Use of long long constants produces incorrect code when cross compiling for the
hppa target on a 64 bit host


$ hppa--linux-gcc -v
Using built-in specs.
Target: hppa--linux
Configured with: /home/nick/gnu/gcc/configure --target=hppa--linux
--prefix=/home/nick/gnu/path --enable-languages=c : (reconfigured)
/home/nick/gnu/gcc/configure --target=hppa--linux --prefix=/home/nick/gnu/path
--enable-languages=c
Thread model: posix
gcc version 4.1.2 20061021 (prerelease) (NetBSD nb1 20061021)
$ hppa--linux-gcc -mpa-risc-1-1 -msoft-float -mdisable-fpregs -S test3.i -o
test3.s
$ cat test3.s
        .LEVEL 1.1
        .text
        .align 4
.globl foo
        .type   foo, @function
foo:
        .PROC
        .CALLINFO FRAME=64,NO_CALLS,SAVE_SP,ENTRY_GR=3
        .ENTRY
        copy %r3,%r1
        copy %r30,%r3
        stwm %r1,64(%r30)
        ldil L'122192928000000000,%r29
        ldi 0,%r28
        ldo R'122192928000000000(%r29),%r29
        stw %r28,8(%r3)
        stw %r29,12(%r3)
        ldw 8(%r3),%r19
        ldw 12(%r3),%r20
        extru %r19,31,28,%r28
        extru %r20,31,32,%r29
        ldo 64(%r3),%r30
        ldwm -64(%r30),%r3
        bv,n %r0(%r2)
        .EXIT
        .PROCEND
        .size   foo, .-foo
        .ident  "GCC: (GNU) 4.1.2 20061021 (prerelease) (NetBSD nb1 20061021)"
$


-- 
           Summary: HPPA: Incorrect code generated on 64bit host
           Product: gcc
           Version: 4.1.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: skrll at netbsd dot org
 GCC build triplet: sparc64--netbsd
  GCC host triplet: sparc64--netbsd
GCC target triplet: hppa--linux


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

Reply via email to