diff options
author | Heejin Ahn <aheejin@gmail.com> | 2017-09-15 22:01:22 +0000 |
---|---|---|
committer | Heejin Ahn <aheejin@gmail.com> | 2017-09-15 22:01:22 +0000 |
commit | fa9e1fba8ccf73e1de13989c935ab5aa8168f5da (patch) | |
tree | ae5fabdbb962fab6ec7f90eca8eba75b2ff72fe5 | |
parent | 496ecab2ba91370b5189c046497cda485883f287 (diff) | |
download | bcm5719-llvm-fa9e1fba8ccf73e1de13989c935ab5aa8168f5da.tar.gz bcm5719-llvm-fa9e1fba8ccf73e1de13989c935ab5aa8168f5da.zip |
Remove __builtin_wasm_rethrow builtin
Summary:
Remove `__builtin_wasm_rethrow` builtin. I thought it was required to implement
`__cxa_rethrow` function in libcxxabi, but it turned out it will be using
`__builtin_wasm_throw` instead.
Reviewers: dschuff, jgravelle-google
Reviewed By: jgravelle-google
Subscribers: jfb, sbc100, jgravelle-google
Differential Revision: https://reviews.llvm.org/D37931
llvm-svn: 313402
-rw-r--r-- | clang/include/clang/Basic/BuiltinsWebAssembly.def | 1 | ||||
-rw-r--r-- | clang/lib/CodeGen/CGBuiltin.cpp | 4 | ||||
-rw-r--r-- | clang/test/CodeGen/builtins-wasm.c | 6 |
3 files changed, 0 insertions, 11 deletions
diff --git a/clang/include/clang/Basic/BuiltinsWebAssembly.def b/clang/include/clang/Basic/BuiltinsWebAssembly.def index 19318dcebb9..e9d8ea63256 100644 --- a/clang/include/clang/Basic/BuiltinsWebAssembly.def +++ b/clang/include/clang/Basic/BuiltinsWebAssembly.def @@ -23,6 +23,5 @@ BUILTIN(__builtin_wasm_grow_memory, "zz", "n") // Exception handling builtins. BUILTIN(__builtin_wasm_throw, "vUiv*", "r") -BUILTIN(__builtin_wasm_rethrow, "v", "r") #undef BUILTIN diff --git a/clang/lib/CodeGen/CGBuiltin.cpp b/clang/lib/CodeGen/CGBuiltin.cpp index 971cecfb484..4240d2de536 100644 --- a/clang/lib/CodeGen/CGBuiltin.cpp +++ b/clang/lib/CodeGen/CGBuiltin.cpp @@ -9574,10 +9574,6 @@ Value *CodeGenFunction::EmitWebAssemblyBuiltinExpr(unsigned BuiltinID, Value *Callee = CGM.getIntrinsic(Intrinsic::wasm_throw); return Builder.CreateCall(Callee, {Tag, Obj}); } - case WebAssembly::BI__builtin_wasm_rethrow: { - Value *Callee = CGM.getIntrinsic(Intrinsic::wasm_rethrow); - return Builder.CreateCall(Callee); - } default: return nullptr; diff --git a/clang/test/CodeGen/builtins-wasm.c b/clang/test/CodeGen/builtins-wasm.c index e0f72d2e503..2361fdf40ce 100644 --- a/clang/test/CodeGen/builtins-wasm.c +++ b/clang/test/CodeGen/builtins-wasm.c @@ -20,9 +20,3 @@ void f3(unsigned int tag, void *obj) { // WEBASSEMBLY32: call void @llvm.wasm.throw(i32 %{{.*}}, i8* %{{.*}}) // WEBASSEMBLY64: call void @llvm.wasm.throw(i32 %{{.*}}, i8* %{{.*}}) } - -void f4() { - return __builtin_wasm_rethrow(); -// WEBASSEMBLY32: call void @llvm.wasm.rethrow() -// WEBASSEMBLY64: call void @llvm.wasm.rethrow() -} |