profiling

VisualVM profiling is polluting results

北城以北 提交于 2019-12-24 11:54:12
问题 I am using VisualVM memory profiling to analyse the memory allocation behavior of an application. Unfortunately, it seems the profiling process itself is polluting my results. I continually see 80Mb being allocated over the timeframe of 5 minutes, which is due to memory profiling results being serialised over the JMXBean RMI connection. This memory is always in generation 1 and is immediately GC'd when I ask for it, but it is still annoying that this is showing up. Can I filter memory

Is GNU gprof buggy?

北战南征 提交于 2019-12-24 11:08:21
问题 I have a C program that calls a function pi_calcPiItem() 600000000 times through the function pi_calcPiBlock . So to analyze the time spent in the functions I used GNU gprof. The result seems to be erroneous since all calls are attributed to main() instead. Furthermore the call graph does not make any sense: Each sample counts as 0.01 seconds. % cumulative self self total time seconds seconds calls Ts/call Ts/call name 61.29 9.28 9.28 pi_calcPiItem 15.85 11.68 2.40 pi_calcPiBlock 11.96 13.49

When profiling my fortran program, Acxtrnal.dll is the part using most of the CPU time! What is that dll.?

不羁岁月 提交于 2019-12-24 11:03:49
问题 Hi I am profiling with VTUNE (an intel visual studio extension) my 2D numerical model I wrote for my research, in order to speed it up a little. I already sped up my 1D model this way (i.e. identifying the "hotspot" of my model). This time though, after running the profiler I see that the most time consuming part is not a fortran subroutine I wrote (as it occured for my 1D model) but it is a dll called Acxtrnal.dll. I googled the name of this dll but I could not find better information. Does

A weird Timinig issue with “clEnqueueNDRangeKernel” in OpenCL

本秂侑毒 提交于 2019-12-24 11:03:01
问题 I'm new to opencl and I'm experiencing a weird issue with it! I have a reduction kernel and I repeat it several times! The problem is that when I profile the execution of kernel the elapsed time (queued->end) is almost same and a bit increasing but when I measure the elasped time within "C++" code the time for the execution of line "clEnqueueNDRangeKernel" increases with a rapid rate!! I have attached both the code and the output of profiling! :shock: // execute the kernel globalWorkSize[0] =

How do I check if ConcurrentLinkedQueue leaves garbage (dereferenced instances) for the GC?

久未见 提交于 2019-12-24 10:35:56
问题 I am using a bunch of ConcurrentLinkedQueue s in my application and the GC overhead is huge. How do I check if the ConcurrentLinkedQueue is the culprit? Is there a standard way in Java to profile these data structures for memory allocation/deallocation? 回答1: One way to do it is to write a simple test program and run it with the -verbose:gc JVM option. For example, the code: import java.util.concurrent.ConcurrentLinkedQueue; public class TestGC { public static void main(String[] args) throws

How to profile Native JNI library

徘徊边缘 提交于 2019-12-24 09:17:53
问题 How can I profile a Java Native Interface library written in C? I know about the usual C profilers, but my question is how can I profile the whole set including the calls to the JVM methods which might be slowing down the program. 回答1: After some research and testing with some of the methods proposed here I ended up using sprof . Basically I followed the instructions available in this answer. Some comments: I had to leave LD_PROFILE_OUTPUT empty in order to get the result in /var/tmp/ ,

Performance/profiling measurement in C

浪尽此生 提交于 2019-12-24 08:48:22
问题 I'm doing some prototyping work in C, and I want to compare how long a program takes to complete with various small modifications. I've been using clock ; from K&R: clock returns the processor time used by the program since the beginning of execution, or -1 if unavailable. This seems sensible to me, and has been giving results which broadly match my expectations. But is there something better to use to see what modifications improve/worsen the efficiency of my code? Update: I'm interested in

Java Mission Control says “few profiling samples”, why, and what are my other options?

对着背影说爱祢 提交于 2019-12-24 07:35:10
问题 I'm profiling a Java application using Java Mission Control, and it's saying on the main page of the flight recording that "This recording contains few profiling samples even though CPU load is high. The profiling data is thus likely not relevant." It seems to be telling the truth. I asked it to sample every 10 ms for 3 minutes which should be 18000 samples, but I only see 996 samples. It goes on to explain "The profiling data is thus likely not relevant. This might be because the application

How much memory does jProfiler need to analyze a heap dump of size X?

孤者浪人 提交于 2019-12-24 05:38:07
问题 I have a heap size of X (= 5 giga bytes). How much should I allocate for jprofiler to efficiently analyze this heap? 回答1: I would recommend using Eclipse MAT to view the heap dump. It does a much better job in terms of memory requirements for a heap dump of size X because it creates intermediate index files on disk instead of sucking up the whole thing into it's own memory. Most tools require some multiple N of X to open the heap dump where N is usually >= 2. Also, make sure to start the Java

How can I “hook into” Python from C++ when it executes a function? My goal is to profile

独自空忆成欢 提交于 2019-12-24 05:23:06
问题 I'm implementing a profiler in an application and I'm a little flummoxed about how to implement Python profiling such that the results can be displayed in my existing tool. The application allows for Python scripting via communication with the python interpreter. I was wondering if anyone has ideas on how to profile Python functions from C++ Thank you for your suggestions :) 回答1: Well not sure what your goal is, but I'd personally not start from zero but use the existing modules for profiling