mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 03:02:36 +01:00
d8d06a1305
See https://github.com/WebAssembly/tool-conventions/pull/95. This is less typing and IMHO more readable, and it also fits with our naming around the binary format which tends to use the short name. e.g. include/llvm/BinaryFormat/Wasm.h tools/llvm-objdump/WasmDump.cpp etc.. Differential Revision: https://reviews.llvm.org/D57611 llvm-svn: 353062
24 lines
731 B
LLVM
24 lines
731 B
LLVM
; RUN: llc -filetype=obj %s -o - | obj2yaml | FileCheck %s
|
|
|
|
target triple = "wasm32-unknown-unknown"
|
|
|
|
; Function that uses explict stack, and should generate a reference to
|
|
; __stack_pointer, along with the corresponding reloction entry.
|
|
define hidden void @foo() #0 {
|
|
entry:
|
|
alloca i32, align 4
|
|
ret void
|
|
}
|
|
|
|
; CHECK: - Type: IMPORT
|
|
; CHECK: Imports:
|
|
; CHECK: - Module: env
|
|
; CHECK: Field: __stack_pointer
|
|
; CHECK: Kind: GLOBAL
|
|
; CHECK: GlobalType: I32
|
|
; CHECK: GlobalMutable: true
|
|
; CHECK: - Type: CODE
|
|
; CHECK: Relocations:
|
|
; CHECK: - Type: R_WASM_GLOBAL_INDEX_LEB
|
|
; CHECK: Index: 0
|