Skip to content

[WebAssembly] Enable type checker in annotations.s #111079

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 4, 2024

Conversation

aheejin
Copy link
Member

@aheejin aheejin commented Oct 4, 2024

No description provided.

@aheejin aheejin requested a review from dschuff October 4, 2024 00:31
@llvmbot llvmbot added backend:WebAssembly mc Machine (object) code labels Oct 4, 2024
@llvmbot
Copy link
Member

llvmbot commented Oct 4, 2024

@llvm/pr-subscribers-mc

@llvm/pr-subscribers-backend-webassembly

Author: Heejin Ahn (aheejin)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/111079.diff

1 Files Affected:

  • (modified) llvm/test/MC/WebAssembly/annotations.s (+9-1)
diff --git a/llvm/test/MC/WebAssembly/annotations.s b/llvm/test/MC/WebAssembly/annotations.s
index 3e727591afa942..59a1349f6eaf20 100644
--- a/llvm/test/MC/WebAssembly/annotations.s
+++ b/llvm/test/MC/WebAssembly/annotations.s
@@ -1,4 +1,4 @@
-# RUN: llvm-mc -no-type-check -triple=wasm32-unknown-unknown -mattr=+exception-handling < %s | FileCheck %s
+# RUN: llvm-mc -triple=wasm32-unknown-unknown -mattr=+exception-handling < %s | FileCheck %s
 
 # Tests if block/loop/try/catch/end/branch/rethrow instructions are correctly
 # printed with their annotations.
@@ -12,15 +12,19 @@ test_annotation:
   try
     br        0
   catch     __cpp_exception
+    drop
     block
+      i32.const 0
       br_if     0
       loop
+        i32.const 0
         br_if     1
       end_loop
     end_block
     try
       rethrow   0
     catch     __cpp_exception
+      drop
     catch_all
       block
         try
@@ -56,15 +60,19 @@ test_annotation:
 # CHECK:        try
 # CHECK-NEXT:   br        0               # 0: down to label0
 # CHECK-NEXT:   catch     __cpp_exception # catch0:
+# CHECK-NEXT:   drop
 # CHECK-NEXT:   block
+# CHECK-NEXT:   i32.const       0
 # CHECK-NEXT:   br_if     0               # 0: down to label1
 # CHECK-NEXT:   loop                      # label2:
+# CHECK-NEXT:   i32.const       0
 # CHECK-NEXT:   br_if     1               # 1: down to label1
 # CHECK-NEXT:   end_loop
 # CHECK-NEXT:   end_block                 # label1:
 # CHECK-NEXT:   try
 # CHECK-NEXT:   rethrow   0               # down to catch3
 # CHECK-NEXT:   catch     __cpp_exception # catch3:
+# CHECK-NEXT:   drop
 # CHECK-NEXT:   catch_all{{$}}
 # CHECK-NEXT:   block
 # CHECK-NEXT:   try

@aheejin aheejin merged commit 643df05 into llvm:main Oct 4, 2024
12 checks passed
@aheejin aheejin deleted the enable_tc_in_tests branch October 4, 2024 17:32
aheejin added a commit to aheejin/llvm-project that referenced this pull request Oct 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend:WebAssembly mc Machine (object) code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants