diff options
| author | Derek Schuff <dschuff@google.com> | 2016-12-01 00:11:15 +0000 |
|---|---|---|
| committer | Derek Schuff <dschuff@google.com> | 2016-12-01 00:11:15 +0000 |
| commit | 7747d703e3c21ed2d16ba88382b8fb57389e085a (patch) | |
| tree | 815a2902d55a838231949ddffbb9fd702c46fdff /llvm/test/CodeGen/WebAssembly/globl.ll | |
| parent | dba63a7e5c935506ac6f943c8592f773dcee4ea6 (diff) | |
| download | bcm5719-llvm-7747d703e3c21ed2d16ba88382b8fb57389e085a.tar.gz bcm5719-llvm-7747d703e3c21ed2d16ba88382b8fb57389e085a.zip | |
[WebAssembly] Emit .import_global assembler directives
Support a new assembler directive, .import_global, to declare imported
global variables (i.e. those with external linkage and no
initializer). The linker turns these into wasm imports.
Patch by Jacob Gravelle
Differential Revision: https://reviews.llvm.org/D26875
llvm-svn: 288296
Diffstat (limited to 'llvm/test/CodeGen/WebAssembly/globl.ll')
| -rw-r--r-- | llvm/test/CodeGen/WebAssembly/globl.ll | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/llvm/test/CodeGen/WebAssembly/globl.ll b/llvm/test/CodeGen/WebAssembly/globl.ll index 91d3ade4666..3ebd3d88fb4 100644 --- a/llvm/test/CodeGen/WebAssembly/globl.ll +++ b/llvm/test/CodeGen/WebAssembly/globl.ll @@ -8,3 +8,7 @@ target triple = "wasm32-unknown-unknown" define void @foo() { ret void } + +; Check import directives - must be at the end of the file +; CHECK: .import_global bar{{$}} +@bar = external global i32 |

