reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

lib/Object/WasmObjectFile.cpp
  491     Info.Kind = readUint8(Ctx);
  492     Info.Flags = readVaruint32(Ctx);
  493     bool IsDefined = (Info.Flags & wasm::WASM_SYMBOL_UNDEFINED) == 0;
  495     switch (Info.Kind) {
  497       Info.ElementIndex = readVaruint32(Ctx);
  498       if (!isValidFunctionIndex(Info.ElementIndex) ||
  499           IsDefined != isDefinedFunctionIndex(Info.ElementIndex))
  503         Info.Name = readString(Ctx);
  504         unsigned FuncIndex = Info.ElementIndex - NumImportedFunctions;
  508           Function.SymbolName = Info.Name;
  510         wasm::WasmImport &Import = *ImportedFunctions[Info.ElementIndex];
  511         if ((Info.Flags & wasm::WASM_SYMBOL_EXPLICIT_NAME) != 0)
  512           Info.Name = readString(Ctx);
  514           Info.Name = Import.Field;
  516         Info.ImportName = Import.Field;
  517         Info.ImportModule = Import.Module;
  522       Info.ElementIndex = readVaruint32(Ctx);
  523       if (!isValidGlobalIndex(Info.ElementIndex) ||
  524           IsDefined != isDefinedGlobalIndex(Info.ElementIndex))
  527       if (!IsDefined && (Info.Flags & wasm::WASM_SYMBOL_BINDING_MASK) ==
  532         Info.Name = readString(Ctx);
  533         unsigned GlobalIndex = Info.ElementIndex - NumImportedGlobals;
  537           Global.SymbolName = Info.Name;
  539         wasm::WasmImport &Import = *ImportedGlobals[Info.ElementIndex];
  540         if ((Info.Flags & wasm::WASM_SYMBOL_EXPLICIT_NAME) != 0)
  541           Info.Name = readString(Ctx);
  543           Info.Name = Import.Field;
  545         Info.ImportName = Import.Field;
  546         Info.ImportModule = Import.Module;
  551       Info.Name = readString(Ctx);
  562         Info.DataRef = wasm::WasmDataReference{Index, Offset, Size};
  567       if ((Info.Flags & wasm::WASM_SYMBOL_BINDING_MASK) !=
  572       Info.ElementIndex = readVaruint32(Ctx);
  574       StringRef SectionName = Sections[Info.ElementIndex].Name;
  575       Info.Name = SectionName;
  580       Info.ElementIndex = readVaruint32(Ctx);
  581       if (!isValidEventIndex(Info.ElementIndex) ||
  582           IsDefined != isDefinedEventIndex(Info.ElementIndex))
  585       if (!IsDefined && (Info.Flags & wasm::WASM_SYMBOL_BINDING_MASK) ==
  590         Info.Name = readString(Ctx);
  591         unsigned EventIndex = Info.ElementIndex - NumImportedEvents;
  596           Event.SymbolName = Info.Name;
  599         wasm::WasmImport &Import = *ImportedEvents[Info.ElementIndex];
  600         if ((Info.Flags & wasm::WASM_SYMBOL_EXPLICIT_NAME) != 0)
  601           Info.Name = readString(Ctx);
  603           Info.Name = Import.Field;
  606         Info.ImportName = Import.Field;
  607         Info.ImportModule = Import.Module;
  617     if ((Info.Flags & wasm::WASM_SYMBOL_BINDING_MASK) !=
  619         !SymbolNames.insert(Info.Name).second)
  621                                                 Twine(Info.Name),
  623     LinkingData.SymbolTable.emplace_back(Info);