From ff363539c637c3078e3b6be886184ce327d2773a Mon Sep 17 00:00:00 2001 From: Heejin Ahn Date: Wed, 22 Aug 2018 18:22:45 +0000 Subject: [PATCH] [WebAssembly] Add hasSideEffects flag to catch instructions Summary: `catch` instruction certainly has rather huge side effects and the flag was missing. At the moment this does not change any unit tests we currently have. Reviewers: dschuff Subscribers: sbc100, jgravelle-google, sunfish, llvm-commits Differential Revision: https://reviews.llvm.org/D50919 llvm-svn: 340433 --- llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td b/llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td index a987906e0878..a8fce89f2034 100644 --- a/llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td +++ b/llvm/lib/Target/WebAssembly/WebAssemblyInstrControl.td @@ -172,7 +172,7 @@ defm END_TRY : NRI<(outs), (ins), [], "end_try", 0x0b>; } // Uses = [VALUE_STACK], Defs = [VALUE_STACK] // Catching an exception: catch / catch_all -let hasCtrlDep = 1 in { +let hasCtrlDep = 1, hasSideEffects = 1 in { defm CATCH_I32 : I<(outs I32:$dst), (ins i32imm:$tag), (outs), (ins i32imm:$tag), [(set I32:$dst, (int_wasm_catch imm:$tag))],