diff options
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()); |