]> granicus.if.org Git - clang/commitdiff
We were already passing the case in pr9356. Add it to attributes.c to make
authorRafael Espindola <rafael.espindola@gmail.com>
Sun, 13 May 2012 01:56:10 +0000 (01:56 +0000)
committerRafael Espindola <rafael.espindola@gmail.com>
Sun, 13 May 2012 01:56:10 +0000 (01:56 +0000)
sure we don't regress. I will add a warning in a sec.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156726 91177308-0d34-0410-b5e6-96231b3b80d8

test/CodeGen/attributes.c

index 4e73af60439db96bc7b6e6799babfcd99ffab787..e971a793473a593c263ce116a83c2f3dec98ca54 100644 (file)
@@ -81,3 +81,11 @@ void t21(void) {
 }
 // CHECK: [[FPTRVAR:%[a-z0-9]+]] = load void (i32)** @fptr
 // CHECK-NEXT: call x86_fastcallcc void [[FPTRVAR]](i32 10)
+
+
+// PR9356: We might want to err on this, but for now at least make sure we
+// use the section in the definition.
+void __attribute__((section(".foo"))) t22(void);
+void __attribute__((section(".bar"))) t22(void) {}
+
+// CHECK: define void @t22() nounwind section ".bar"