diff options
author | Heejin Ahn <aheejin@gmail.com> | 2019-03-19 04:58:59 +0000 |
---|---|---|
committer | Heejin Ahn <aheejin@gmail.com> | 2019-03-19 04:58:59 +0000 |
commit | 802fe81df39f59279e93ea46d547186b40528a64 (patch) | |
tree | c73379fbf7a0c6efb20d120f4f0666af23fb95c4 /clang/test/CodeGen/builtins-wasm.c | |
parent | 9ea0e473f0b96455b918eefcf8fc535638674a1f (diff) | |
download | bcm5719-llvm-802fe81df39f59279e93ea46d547186b40528a64.tar.gz bcm5719-llvm-802fe81df39f59279e93ea46d547186b40528a64.zip |
[WebAssembly] Change wasm.throw's first argument to an immediate
Summary:
`wasm.throw` builtin's first 'tag' argument should be an immediate index
into the event section.
Reviewers: dschuff, craig.topper
Subscribers: sbc100, jgravelle-google, sunfish, cfe-commits
Tags: #clang
Differential Revision: https://reviews.llvm.org/D59448
llvm-svn: 356436
Diffstat (limited to 'clang/test/CodeGen/builtins-wasm.c')
-rw-r--r-- | clang/test/CodeGen/builtins-wasm.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/clang/test/CodeGen/builtins-wasm.c b/clang/test/CodeGen/builtins-wasm.c index 3c5db7268d2..4784d6ff86e 100644 --- a/clang/test/CodeGen/builtins-wasm.c +++ b/clang/test/CodeGen/builtins-wasm.c @@ -38,10 +38,10 @@ void data_drop() { // WEBASSEMBLY64: call void @llvm.wasm.data.drop(i32 3) } -void throw(unsigned int tag, void *obj) { - return __builtin_wasm_throw(tag, obj); - // WEBASSEMBLY32: call void @llvm.wasm.throw(i32 %{{.*}}, i8* %{{.*}}) - // WEBASSEMBLY64: call void @llvm.wasm.throw(i32 %{{.*}}, i8* %{{.*}}) +void throw(void *obj) { + return __builtin_wasm_throw(0, obj); + // WEBASSEMBLY32: call void @llvm.wasm.throw(i32 0, i8* %{{.*}}) + // WEBASSEMBLY64: call void @llvm.wasm.throw(i32 0, i8* %{{.*}}) } void rethrow_in_catch(void) { |