]> granicus.if.org Git - clang/commitdiff
Testcase for recent checkin.
authorMike Stump <mrs@apple.com>
Mon, 5 Oct 2009 22:24:47 +0000 (22:24 +0000)
committerMike Stump <mrs@apple.com>
Mon, 5 Oct 2009 22:24:47 +0000 (22:24 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83330 91177308-0d34-0410-b5e6-96231b3b80d8

test/CodeGenCXX/attr.cpp [new file with mode: 0644]

diff --git a/test/CodeGenCXX/attr.cpp b/test/CodeGenCXX/attr.cpp
new file mode 100644 (file)
index 0000000..57507d8
--- /dev/null
@@ -0,0 +1,28 @@
+// RUN: clang-cc -triple x86_64-apple-darwin -O0 -S %s -o %t.s &&
+// RUN: FileCheck --input-file=%t.s %s
+
+int foo() __attribute__((aligned(1024)));
+int foo() { }
+
+// CHECK:.align 10, 0x90
+// CHECK:.globl __Z3foov
+// CHECK:__Z3foov:
+
+
+class C {
+  virtual void bar1() __attribute__((aligned(2)));
+  virtual void bar2() __attribute__((aligned(1024)));
+} c;
+
+void C::bar1() { }
+
+// CHECK:.align 1, 0x90
+// CHECK-NEXT:.globl __ZN1C4bar1Ev
+// CHECK-NEXT:__ZN1C4bar1Ev:
+
+
+void C::bar2() { }
+
+// CHECK:.align  10, 0x90
+// CHECK-NEXT:.globl __ZN1C4bar2Ev
+// CHECK-NEXT:__ZN1C4bar2Ev: