diff options
author | Roman Lebedev <lebedev.ri@gmail.com> | 2021-07-02 11:48:44 +0300 |
---|---|---|
committer | Roman Lebedev <lebedev.ri@gmail.com> | 2021-07-02 11:49:51 +0300 |
commit | c2c0d3ea894328667583155334f0607db0c0a73a (patch) | |
tree | 44389f186d962ab66609d202e3c3e41aa2c6664a /llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp | |
parent | b7c140335beb11bcbb2abe51222d7a300cd365e5 (diff) | |
download | llvm-c2c0d3ea894328667583155334f0607db0c0a73a.zip llvm-c2c0d3ea894328667583155334f0607db0c0a73a.tar.gz llvm-c2c0d3ea894328667583155334f0607db0c0a73a.tar.bz2 |
Revert "[WebAssembly] Implementation of global.get/set for reftypes in LLVM IR"
This reverts commit 4facbf213c51e4add2e8c19b08d5e58ad71c72de.
```
********************
FAIL: LLVM :: CodeGen/WebAssembly/funcref-call.ll (44466 of 44468)
******************** TEST 'LLVM :: CodeGen/WebAssembly/funcref-call.ll' FAILED ********************
Script:
--
: 'RUN: at line 1'; /builddirs/llvm-project/build-Clang12/bin/llc < /repositories/llvm-project/llvm/test/CodeGen/WebAssembly/funcref-call.ll --mtriple=wasm32-unknown-unknown -asm-verbose=false -mattr=+reference-types | /builddirs/llvm-project/build-Clang12/bin/FileCheck /repositories/llvm-project/llvm/test/CodeGen/WebAssembly/funcref-call.ll
--
Exit Code: 2
Command Output (stderr):
--
llc: /repositories/llvm-project/llvm/include/llvm/Support/LowLevelTypeImpl.h:44: static llvm::LLT llvm::LLT::scalar(unsigned int): Assertion `SizeInBits > 0 && "invalid scalar size"' failed.
```
Diffstat (limited to 'llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp')
-rw-r--r-- | llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp b/llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp index 3da80f4..824d336 100644 --- a/llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp +++ b/llvm/lib/Target/WebAssembly/Utils/WebAssemblyUtilities.cpp @@ -116,31 +116,6 @@ MCSymbolWasm *WebAssembly::getOrCreateFunctionTableSymbol( return Sym; } -MCSymbolWasm *WebAssembly::getOrCreateFuncrefCallTableSymbol( - MCContext &Ctx, const WebAssemblySubtarget *Subtarget) { - StringRef Name = "__funcref_call_table"; - MCSymbolWasm *Sym = cast_or_null<MCSymbolWasm>(Ctx.lookupSymbol(Name)); - if (Sym) { - if (!Sym->isFunctionTable()) - Ctx.reportError(SMLoc(), "symbol is not a wasm funcref table"); - } else { - Sym = cast<MCSymbolWasm>(Ctx.getOrCreateSymbol(Name)); - - // Setting Weak ensure only one table is left after linking when multiple - // modules define the table. - Sym->setWeak(true); - - wasm::WasmLimits Limits = {0, 1, 1}; - wasm::WasmTableType TableType = {wasm::WASM_TYPE_FUNCREF, Limits}; - Sym->setType(wasm::WASM_SYMBOL_TYPE_TABLE); - Sym->setTableType(TableType); - } - // MVP object files can't have symtab entries for tables. - if (!(Subtarget && Subtarget->hasReferenceTypes())) - Sym->setOmitFromLinkingSection(); - return Sym; -} - // Find a catch instruction from an EH pad. MachineInstr *WebAssembly::findCatch(MachineBasicBlock *EHPad) { assert(EHPad->isEHPad()); |