summaryrefslogtreecommitdiffstats
path: root/test/CodeGen/asm-label.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/CodeGen/asm-label.c')
-rw-r--r--test/CodeGen/asm-label.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/test/CodeGen/asm-label.c b/test/CodeGen/asm-label.c
index 7be2ad3..c06f11f 100644
--- a/test/CodeGen/asm-label.c
+++ b/test/CodeGen/asm-label.c
@@ -2,11 +2,18 @@
// RUN: %clang_cc1 -triple=i686-apple-darwin9 -emit-llvm %s -o - | FileCheck %s --check-prefix=DARWIN
char *strerror(int) asm("alias");
+int x __asm("foo");
-void test(void)
-{
- strerror(-1);
+int *test(void) {
+ static int y __asm("bar");
+ strerror(-1);
+ return &y;
}
+// LINUX: @bar = internal global i32 0
+// LINUX: @foo = common global i32 0
// LINUX: declare i8* @alias(i32)
+
+// DARWIN: @"\01bar" = internal global i32 0
+// DARWIN: @"\01foo" = common global i32 0
// DARWIN: declare i8* @"\01alias"(i32)
OpenPOWER on IntegriCloud