10

I have a C++ code that upon execution:

Loads JVM (I have full control on how to load the JVM), and call Java methods (from loaded classes) using C JNI code. The Java code has no Main() and it is actually not a standard Java application. it is mainly a static code that compiled and compacted into Jar file, the code is being called by the C++ module.

Is it possible to profile this Java code being executed by YourKit (have license for it)? If so I'll be glad to know how.

Bill the Lizard
  • 398,270
  • 210
  • 566
  • 880
Guy
  • 915
  • 2
  • 14
  • 27

2 Answers2

0

I'll throw this out there for C++ folks looking to profile Java: Java has a great visual profiler that automatically hooks up to the JVM called VisualVM. It is included with the jdk. Check it out here: http://visualvm.java.net/

To run visual vm look for the executable in your jdk bin folder.

Adam
  • 3,675
  • 8
  • 45
  • 77
0

Answer for the mass demands,

I have managed to profile using YourKit. I just added the yourkit.com/docs/80/help/agent.jsp agnent VM flag and attach the profiler to the VM.

Guy
  • 915
  • 2
  • 14
  • 27