http://llvm.org/bugs/show_bug.cgi?id=14293

             Bug #: 14293
           Summary: register pinned variables are not pinned to the
                    register
           Product: libraries
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: Backend: PowerPC
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]
    Classification: Unclassified


[rdivacky@anacreon ~]$ cat rtld.c 
void *foo() {
  register void *tp __asm__("r2");

  return tp;
}
[rdivacky@anacreon ~]$ ./llvm/Release+Asserts/bin/clang -O2 -S -o - rtld.c
    .file    "rtld.c"
    .text
    .globl    foo
    .align    2
    .type    foo,@function
    .section    .opd,"aw",@progbits
foo:
    .align    3
    .quad    .L.foo
    .quad    .TOC.@tocbase
    .quad    0
    .text
.L.foo:
    blr 
    .long    0
    .quad    0
.Ltmp0:
    .size    foo, .Ltmp0-.L.foo


No mention of "r2" in foo at all. The code at O0 is


    ld 3, -8(1)
    blr 

whicih seems wrong to me as well.

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to