Thank you for the bug report. I've confirmed this with gcc-linaro-4.6-2012.01 on ARM:
asa-san@ursa4:~/bugs/ken$ /scratch/asa-san/cbuild/slaves/ursa4/gcc-linaro-4.6-20 12.0 gcc-linaro-4.6-2012.01/ gcc-linaro-4.6-2012.02/ asa-san@ursa4:~/bugs/ken$ /scratch/asa-san/cbuild/slaves/ursa4/gcc-linaro-4.6-20 12.01/gcc-binary/bin/g++ -c test.cpp asa-san@ursa4:~/bugs/ken$ readelf -s test.o|grep THUNK 13: 00000001 72 FUNC LOCAL DEFAULT 29 .LTHUNK0 32: 00000001 68 FUNC LOCAL DEFAULT 44 .LTHUNK2 51: 00000001 68 FUNC LOCAL DEFAULT 59 .LTHUNK4
Ken has investigated for which other toolchains the problems does and does not exist, see previous comments.
I have set the priority to Medium, since there is a work around - the error only happens when compiling at -O0.
Thank you for the bug report. I've confirmed this with gcc-linaro- 4.6-2012. 01 on ARM:
asa-san@ ursa4:~ /bugs/ken$ /scratch/ asa-san/ cbuild/ slaves/ ursa4/gcc- linaro- 4.6-20 4.6-2012. 01/ gcc-linaro- 4.6-2012. 02/ ursa4:~ /bugs/ken$ /scratch/ asa-san/ cbuild/ slaves/ ursa4/gcc- linaro- 4.6-20 binary/ bin/g++ -c test.cpp ursa4:~ /bugs/ken$ readelf -s test.o|grep THUNK
12.0
gcc-linaro-
asa-san@
12.01/gcc-
asa-san@
13: 00000001 72 FUNC LOCAL DEFAULT 29 .LTHUNK0
32: 00000001 68 FUNC LOCAL DEFAULT 44 .LTHUNK2
51: 00000001 68 FUNC LOCAL DEFAULT 59 .LTHUNK4
Ken has investigated for which other toolchains the problems does and does not exist, see previous comments.
I have set the priority to Medium, since there is a work around - the error only happens when compiling at -O0.