------- Comment #1 from jingyu at google dot com 2010-01-11 19:59 -------
I forgot to paste the wrong assembly code.
arm-eabi-g++ -Os -mthumb double.cpp --save-temps -c -o double.o
The assembly for the following part
_D_rep _D_inf = {{ 0, 0, 0, 0x7ff0 }};
if (*entry == _D_inf.val)
break;
is
ldr r3, .L10+4 ;; _D_inf higher part
ldr r2, .L10 ;; _D_inf lower part
mov r0, r5
mov r1, r6
bl __aeabi_dcmpeq
.L10:
.word 2146435072 ;; 0x7ff00000
.word 0
The value loaded for _D_inf is wrong.
It is a little-endian target.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42691