http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53823

--- Comment #9 from John David Anglin <danglin at gcc dot gnu.org> 2012-07-31 
18:51:26 UTC ---
Regarding the remaining acats fails, the following line in a-calend.adb
appears to be miscompiled:

            Date_Dur := Date_Dur - Time_Dur (Four_Year_Segs) *
                                   Secs_In_Four_Years;

The resulting value for Date_Dur is wrong.

The generated code appears to use synth_mult.

=> 0x00019c28 <__gnat_split+480>:    cmpib,>= 0,ret1,0x19cd0 <__gnat_split+648>
   0x00019c2c <__gnat_split+484>:    copy ret1,r20
   0x00019c30 <__gnat_split+488>:    ldi 0,r21
   0x00019c34 <__gnat_split+492>:    ldi -1,r22
   0x00019c38 <__gnat_split+496>:    and r19,r21,ret0
   0x00019c3c <__gnat_split+500>:    and r20,r22,ret1
   0x00019c40 <__gnat_split+504>:    extrw,u ret1,4,5,r19
   0x00019c44 <__gnat_split+508>:    depw,z ret0,26,27,r7
   0x00019c48 <__gnat_split+512>:    depw,z ret1,26,27,r8
   0x00019c4c <__gnat_split+516>:    or r19,r7,r7
   0x00019c50 <__gnat_split+520>:    sub r8,ret1,r12
   0x00019c54 <__gnat_split+524>:    sub,b r7,ret0,r11
   0x00019c58 <__gnat_split+528>:    extrw,u r12,8,9,r31
   0x00019c5c <__gnat_split+532>:    depw,z r12,22,23,r26
   0x00019c60 <__gnat_split+536>:    depw,z r11,22,23,r25
   0x00019c64 <__gnat_split+540>:    or r31,r25,r25
   0x00019c68 <__gnat_split+544>:    add r26,r12,r8
   0x00019c6c <__gnat_split+548>:    add,c r25,r11,r7
   0x00019c70 <__gnat_split+552>:    extrw,u r8,0,1,r31
   0x00019c74 <__gnat_split+556>:    depw,z r8,30,31,r24
   0x00019c78 <__gnat_split+560>:    depw,z r7,30,31,r23
   0x00019c7c <__gnat_split+564>:    or r31,r23,r23
   0x00019c80 <__gnat_split+568>:    sub r24,ret1,r26
   0x00019c84 <__gnat_split+572>:    sub,b r23,ret0,r25
   0x00019c88 <__gnat_split+576>:    extrw,u r26,3,4,r31
   0x00019c8c <__gnat_split+580>:    depw,z r25,27,28,r21
   0x00019c90 <__gnat_split+584>:    or r31,r21,r21
   0x00019c94 <__gnat_split+588>:    depw,z r26,27,28,r22
   0x00019c98 <__gnat_split+592>:    sub r22,ret1,r24
   0x00019c9c <__gnat_split+596>:    sub,b r21,ret0,r23
   0x00019ca0 <__gnat_split+600>:    extrw,u r24,5,6,r21
   0x00019ca4 <__gnat_split+604>:    depw,z r23,25,26,r19
   0x00019ca8 <__gnat_split+608>:    depw,z r24,25,26,r20
   0x00019cac <__gnat_split+612>:    or r21,r19,r19
   0x00019cb0 <__gnat_split+616>:    add ret1,r20,r22
   0x00019cb4 <__gnat_split+620>:    add,c ret0,r19,r21
   0x00019cb8 <__gnat_split+624>:    shrpw r21,r22,25,r19
   0x00019cbc <__gnat_split+628>:    depw,z r22,24,25,ret0
   0x00019cc0 <__gnat_split+632>:    copy r19,r21
   0x00019cc4 <__gnat_split+636>:    copy ret0,r22
   0x00019cc8 <__gnat_split+640>:    add r22,r4,r8
   0x00019ccc <__gnat_split+644>:    add,c r21,r3,r7
   0x00019cd0 <__gnat_split+648>:    copy r7,r25
   0x00019cd4 <__gnat_split+652>:    copy r8,r26
   0x00019cd8 <__gnat_split+656>:    ldi 0,r23
   0x00019cdc <__gnat_split+660>:    ldil L%1e13000,r24
   0x00019ce0 <__gnat_split+664>:    ldo 380(r24),r24
   0x00019ce4 <__gnat_split+668>:    b,l 0x34288 <__divdi3>,rp
   0x00019ce8 <__gnat_split+672>:    nop

Reply via email to