[chbot] Compiler optimisation
gb7ipd at gmail.com
Fri Jul 2 01:10:59 BST 2021
Does anyone have any tips on how to debug an issue that only arises when
GCC optimisation is increased from -O0 to -O1 (or above).
I have an issue with the hardware jpeg encoder on an stm32f7 MCU when I
crank up the optimise (the first time I've tried it as I prefer -O0 for
debugging). I've tried putting:
#pragma GCC optimize("O0")
at the start of the 3 files that directly implement the jpeg stuff to turn
off optimise on them as it looks like the conversion functions that
generate the YCbCr 4:2:0 data from the ARGB8888 ready for the hardware
engine have bits optimised away!
I would expect the lookup tables generated by the code for these
conversions would be the same irrespective of optimisation level but that's
the only place I can think to look (the '.lst' files output from the
compiler are way too different to make any sensible comparisons between
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Chchrobotics