summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/exceptions-seh.c
diff options
context:
space:
mode:
authorReid Kleckner <reid@kleckner.net>2015-07-01 21:00:00 +0000
committerReid Kleckner <reid@kleckner.net>2015-07-01 21:00:00 +0000
commiteb11c41900a4110ad8f1f088eabab5a57f53a1f4 (patch)
treef48da955d7b3dcc93c66e026f1d9973ddcfbb550 /clang/test/CodeGen/exceptions-seh.c
parent6511c8bb9a7edb0f973b7ba5ca47f4ff049b1bc8 (diff)
downloadbcm5719-llvm-eb11c41900a4110ad8f1f088eabab5a57f53a1f4.tar.gz
bcm5719-llvm-eb11c41900a4110ad8f1f088eabab5a57f53a1f4.zip
[SEH] Delete the 32-bit IR lowering for __finally blocks and use x64
32-bit finally funclets are intended to be called both directly from the parent function and indirectly from the EH runtime. Because we aren't contorting LLVM's X86 prologue to match MSVC's, calling the finally block directly passes in a different value of EBP than the one that the runtime provides. We need an adapter thunk to adjust EBP to the expected value. However, WinEHPrepare already has to solve this problem when cleanups are not pre-outlined, so we can go ahead and rely on it rather than duplicating work. Now we only do the llvm.x86.seh.recoverfp dance for 32-bit SEH filter functions. llvm-svn: 241187
Diffstat (limited to 'clang/test/CodeGen/exceptions-seh.c')
-rw-r--r--clang/test/CodeGen/exceptions-seh.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/clang/test/CodeGen/exceptions-seh.c b/clang/test/CodeGen/exceptions-seh.c
index ab6fad6f3ef..772fe547ba5 100644
--- a/clang/test/CodeGen/exceptions-seh.c
+++ b/clang/test/CodeGen/exceptions-seh.c
@@ -188,17 +188,15 @@ void basic_finally(void) {
// CHECK: to label %[[cont:[^ ]*]] unwind label %[[lpad:[^ ]*]]
//
// CHECK: [[cont]]
-// X64: %[[fp:[^ ]*]] = call i8* @llvm.frameaddress(i32 0)
-// X64: call void @"\01?fin$0@0@basic_finally@@"(i8 0, i8* %[[fp]])
-// X86: call void @"\01?fin$0@0@basic_finally@@"()
+// CHECK: %[[fp:[^ ]*]] = call i8* @llvm.frameaddress(i32 0)
+// CHECK: call void @"\01?fin$0@0@basic_finally@@"({{i8( zeroext)?}} 0, i8* %[[fp]])
// CHECK: ret void
//
// CHECK: [[lpad]]
// CHECK: landingpad { i8*, i32 }
// CHECK-NEXT: cleanup
-// X64: %[[fp:[^ ]*]] = call i8* @llvm.frameaddress(i32 0)
-// X64: call void @"\01?fin$0@0@basic_finally@@"(i8 1, i8* %[[fp]])
-// X86: call void @"\01?fin$0@0@basic_finally@@"()
+// CHECK: %[[fp:[^ ]*]] = call i8* @llvm.frameaddress(i32 0)
+// CHECK: call void @"\01?fin$0@0@basic_finally@@"({{i8( zeroext)?}} 1, i8* %[[fp]])
// CHECK: resume
// CHECK: define internal void @"\01?fin$0@0@basic_finally@@"({{.*}})
OpenPOWER on IntegriCloud