public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/18404] New: unnecessary sll when -mint64
@ 2004-11-09 15:56 fshvaige at cisco dot com
  2004-11-09 15:57 ` [Bug target/18404] unnecessary sll when -mint64 (MIPS) fshvaige at cisco dot com
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: fshvaige at cisco dot com @ 2004-11-09 15:56 UTC (permalink / raw)
  To: gcc-bugs

Configured with:
--target=mips-elf --program-suffix=.mips --with-newlib --without-headers
--enable-languages=c,c++,objc -v

Thread model: single
gcc version 3.4.2

File /tmp/gcctest_01.c:

typedef signed char t_SI __attribute__ ((__mode__(SI)));

t_SI inc_SI (t_SI v) {
    return ++v;
}

Command line:
gcc.mips -S -O2 -march=sb1 -mabi=64 -o /tmp/gcctest_01.s /tmp/gcctest_01.c

Result file gcctest_01.s:

        .file   1 "gcctest_01.c"
        .section .mdebug.abi64
        .previous
        .text
        .align  2
        .align  3
        .globl  inc_SI
        .ent    inc_SI
inc_SI:
        .frame  $sp,0,$31               # vars= 0, regs= 0/0, args= 0, gp= 0
        .mask   0x00000000,0
        .fmask  0x00000000,0
        .set    noreorder
        .set    nomacro
        j       $31
        addiu   $2,$4,1
        .set    macro
        .set    reorder

        .end    inc_SI

Command line:
gcc.mips -S -O2 -march=sb1 -mabi=64 -mint64 -o /tmp/gcctest_01.s /tmp/gcctest_01.c

Result file gcctest_01.s:

        .file   1 "gcctest_01.c"
        .section .mdebug.abi64
        .previous
        .text
        .align  2
        .align  3
        .globl  inc_SI
        .ent    inc_SI
inc_SI:
        .frame  $sp,0,$31               # vars= 0, regs= 0/0, args= 0, gp= 0
        .mask   0x00000000,0
        .fmask  0x00000000,0
        sll     $2,$4,0
        .set    noreorder
        .set    nomacro
        j       $31
        addiu   $2,$2,1
        .set    macro
        .set    reorder

        .end    inc_SI

Question: what is this "sll $2,$4,0" good for or why it absent in first result
(without -mint64) ?

-- 
           Summary: unnecessary sll when -mint64
           Product: gcc
           Version: 3.4.2
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: fshvaige at cisco dot com
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: mips-unknown-elf


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


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2005-02-01  3:06 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-11-09 15:56 [Bug target/18404] New: unnecessary sll when -mint64 fshvaige at cisco dot com
2004-11-09 15:57 ` [Bug target/18404] unnecessary sll when -mint64 (MIPS) fshvaige at cisco dot com
2004-11-12  3:34 ` pinskia at gcc dot gnu dot org
2004-11-12  3:55 ` pinskia at gcc dot gnu dot org
2004-12-01 20:04 ` echristo at redhat dot com
2004-12-07 22:21 ` echristo at redhat dot com
2005-01-13  2:38 ` echristo at redhat dot com
2005-01-18  9:57 ` fshvaige at cisco dot com
2005-01-20  0:37 ` echristo at redhat dot com
2005-02-01  3:06 ` echristo at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).