[PATCH] D58315: [WebAssembly] Add .shared directive for shared memory

Thomas Lively via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 15 17:09:17 PST 2019


tlively created this revision.
tlively added reviewers: aheejin, sbc100, aardappel.
Herald added subscribers: llvm-commits, sunfish, hiraditya, jgravelle-google, dschuff.
Herald added a project: LLVM.

For object files, emitting the .shared directive sets the shared bit
on the __linear_memory import symbol, so memory flags are also added
to wasm symbols. The directive is emitted in the AsmPrinter if the
thread model is multithreaded to communicate to the linker that this
object is built for a multithreaded context. Depends on D57938 <https://reviews.llvm.org/D57938>.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D58315

Files:
  llvm/include/llvm/BinaryFormat/Wasm.h
  llvm/include/llvm/MC/MCSymbolWasm.h
  llvm/lib/MC/WasmObjectWriter.cpp
  llvm/lib/Target/WebAssembly/AsmParser/WebAssemblyAsmParser.cpp
  llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyTargetStreamer.cpp
  llvm/lib/Target/WebAssembly/MCTargetDesc/WebAssemblyTargetStreamer.h
  llvm/lib/Target/WebAssembly/WebAssemblyAsmPrinter.cpp
  llvm/lib/Target/WebAssembly/WebAssemblyAsmPrinter.h
  llvm/test/MC/WebAssembly/assembler-binary.ll
  llvm/test/MC/WebAssembly/custom-sections.ll
  llvm/test/MC/WebAssembly/event-section.ll
  llvm/test/ObjectYAML/wasm/memory_section.yaml

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D58315.187118.patch
Type: text/x-patch
Size: 10010 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190216/615ebfe0/attachment.bin>


More information about the llvm-commits mailing list