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

            Bug ID: 16877
           Summary: Global register variable support
           Product: clang
           Version: trunk
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: -New Bugs
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
    Classification: Unclassified

register int num asm("ebx");

void f() {
  num = 12345;
}

void g() {
  int x;
  f();
  asm("mov %%ebx, %0" : "=r"(x));
  // x is now 12345
}

clang parses this successfully and prints a helpful error message; the bug is
that it doesn't actually support this (GNU extension) functionality.

This feature is useful in low-level software like JIT compilers. I realize this
requires support in LLVM (some way to express this constraint in LLIR for a
start), so I'm not sure exactly where this bug should be filed.

-- 
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