summaryrefslogtreecommitdiff
path: root/test/wasm/compress-relocs.ll
diff options
context:
space:
mode:
Diffstat (limited to 'test/wasm/compress-relocs.ll')
-rw-r--r--test/wasm/compress-relocs.ll10
1 files changed, 7 insertions, 3 deletions
diff --git a/test/wasm/compress-relocs.ll b/test/wasm/compress-relocs.ll
index b137d5abd43e..d14ea26a4c33 100644
--- a/test/wasm/compress-relocs.ll
+++ b/test/wasm/compress-relocs.ll
@@ -1,9 +1,11 @@
; RUN: llc -filetype=obj %p/Inputs/call-indirect.ll -o %t2.o
; RUN: llc -filetype=obj %s -o %t.o
-; RUN: wasm-ld -o %t.wasm %t2.o %t.o
+; RUN: wasm-ld --export-dynamic -o %t.wasm %t2.o %t.o
; RUN: obj2yaml %t.wasm | FileCheck %s
-
-; RUN: wasm-ld -O2 -o %t-compressed.wasm %t2.o %t.o
+; RUN: wasm-ld --export-dynamic -O2 -o %t-opt.wasm %t2.o %t.o
+; RUN: obj2yaml %t-opt.wasm | FileCheck %s
+; RUN: not wasm-ld --compress-relocations -o %t-compressed.wasm %t2.o %t.o 2>&1 | FileCheck %s -check-prefix=ERROR
+; RUN: wasm-ld --export-dynamic --strip-debug --compress-relocations -o %t-compressed.wasm %t2.o %t.o
; RUN: obj2yaml %t-compressed.wasm | FileCheck %s -check-prefix=COMPRESS
target triple = "wasm32-unknown-unknown-wasm"
@@ -18,5 +20,7 @@ entry:
ret void
}
+; ERROR: wasm-ld: error: --compress-relocations is incompatible with output debug information. Please pass --strip-debug or --strip-all
+
; CHECK: Body: 4100280284888080002100410028028088808000118080808000001A2000118180808000001A0B
; COMPRESS: Body: 41002802840821004100280280081100001A20001101001A0B