Mystery symbols made up by C++ at _low_ optimization levels
Mikhail Teterin
mi+mx at aldan.algebra.com
Mon Sep 25 09:28:03 PDT 2006
Could someone with knowledge of compilers, please, look at the PR 103610?
http://www.freebsd.org/cgi/query-pr.cgi?pr=ports/103610
One of the source files, when compiled (with -O0 or -O1), grows a symbol, that
is not referenced anywhere else... Depending on the optimizations, the symbol
name and the line-number change from `.LC786' and 181 with -O0 below:
loctest.o(.data+0x51c):/usr/ports/devel/icu/work/icu/source/test/intltest/loctest.cpp:181:
undefined reference to `.LC786'
loctest.o(.data+0x520):/usr/ports/devel/icu/work/icu/source/test/intltest/loctest.cpp:181:
undefined reference to `.LC786'
to `.LC779' and 185 with -O1...
Compiling with -O2 gets rid of the problem, but not everyone likes to do that.
I checked -- it does not come from any pre-processor magic. Any clues?
To reproduce, build the devel/icu port with -O1 and -g.
Thanks!
-mi
More information about the freebsd-stable
mailing list