summaryrefslogtreecommitdiffstats
path: root/llvm/test/CodeGen/WebAssembly/globl.ll
diff options
context:
space:
mode:
authorDan Gohman <dan433584@gmail.com>2017-12-05 17:21:57 +0000
committerDan Gohman <dan433584@gmail.com>2017-12-05 17:21:57 +0000
commitf7172f4ab095c641c36ce205d6c7e965b2b5b67c (patch)
treeb9b317b0b1e6403a5ac8fdbc3358ca0a6d77e539 /llvm/test/CodeGen/WebAssembly/globl.ll
parent06be6debbc005a45493c81643729b32bd3754f38 (diff)
downloadbcm5719-llvm-f7172f4ab095c641c36ce205d6c7e965b2b5b67c.tar.gz
bcm5719-llvm-f7172f4ab095c641c36ce205d6c7e965b2b5b67c.zip
[WebAssembly] Don't emit .import_global for the wasm target.
.import_global is used by the ELF-based target and not needed by the wasm target. llvm-svn: 319796
Diffstat (limited to 'llvm/test/CodeGen/WebAssembly/globl.ll')
-rw-r--r--llvm/test/CodeGen/WebAssembly/globl.ll13
1 files changed, 8 insertions, 5 deletions
diff --git a/llvm/test/CodeGen/WebAssembly/globl.ll b/llvm/test/CodeGen/WebAssembly/globl.ll
index ba9f6659d7d..c3126d55863 100644
--- a/llvm/test/CodeGen/WebAssembly/globl.ll
+++ b/llvm/test/CodeGen/WebAssembly/globl.ll
@@ -4,11 +4,14 @@ target datalayout = "e-m:e-p:32:32-i64:64-n32:64-S128"
target triple = "wasm32-unknown-unknown-wasm"
; CHECK: .globl foo
+; CHECK: .type foo,@function
; CHECK-LABEL: foo:
-define void @foo() {
- ret void
+; CHECK: .size foo,
+define i32* @foo() {
+ ret i32* @bar
}
-; Check import directives - must be at the end of the file
-; CHECK: .import_global bar{{$}}
-@bar = external global i32
+; CHECK: .type bar,@object
+; CHECK: .globl bar
+; CHECK: .size bar, 4
+@bar = global i32 2
OpenPOWER on IntegriCloud