[PATCH] D63955: [WebAssembly] Allow @object in .type directives.
Wouter van Oortmerssen via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 28 13:48:14 PDT 2019
aardappel created this revision.
aardappel added a reviewer: sbc100.
Herald added subscribers: llvm-commits, sunfish, aheejin, jgravelle-google, dschuff.
Herald added a project: LLVM.
Repository:
rL LLVM
https://reviews.llvm.org/D63955
Files:
lib/MC/MCParser/WasmAsmParser.cpp
test/MC/WebAssembly/basic-assembly.s
Index: test/MC/WebAssembly/basic-assembly.s
===================================================================
--- test/MC/WebAssembly/basic-assembly.s
+++ test/MC/WebAssembly/basic-assembly.s
@@ -91,6 +91,7 @@
.section .rodata..L.str,"",@
.hidden .L.str
+ .type .L.str, at object
.L.str:
.int8 'H'
.asciz "ello, World!"
Index: lib/MC/MCParser/WasmAsmParser.cpp
===================================================================
--- lib/MC/MCParser/WasmAsmParser.cpp
+++ lib/MC/MCParser/WasmAsmParser.cpp
@@ -187,6 +187,8 @@
WasmSym->setType(wasm::WASM_SYMBOL_TYPE_FUNCTION);
else if (TypeName == "global")
WasmSym->setType(wasm::WASM_SYMBOL_TYPE_GLOBAL);
+ else if (TypeName == "object")
+ WasmSym->setType(wasm::WASM_SYMBOL_TYPE_DATA);
else
return error("Unknown WASM symbol type: ", Lexer->getTok());
Lex();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63955.207141.patch
Type: text/x-patch
Size: 904 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190628/e5a7d6f2/attachment.bin>
More information about the llvm-commits
mailing list