Home » Archived » Test and Performance Tools Platform (TPTP) » No Execution Statistics on stand-alone
|
Re: No Execution Statistics on stand-alone [message #87292 is a reply to message #87204] |
Wed, 15 November 2006 09:12 |
Asaf Yaffe Messages: 333 Registered: July 2009 |
Senior Member |
|
|
Michael wrote:
> Hi,
>
> i try to profile a application with the stand-alone mode.
>
> call: java
> -XrunpiAgent:server=standalone,filters=myfilter,profile=mypr ofile,file=trace.trcxml
> test.Main
>
> myprofile looks like:
> MONITOR_MDE = all
> FILTERS = true
> ID_STYLE = static
> TIMESTAMPS = true
> METHOD_COUNTS = true
> STACK_INFORMATION = boundaryAndContigous
> BOUNDARY_DEPTH = 2
> TRACE_MODE = full
>
> But i get no execution statistics. Have i forgot an option? Which
> options i have to aktivate to get the execution statistics (or execution
> flow) ??
>
> thx for any help!
>
> regards Michael
>
I suggest to start with a simple configuration and then check which
additional option prevents the profiler from working as expected.
For example, you can use the following command line (without any
additional profiling options) to get execution statistics/flow:
java
-XrunpiAgent:mode=full,server=standalone,filters=myfilter,fi le=trace.trcxml
test.Main
If this still does not work, try to remove the filter option and check
again.
Also, when you import the trace.trcxml file to Eclipse, make sure to
select the correct option in the Import Profiling File wizard (e.g,
select either "Show Execution Statistics" or "Show Full Data"). Note
that the default option is "Show Heap Statistics", which does not import
execution information.
HTH,
Asaf
--
Asaf Yaffe
Eclipse TPTP Committer, Platform Project (JVMTI Profiler)
|
|
| |
Re: No Execution Statistics on stand-alone [message #88715 is a reply to message #87292] |
Sun, 26 November 2006 14:33 |
Ravi Roy Messages: 47 Registered: July 2009 |
Member |
|
|
Hi Asaf,
I have different problem while trying to profile an application in headless
way.
I try to profile as per the following command line options :
java -XrunpiAgent:server=standalone,profile=myprofile,file=trace. trcxml
MyApp
which gives the following exception :
Exception in thread "main" java.lang.NoClassDefFoundError: MyApp (wrong
name: com/mycomp/myapp/MyApp)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
Test Application to be profiled itself is located where I am running the
above command line options, but still it says NoClassDefFoundError.
I have installed Agent Controller seperately. I can run the sample
application (SampleClient) located in Agent Controller directory, it works
fine.
Thanks for your help!
Regards,
Ravi.
"Asaf Yaffe" <asaf.yaffe@intel.com> wrote in message
news:ejell9$u3c$1@utils.eclipse.org...
> Michael wrote:
>> Hi,
>>
>> i try to profile a application with the stand-alone mode.
>>
>> call:
>> java -XrunpiAgent:server=standalone,filters=myfilter,profile=mypr ofile,file=trace.trcxml
>> test.Main
>>
>> myprofile looks like:
>> MONITOR_MDE = all
>> FILTERS = true
>> ID_STYLE = static
>> TIMESTAMPS = true
>> METHOD_COUNTS = true
>> STACK_INFORMATION = boundaryAndContigous
>> BOUNDARY_DEPTH = 2
>> TRACE_MODE = full
>>
>> But i get no execution statistics. Have i forgot an option? Which options
>> i have to aktivate to get the execution statistics (or execution flow) ??
>>
>> thx for any help!
>>
>> regards Michael
>>
> I suggest to start with a simple configuration and then check which
> additional option prevents the profiler from working as expected.
> For example, you can use the following command line (without any
> additional profiling options) to get execution statistics/flow:
>
> java -XrunpiAgent:mode=full,server=standalone,filters=myfilter,fi le=trace.trcxml
> test.Main
>
> If this still does not work, try to remove the filter option and check
> again.
>
> Also, when you import the trace.trcxml file to Eclipse, make sure to
> select the correct option in the Import Profiling File wizard (e.g, select
> either "Show Execution Statistics" or "Show Full Data"). Note that the
> default option is "Show Heap Statistics", which does not import execution
> information.
>
> HTH,
> Asaf
>
> --
> Asaf Yaffe
> Eclipse TPTP Committer, Platform Project (JVMTI Profiler)
|
|
| |
Re: No Execution Statistics on stand-alone [message #88953 is a reply to message #88895] |
Wed, 29 November 2006 09:25 |
Ravi Roy Messages: 47 Registered: July 2009 |
Member |
|
|
Thanks Asaf,
Thanks a lot, It worked, I was just wondering why it is not working, as you
mentioned in your post that I had to run it from root of the package and
specify the class name preceding the full package name.
Now I have the "myapp.trcxml", is it also possible to generate a HTML report
on the basis of this XML document in the headless way too ?
Great, Thanks a lot again for the pointer you provided.
Regards.
Ravi.
"Asaf Yaffe" <asaf.yaffe@intel.com> wrote in message
news:ekjdpc$fij$1@utils.eclipse.org...
> Ravi Roy wrote:
>
>> I try to profile as per the following command line options :
>>
>> java -XrunpiAgent:server=standalone,profile=myprofile,file=trace. trcxml
>> MyApp
>>
>> which gives the following exception :
>>
>> Exception in thread "main" java.lang.NoClassDefFoundError: MyApp (wrong
>> name: com/mycomp/myapp/MyApp)
>
> Ravi,
>
> This problem does not seem to be related to the profiler (the -Xrun...
> stuff). Please check whether you get the same error when trying to run
> your application from the command line without the profiler (just try java
> MyApp).
>
> When launching Java classes from the command line, you need to:
> 1. Use the fully qualified class name (e.g. com.mycomp.myapp.MyApp instead
> of just MyApp)
> 2. Set the working/current directory to be the one that includes your
> *root* package, and not the application itself.
> 3. In some VMs, you may need to add the current directory to the VM
> classpath using '-cp .;' (Windows) or '-cp .:' (Linux).
>
> Bottom line: assuming all class files are located somewhere under a 'bin'
> directory (the default configuration when using Eclipse to build your Java
> applications):
> 1. Change directory to 'bin'
> 2. Type 'java -cp .; com.mycomp.myapp.MyApp' and check that it works
> 3. Add the '-X...' stuff to profile your application in standalone mode
>
> HTH!
> Asaf
>
> --
> Asaf Yaffe
> Eclipse TPTP Committer, Platform Project (JVMTI Profiler)
|
|
| | |
Goto Forum:
Current Time: Wed Jan 15 09:25:04 GMT 2025
Powered by FUDForum. Page generated in 0.32757 seconds
|