On Wed, 18 Apr 2018, Jack Stalnaker wrote:
Yeah, I realize it's a difficult question with no example. It would be quite difficult to chop out a chunk of the code showing the 5x slowdown, though, I think. I was probing for something big or obvious I may have missed, or some known issue with the later versions, since this is so dramatic, and since the only thing that has changed is the compiler. The compilation options are minimal. I'm using -g -Og, and that's it. I have tried a release build with some finer tuning, but that doesn't show much improvement.
-Og really isn't meant for high performance. It is quite possible that some optimizations that were hindering debugging were disabled in it. I'd be much more worried if you got this kind of slowdown for -O[123].
-- Marc Glisse