This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/14204] New: [tree-ssa] Bogus uninitialized warning for stack pointer register var


GNU C version 3.5-tree-ssa 20040217 (merged 20040211) (alphaev68-unknown-linux-gnu)
        compiled by GNU C version 3.5-tree-ssa 20040217 (merged 20040211).

% cat test.c
void *load_PCB (void)
{
        register void *sp __asm__("$30");
        return sp;
}

% gcc -O -c -W -Wall test.c 
test.c: In function `load_PCB':
test.c:4: warning: 'sp' is used uninitialized in this function

$30 is the stack pointer, which must be kept valid by gcc all the time,
so this shouldn't produce a warning.

-- 
           Summary: [tree-ssa] Bogus uninitialized warning for stack pointer
                    register var
           Product: gcc
           Version: tree-ssa
            Status: UNCONFIRMED
          Keywords: diagnostic
          Severity: normal
          Priority: P2
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: falk at debian dot org
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: alphaev68-unknown-linux-gnu
  GCC host triplet: alphaev68-unknown-linux-gnu
GCC target triplet: alphaev68-unknown-linux-gnu


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]