简体   繁体   中英

16 Thread / 16 core code profiling with Java / Eclipse TPTP on Linux system

I have developed a nice multi-Threaded genetic algorithm in Java that runs on a 16-core system running CentOS with 128GB of RAM.

I want to use a code profiler to see if I can figure out which portion of the code is getting bogged down when I increase the number of mutations in my simulation beyond a certain point. Memory doesn't seem to be the issue.

So I installed VNC and Eclipse 3.6SR2 on the server and installed the TPTP plugin.

PROBLEM: The biggest issue is that it doesn't look like eclipse is using more than one core when I am doing the TPTP "execution time analysis" (I checked using 'top'). Normally when the program is run from the command line it uses as many cores as there are threads in the program.

Is there a way to fix this in the eclipse configuration?

Get a real profiler like YourKit and add the agent to your application at startup.

Then you can open an SSH tunnel with the port where the agent is running and you can remotely profile your application. It has a quite good documentation and a healthy community in their forums. And in my opinion YourKit is great for multithreaded applications, I use it a lot.

No need for VNC and installing Eclipse on a production server.

Disclaimer: My company develops JProfiler

A profiler that uses JVMTI should not change the multi-core thread distribution with respect to a regular execution. TPTP may not be the best option for you.

There are several powerful Java profilers in the market. The most well-known free option is VisualVM and a commmercial alternative with much more powerful analytic capabilities in the area of multi-threading and monitor contention analysis is JProfiler - there's a fully functional free trial.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM