- status: open --> closed
With gcc 7.5 or 9.2, annotation at top of cbyt plot does not appear.
This did not happen with older gcc 4.x versions. It appears that two global
variables _firstLbl and _LblInc have something in the high-order half of
the long variables. So these become huge numbers, out of range, thus no
annotation is plotted. annotate.cc in oop/image directory contains the
code for this. I haven't been able to find where the corruption occurs.
The CMP trace plots in va still have annotation working when cbyt does
not. The garbage can be cleared by an AND operation &32767, since these
are relatively small positive integers. One would need at least &8191
to allow for an 8K UHD monitor. The two relevant functions
getXlabelIncrement() and getFirstTraceToAnnotate() occur several times.
It turns out that the easiest fix is to modify the header file
image_input.hh where these are defined. The modified lines will be:
long getFirstTraceToAnnotate(){return _firstLbl&32767;}
long getXlabelIncrement(){return _LblInc&32767;}
I have tried this patch with gcc 4.8 and 9.3 (where annotation works)
and it had no effect. So this kind of fix may be applicable to
other problems related to long integers in the c++ code.