Timeline for Do I get valid profiling results with optimization turned off?
Current License: CC BY-SA 3.0
13 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Nov 1, 2016 at 2:37 | history | tweeted | twitter.com/StackSoftEng/status/793280682915143680 | ||
| Oct 30, 2016 at 12:44 | comment | added | gnasher729 | If you lose your wallet, and it is dark, do you look for it under a street light where it would be easy to see, or in the dark place where you lost it? | |
| Oct 29, 2016 at 18:44 | comment | added | rwong | If code C1 is faster than code C2 when optimization is off, but C2 is faster than C1 when optimization is on, then you will have to choose which result is more useful to you based on how you plan to use the result. In particular, if you want to choose between C1 and C2, AND you want to maximize the performance with optimizations on, then you should benchmark C1 and C2 with optimizations on. Also, you will want to minimize instrumentation (extra code inserted into the executable for measurement) because instrumentation is also an overhead. | |
| Aug 28, 2016 at 15:09 | comment | added | old_timer | No matter how great the driver they cannot make any car perform through the same corner on the same track in a proportional way. In one vehicle the straights are the problem in another it may be the corners. Sometimes the profiler will find the same bottleneck but that may be just dumb luck for that one application, for another it may find another place. | |
| Aug 28, 2016 at 15:07 | comment | added | old_timer | which you really cant do in this situation, the output is expected to be vastly different in ways that are somewhat predictable with experience but that doesnt mean the profile will see that. We can tell what the optimizer will do with local variables and if it will inline functions or not, where the cliffs are with respect to all in registers or falling off the cliff and having to use the stack, etc. But the profile is of both micro and macro taken at the same time ideally. A sports car vs a yugo. | |
| Aug 28, 2016 at 15:02 | comment | added | Johannes Luong | To stick with your analogy, in my use case I am interesed in the driver's performance and not so much in the cars. | |
| Aug 28, 2016 at 14:53 | comment | added | old_timer | A better analogy is having the same driver (source code) do laps in a minivan and laps in sports car and somehow try to use the minivan lap time to talk about the sports car lap times. | |
| Aug 28, 2016 at 14:51 | comment | added | old_timer | profiling is profiling, it is against the code you built no matter how you built it. If optimized then that is what you are measuring, if not optimized, then that is what you are measuring. If you are wanting to use one measurement of one thing to mean something for the other, that makes no sense. You nave to measure the thing you are using and use those results, cant measure something else. The price of tea in china has nothing to do with the temperature in Texas. | |
| Aug 23, 2016 at 15:05 | vote | accept | Johannes Luong | ||
| Aug 23, 2016 at 13:16 | answer | added | Mike Dunlavey | timeline score: 8 | |
| Aug 23, 2016 at 12:23 | vote | accept | Johannes Luong | ||
| Aug 23, 2016 at 15:05 | |||||
| Aug 23, 2016 at 12:06 | answer | added | nomadictype | timeline score: 7 | |
| Aug 23, 2016 at 11:03 | history | asked | Johannes Luong | CC BY-SA 3.0 |