Re: [Gimp-developer] gimp-plugin profiling

2013-03-11 Thread Tibor Bamhor
Well, I have a lot of if/then in code, but they are essential. So probably no opportunity here. I will look on the links you provided anyway, thanks... 2013/3/11 Jon Nordby > > Yes, if you have branches in inner loops eliminating them can give > large speedups. > A quick google search gave th

Re: [Gimp-developer] gimp-plugin profiling

2013-03-11 Thread Jon Nordby
On 10 March 2013 22:55, Tibor Bamhor wrote: > Hi, > > Thank for you interest. Today I spent some time reading about perf - it is > quite complex tool or rather it measures things that I am not familiar with. > However I did some primitive testing and got this output: > > 7729.437618_task-clock

Re: [Gimp-developer] gimp-plugin profiling

2013-03-11 Thread Ville Sokk
I find it difficult to read perf output so I use https://code.google.com/p/jrfonseca/wiki/Gprof2Dot to create a callgraph. I think branch misses is related to branch prediction https://en.wikipedia.org/wiki/Branch_prediction it's a micro-optimization and difficult to get right. I'm not an expert a

Re: [Gimp-developer] gimp-plugin profiling

2013-03-10 Thread Tibor Bamhor
Hi, Thank for you interest. Today I spent some time reading about perf - it is quite complex tool or rather it measures things that I am not familiar with. However I did some primitive testing and got this output: 7729.437618_task-clock#0.386_CPUs_utilized__ __

Re: [Gimp-developer] gimp-plugin profiling

2013-03-10 Thread Ville Sokk
I'm sorry you didn't get any help. But I would like to note that gprof is generally not considered a good tool for profiling, especially if threads are involved. People suggest statistical profilers like perf (Linux kernel profiler, works in userspace too), gperftools, oprofile, dtrace (not just a

Re: [Gimp-developer] gimp-plugin profiling

2013-03-09 Thread Tibor Bamhor
Hi, I reply to my own post. On the second time using gprof turned to be easy. In case anybody is interested, the steps are: 1. you need the gimp compiled with debug option [but this I am not sure about, and can not test right now] 2. Compile your plugin with '-pg' switch. If you are using gimptoo

[Gimp-developer] gimp-plugin profiling

2013-03-08 Thread Tibor Bamhor
Hi, this is my first post in this mailing list ever, I am developer of few C-based plugins for gimp, but overall I am not professional developer. Now I have a question about profiling of plugins. I have some experiences with debugging a plugin with valgrind, but now I would like to get an outpu