/openbsd/gnu/llvm/llvm/include/llvm/BinaryFormat/ |
H A D | WasmTraits.h | 23 static wasm::WasmSignature getEmptyKey() { 24 wasm::WasmSignature Sig; 25 Sig.State = wasm::WasmSignature::Empty; 29 wasm::WasmSignature Sig; 49 static wasm::WasmGlobalType getEmptyKey() { 50 return wasm::WasmGlobalType{1, true}; 53 return wasm::WasmGlobalType{2, true}; 66 static wasm::WasmLimits getEmptyKey() { 88 static wasm::WasmTableType getEmptyKey() { 89 return wasm::WasmTableType{ [all …]
|
/openbsd/gnu/llvm/llvm/lib/Target/WebAssembly/Utils/ |
H A D | WebAssemblyTypeUtilities.cpp | 28 return wasm::ValType::I32; in parseType() 30 return wasm::ValType::I64; in parseType() 32 return wasm::ValType::F32; in parseType() 34 return wasm::ValType::F64; in parseType() 79 case wasm::WASM_TYPE_I32: in anyTypeToString() 81 case wasm::WASM_TYPE_I64: in anyTypeToString() 83 case wasm::WASM_TYPE_F32: in anyTypeToString() 85 case wasm::WASM_TYPE_F64: in anyTypeToString() 87 case wasm::WASM_TYPE_V128: in anyTypeToString() 93 case wasm::WASM_TYPE_FUNC: in anyTypeToString() [all …]
|
H A D | WebAssemblyTypeUtilities.h | 33 I32 = unsigned(wasm::ValType::I32), 34 I64 = unsigned(wasm::ValType::I64), 35 F32 = unsigned(wasm::ValType::F32), 36 F64 = unsigned(wasm::ValType::F64), 37 V128 = unsigned(wasm::ValType::V128), 39 Funcref = unsigned(wasm::ValType::FUNCREF), 85 inline bool isRefType(wasm::ValType Type) { in isRefType() 86 return Type == wasm::ValType::EXTERNREF || Type == wasm::ValType::FUNCREF; in isRefType() 101 const char *typeToString(wasm::ValType Type); 111 wasm::ValType toValType(MVT Type); [all …]
|
/openbsd/gnu/llvm/llvm/include/llvm/MC/ |
H A D | MCSymbolWasm.h | 17 std::optional<wasm::WasmSymbolType> Type; 27 wasm::WasmSignature *Signature = nullptr; 28 std::optional<wasm::WasmGlobalType> GlobalType; 29 std::optional<wasm::WasmTableType> TableType; 59 modifyFlags(wasm::WASM_SYMBOL_EXPORTED, wasm::WASM_SYMBOL_EXPORTED); in setExported() 66 modifyFlags(wasm::WASM_SYMBOL_NO_STRIP, wasm::WASM_SYMBOL_NO_STRIP); in setNoStrip() 71 modifyFlags(wasm::WASM_SYMBOL_TLS, wasm::WASM_SYMBOL_TLS); in setTLS() 118 setType(wasm::WASM_SYMBOL_TYPE_TABLE); in setFunctionTable() 119 setTableType(wasm::ValType::FUNCREF); in setFunctionTable() 143 void setTableType(wasm::ValType VT) { in setTableType() [all …]
|
/openbsd/gnu/llvm/llvm/lib/Target/WebAssembly/ |
H A D | WebAssemblyRuntimeLibcallSignatures.cpp | 527 wasm::ValType PtrTy = in getLibcallSignature() 528 Subtarget.hasAddr64() ? wasm::ValType::I64 : wasm::ValType::I32; in getLibcallSignature() 535 Rets.push_back(wasm::ValType::F32); in getLibcallSignature() 539 Rets.push_back(wasm::ValType::F32); in getLibcallSignature() 543 Rets.push_back(wasm::ValType::F32); in getLibcallSignature() 547 Rets.push_back(wasm::ValType::F32); in getLibcallSignature() 551 Rets.push_back(wasm::ValType::F32); in getLibcallSignature() 555 Rets.push_back(wasm::ValType::F64); in getLibcallSignature() 559 Rets.push_back(wasm::ValType::F64); in getLibcallSignature() 563 Rets.push_back(wasm::ValType::F64); in getLibcallSignature() [all …]
|
H A D | WebAssemblyAsmPrinter.cpp | 112 case wasm::ValType::I32: in getInvokeSig() 114 case wasm::ValType::I64: in getInvokeSig() 116 case wasm::ValType::F32: in getInvokeSig() 118 case wasm::ValType::F64: in getInvokeSig() 120 case wasm::ValType::V128: in getInvokeSig() 122 case wasm::ValType::FUNCREF: in getInvokeSig() 124 case wasm::ValType::EXTERNREF: in getInvokeSig() 259 wasm::ValType AddrType = in getOrCreateWasmSymbol() 260 Subtarget.hasAddr64() ? wasm::ValType::I64 : wasm::ValType::I32; in getOrCreateWasmSymbol() 283 case wasm::WASM_SYMBOL_TYPE_TAG: in emitSymbolType() [all …]
|
/openbsd/gnu/llvm/llvm/include/llvm/Object/ |
H A D | Wasm.h | 44 const wasm::WasmSymbolInfo &Info; 45 const wasm::WasmGlobalType *GlobalType; 46 const wasm::WasmTableType *TableType; 47 const wasm::WasmSignature *Signature; 117 wasm::WasmDataSegment Data; 269 wasm::WasmObjectHeader Header; 271 wasm::WasmDylinkInfo DylinkInfo; 272 wasm::WasmProducerInfo ProducerInfo; 275 std::vector<wasm::WasmTable> Tables; 278 std::vector<wasm::WasmTag> Tags; [all …]
|
/openbsd/gnu/llvm/llvm/lib/Target/WebAssembly/MCTargetDesc/ |
H A D | WebAssemblyWasmObjectWriter.cpp | 78 return wasm::R_WASM_GLOBAL_INDEX_LEB; in getRelocType() 91 return wasm::R_WASM_TYPE_INDEX_LEB; in getRelocType() 102 return wasm::R_WASM_TABLE_INDEX_SLEB; in getRelocType() 103 return wasm::R_WASM_MEMORY_ADDR_SLEB; in getRelocType() 107 return wasm::R_WASM_MEMORY_ADDR_SLEB64; in getRelocType() 114 return wasm::R_WASM_TAG_INDEX_LEB; in getRelocType() 117 return wasm::R_WASM_MEMORY_ADDR_LEB; in getRelocType() 120 return wasm::R_WASM_MEMORY_ADDR_LEB64; in getRelocType() 126 return wasm::R_WASM_TABLE_INDEX_I32; in getRelocType() 143 return wasm::R_WASM_TABLE_INDEX_I64; in getRelocType() [all …]
|
H A D | WebAssemblyTargetStreamer.cpp | 30 void WebAssemblyTargetStreamer::emitValueType(wasm::ValType Type) { in emitValueType() 42 ArrayRef<wasm::ValType> Types) { in printTypes() 54 void WebAssemblyTargetAsmStreamer::emitLocal(ArrayRef<wasm::ValType> Types) { in emitLocal() 72 static_cast<wasm::ValType>(Sym->getGlobalType().Type)); in emitGlobalType() 80 const wasm::WasmTableType &Type = Sym->getTableType(); in emitTableType() 82 << WebAssembly::typeToString(static_cast<wasm::ValType>(Type.ElemType)); in emitTableType() 83 bool HasMaximum = Type.Limits.Flags & wasm::WASM_LIMITS_FLAG_HAS_MAX; in emitTableType() 121 void WebAssemblyTargetWasmStreamer::emitLocal(ArrayRef<wasm::ValType> Types) { in emitLocal() 122 SmallVector<std::pair<wasm::ValType, uint32_t>, 4> Grouped; in emitLocal()
|
/openbsd/gnu/llvm/llvm/lib/Object/ |
H A D | WasmObjectFile.cpp | 188 wasm::ValType Ty = static_cast<wasm::ValType>(readULEB128(Ctx)); in readInitExpr() 240 wasm::WasmLimits Result; in readLimits() 340 case wasm::WASM_SEC_TYPE: in parseSection() 350 case wasm::WASM_SEC_TAG: in parseSection() 358 case wasm::WASM_SEC_ELEM: in parseSection() 467 wasm::NameType nameType = wasm::NameType::FUNCTION; in parseNameSection() 1115 wasm::WasmImport Im; in parseImportSection() 1178 wasm::WasmFunction F; in parseFunctionSection() 1193 wasm::WasmTable T; in parseTableSection() 1238 wasm::WasmTag Tag; in parseTagSection() [all …]
|
H A D | RelocationResolver.cpp | 676 case wasm::R_WASM_TABLE_INDEX_I32: in supportsWasm32() 677 case wasm::R_WASM_MEMORY_ADDR_LEB: in supportsWasm32() 679 case wasm::R_WASM_MEMORY_ADDR_I32: in supportsWasm32() 680 case wasm::R_WASM_TYPE_INDEX_LEB: in supportsWasm32() 684 case wasm::R_WASM_TAG_INDEX_LEB: in supportsWasm32() 698 case wasm::R_WASM_MEMORY_ADDR_I64: in supportsWasm64() 700 case wasm::R_WASM_TABLE_INDEX_I64: in supportsWasm64() 713 case wasm::R_WASM_TABLE_INDEX_I32: in resolveWasm32() 714 case wasm::R_WASM_MEMORY_ADDR_LEB: in resolveWasm32() 717 case wasm::R_WASM_TYPE_INDEX_LEB: in resolveWasm32() [all …]
|
/openbsd/gnu/llvm/llvm/lib/MC/ |
H A D | WasmObjectWriter.cpp | 80 wasm::WasmGlobalType Type; 451 W->OS.write(wasm::WasmMagic, sizeof(wasm::WasmMagic)); in writeHeader() 853 uint64_t NumPages = (DataSize + wasm::WasmPageSize - 1) / wasm::WasmPageSize; in writeImportSection() 939 case wasm::WASM_TYPE_I32: in writeGlobalSection() 1274 wasm::WasmSignature S; in registerFunctionType() 1296 wasm::WasmSignature S; in registerTagType() 1337 wasm::WasmImport MemImport; in prepareImports() 1422 wasm::WasmImport Import; in prepareImports() 1645 wasm::WasmDataReference Ref = wasm::WasmDataReference{ in writeOneObject() 1760 wasm::WasmDataReference Ref = wasm::WasmDataReference{ in writeOneObject() [all …]
|
/openbsd/gnu/llvm/llvm/lib/BinaryFormat/ |
H A D | Wasm.cpp | 11 llvm::StringRef llvm::wasm::toString(wasm::WasmSymbolType Type) { in toString() 13 case wasm::WASM_SYMBOL_TYPE_FUNCTION: in toString() 15 case wasm::WASM_SYMBOL_TYPE_GLOBAL: in toString() 17 case wasm::WASM_SYMBOL_TYPE_TABLE: in toString() 19 case wasm::WASM_SYMBOL_TYPE_DATA: in toString() 21 case wasm::WASM_SYMBOL_TYPE_SECTION: in toString() 23 case wasm::WASM_SYMBOL_TYPE_TAG: in toString() 29 llvm::StringRef llvm::wasm::relocTypetoString(uint32_t Type) { in relocTypetoString() 41 llvm::StringRef llvm::wasm::sectionTypeToString(uint32_t Type) { in sectionTypeToString() 43 case wasm::WASM_SEC_##X: \ in sectionTypeToString() [all …]
|
/openbsd/gnu/llvm/lld/wasm/ |
H A D | WriterUtils.h | 17 namespace wasm { 38 void writeValueType(raw_ostream &os, llvm::wasm::ValType type, 41 void writeSig(raw_ostream &os, const llvm::wasm::WasmSignature &sig); 55 const llvm::wasm::WasmInitExprMVP &initExpr); 57 void writeLimits(raw_ostream &os, const llvm::wasm::WasmLimits &limits); 63 void writeImport(raw_ostream &os, const llvm::wasm::WasmImport &import); 65 void writeExport(raw_ostream &os, const llvm::wasm::WasmExport &export_); 69 std::string toString(llvm::wasm::ValType type); 70 std::string toString(const llvm::wasm::WasmSignature &sig); 71 std::string toString(const llvm::wasm::WasmGlobalType &type); [all …]
|
H A D | SyntheticSections.h | 28 namespace wasm { 137 static lld::wasm::ImportKey<T> getEmptyKey() { 139 key.state = lld::wasm::ImportKey<T>::State::Empty; 142 static lld::wasm::ImportKey<T> getTombstoneKey() { 144 key.state = lld::wasm::ImportKey<T>::State::Tombstone; 154 static bool isEqual(const lld::wasm::ImportKey<T> &lhs, 155 const lld::wasm::ImportKey<T> &rhs) { 162 namespace wasm { 265 return sec->type == llvm::wasm::WASM_SEC_GLOBAL; 317 std::vector<llvm::wasm::WasmExport> exports; [all …]
|
H A D | OutputSections.h | 20 namespace wasm { 23 std::string toString(const wasm::OutputSection §ion); 25 namespace wasm { 59 : OutputSection(llvm::wasm::WASM_SEC_CODE), functions(functions) {} in CodeSection() 62 return sec->type == llvm::wasm::WASM_SEC_CODE; in classof() 82 : OutputSection(llvm::wasm::WASM_SEC_DATA), segments(segments) {} in DataSection() 85 return sec->type == llvm::wasm::WASM_SEC_DATA; in classof() 112 : OutputSection(llvm::wasm::WASM_SEC_CUSTOM, name), in CustomSection() 116 return sec->type == llvm::wasm::WASM_SEC_CUSTOM; in classof()
|
/openbsd/gnu/llvm/llvm/lib/Target/WebAssembly/AsmParser/ |
H A D | WebAssemblyAsmTypeCheck.h | 31 SmallVector<wasm::ValType, 8> Stack; 32 SmallVector<wasm::ValType, 16> LocalTypes; 33 SmallVector<wasm::ValType, 4> ReturnTypes; 34 wasm::WasmSignature LastSig; 41 bool popType(SMLoc ErrorLoc, std::optional<wasm::ValType> EVT); 43 bool getLocal(SMLoc ErrorLoc, const MCInst &Inst, wasm::ValType &Type); 45 bool checkSig(SMLoc ErrorLoc, const wasm::WasmSignature &Sig); 49 bool getTable(SMLoc ErrorLoc, const MCInst &Inst, wasm::ValType &Type); 54 void funcDecl(const wasm::WasmSignature &Sig); 55 void localDecl(const SmallVector<wasm::ValType, 4> &Locals); [all …]
|
H A D | WebAssemblyAsmTypeCheck.cpp | 174 case wasm::WASM_SYMBOL_TYPE_GLOBAL: in getGlobal() 177 case wasm::WASM_SYMBOL_TYPE_FUNCTION: in getGlobal() 178 case wasm::WASM_SYMBOL_TYPE_DATA: in getGlobal() 182 Type = is64 ? wasm::ValType::I64 : wasm::ValType::I32; in getGlobal() 202 wasm::WASM_SYMBOL_TYPE_TABLE) in getTable() 228 wasm::ValType Type; in typeCheck() 256 if (popType(ErrorLoc, wasm::ValType::I32)) in typeCheck() 264 if (popType(ErrorLoc, wasm::ValType::I32)) in typeCheck() 269 if (popType(ErrorLoc, wasm::ValType::I32)) in typeCheck() 273 if (popType(ErrorLoc, wasm::ValType::I32)) in typeCheck() [all …]
|
/openbsd/gnu/llvm/llvm/tools/obj2yaml/ |
H A D | wasm2yaml.cpp | 206 case wasm::WASM_SEC_CUSTOM: { in dump() 215 case wasm::WASM_SEC_TYPE: { in dump() 230 case wasm::WASM_SEC_IMPORT: { in dump() 270 case wasm::WASM_SEC_TABLE: { in dump() 278 case wasm::WASM_SEC_MEMORY: { in dump() 286 case wasm::WASM_SEC_TAG: { in dump() 294 case wasm::WASM_SEC_GLOBAL: { in dump() 312 case wasm::WASM_SEC_START: { in dump() 330 case wasm::WASM_SEC_ELEM: { in dump() 349 case wasm::WASM_SEC_CODE: { in dump() [all …]
|
/openbsd/gnu/llvm/llvm/lib/ObjectYAML/ |
H A D | WasmYAML.cpp | 209 case wasm::WASM_SEC_TYPE: in mapping() 214 case wasm::WASM_SEC_IMPORT: in mapping() 224 case wasm::WASM_SEC_TABLE: in mapping() 229 case wasm::WASM_SEC_MEMORY: in mapping() 234 case wasm::WASM_SEC_TAG: in mapping() 239 case wasm::WASM_SEC_GLOBAL: in mapping() 249 case wasm::WASM_SEC_START: in mapping() 254 case wasm::WASM_SEC_ELEM: in mapping() 259 case wasm::WASM_SEC_CODE: in mapping() 264 case wasm::WASM_SEC_DATA: in mapping() [all …]
|
H A D | WasmEmitter.cpp | 138 case wasm::WASM_OPCODE_I32_CONST: in writeInitExpr() 141 case wasm::WASM_OPCODE_I64_CONST: in writeInitExpr() 144 case wasm::WASM_OPCODE_F32_CONST: in writeInitExpr() 147 case wasm::WASM_OPCODE_F64_CONST: in writeInitExpr() 396 case wasm::WASM_EXTERNAL_GLOBAL: in writeSectionContent() 401 case wasm::WASM_EXTERNAL_TAG: in writeSectionContent() 409 case wasm::WASM_EXTERNAL_TABLE: in writeSectionContent() 568 case wasm::WASM_SEC_CODE: in writeRelocSection() 571 case wasm::WASM_SEC_DATA: in writeRelocSection() 574 case wasm::WASM_SEC_CUSTOM: { in writeRelocSection() [all …]
|
/openbsd/gnu/llvm/lld/include/lld/Common/ |
H A D | LLVM.h | 46 namespace wasm { 89 using llvm::wasm::WasmFunction; 90 using llvm::wasm::WasmGlobal; 91 using llvm::wasm::WasmGlobalType; 92 using llvm::wasm::WasmInitExpr; 93 using llvm::wasm::WasmLimits; 94 using llvm::wasm::WasmRelocation; 95 using llvm::wasm::WasmSignature; 96 using llvm::wasm::WasmTable; 97 using llvm::wasm::WasmTableType; [all …]
|
/openbsd/gnu/llvm/llvm/lib/ObjCopy/ |
H A D | CMakeLists.txt | 13 source_group("Header Files\\wasm" REGULAR_EXPRESSION 14 wasm/.*[.]h 31 source_group("Source Files\\wasm" REGULAR_EXPRESSION 32 wasm/.*[.]cpp 54 wasm/WasmObject.cpp 55 wasm/WasmReader.cpp 56 wasm/WasmWriter.cpp 57 wasm/WasmObjcopy.cpp 67 ${LLVM_MAIN_INCLUDE_DIR}/llvm/ObjCopy/wasm 72 wasm
|
/openbsd/gnu/llvm/llvm/tools/llvm-readobj/ |
H A D | WasmDumper.cpp | 25 { #X, wasm::WASM_SYMBOL_TYPE_##X } 33 { #X, wasm::WASM_SEC_##X } 44 { #X, wasm::WASM_SYMBOL_##X } 163 case wasm::WASM_SEC_CUSTOM: in printSectionHeaders() 174 case wasm::WASM_SEC_DATA: { in printSectionHeaders() 177 const wasm::WasmDataSegment &Seg = Segment.Data; in printSectionHeaders() 196 case wasm::WASM_SEC_MEMORY: in printSectionHeaders() 198 for (const wasm::WasmLimits &Memory : Obj->memories()) { in printSectionHeaders() 201 if (Memory.Flags & wasm::WASM_LIMITS_FLAG_HAS_MAX) { in printSectionHeaders() 227 if (Symbol.Info.Flags & wasm::WASM_SYMBOL_UNDEFINED) { in printSymbol() [all …]
|
/openbsd/gnu/llvm/llvm/include/llvm/ObjectYAML/ |
H A D | WasmYAML.h | 69 wasm::WasmInitExprMVP Inst; 155 SignatureForm Form = wasm::WASM_TYPE_FUNC; 167 wasm::WasmDataReference DataRef; 199 return S->Type == wasm::WASM_SEC_CUSTOM; in classof() 290 return S->Type == wasm::WASM_SEC_TYPE; in classof() 320 return S->Type == wasm::WASM_SEC_TABLE; in classof() 340 return S->Type == wasm::WASM_SEC_TAG; in classof() 370 return S->Type == wasm::WASM_SEC_START; in classof() 380 return S->Type == wasm::WASM_SEC_ELEM; in classof() 390 return S->Type == wasm::WASM_SEC_CODE; in classof() [all …]
|