• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-12-stable/contrib/llvm-project/llvm/lib/MC/

Lines Matching refs:WS

414     const auto &WS = static_cast<const MCSymbolWasm &>(S);
415 if (WS.isDefined() && WS.isFunction() && !WS.isVariable()) {
1145 const auto &WS = static_cast<const MCSymbolWasm &>(S);
1149 if (WS.isFunction())
1150 registerFunctionType(WS);
1152 if (WS.isEvent())
1153 registerEventType(WS);
1155 if (WS.isTemporary())
1159 if (!WS.isDefined() && !WS.isComdat()) {
1160 if (WS.isFunction()) {
1162 Import.Module = WS.getImportModule();
1163 Import.Field = WS.getImportName();
1165 Import.SigIndex = getFunctionType(WS);
1167 assert(WasmIndices.count(&WS) == 0);
1168 WasmIndices[&WS] = NumFunctionImports++;
1169 } else if (WS.isGlobal()) {
1170 if (WS.isWeak())
1174 Import.Field = WS.getImportName();
1176 Import.Module = WS.getImportModule();
1177 Import.Global = WS.getGlobalType();
1179 assert(WasmIndices.count(&WS) == 0);
1180 WasmIndices[&WS] = NumGlobalImports++;
1181 } else if (WS.isEvent()) {
1182 if (WS.isWeak())
1186 Import.Module = WS.getImportModule();
1187 Import.Field = WS.getImportName();
1190 Import.Event.SigIndex = getEventType(WS);
1192 assert(WasmIndices.count(&WS) == 0);
1193 WasmIndices[&WS] = NumEventImports++;
1200 const auto &WS = static_cast<const MCSymbolWasm &>(S);
1201 if (WS.isUsedInGOT()) {
1203 if (WS.isFunction())
1207 Import.Field = WS.getName();
1211 assert(GOTIndices.count(&WS) == 0);
1212 GOTIndices[&WS] = NumGlobalImports++;
1290 const auto &WS = static_cast<const MCSymbolWasm &>(S);
1292 dbgs() << "MCSymbol: " << toString(WS.getType()) << " '" << S << "'"
1295 << " isWeak=" << WS.isWeak() << " isHidden=" << WS.isHidden()
1296 << " isVariable=" << WS.isVariable() << "\n");
1298 if (WS.isVariable())
1300 if (WS.isComdat() && !WS.isDefined())
1303 if (WS.isFunction()) {
1305 if (WS.isDefined()) {
1306 if (WS.getOffset() != 0)
1310 if (WS.getSize() == nullptr)
1317 Func.SigIndex = getFunctionType(WS);
1318 Func.Sym = &WS;
1319 WasmIndices[&WS] = Index;
1322 auto &Section = static_cast<MCSectionWasm &>(WS.getSection());
1328 if (WS.hasExportName()) {
1330 Export.Name = WS.getExportName();
1337 Index = WasmIndices.find(&WS)->second;
1342 } else if (WS.isData()) {
1343 if (!isInSymtab(WS))
1346 if (!WS.isDefined()) {
1352 if (!WS.getSize())
1354 WS.getName());
1357 if (!WS.getSize()->evaluateAsAbsolute(Size, Layout))
1360 auto &DataSection = static_cast<MCSectionWasm &>(WS.getSection());
1363 WS.getName());
1369 static_cast<uint32_t>(Layout.getSymbolOffset(WS)),
1371 DataLocations[&WS] = Ref;
1374 } else if (WS.isGlobal()) {
1376 if (WS.isDefined())
1381 << WasmIndices.find(&WS)->second << "\n");
1383 } else if (WS.isEvent()) {
1386 if (WS.isDefined()) {
1389 Event.SigIndex = getEventType(WS);
1391 assert(WasmIndices.count(&WS) == 0);
1392 WasmIndices[&WS] = Index;
1396 assert(WasmIndices.count(&WS) > 0);
1398 LLVM_DEBUG(dbgs() << " -> event index: " << WasmIndices.find(&WS)->second
1402 assert(WS.isSection());
1417 const auto &WS = static_cast<const MCSymbolWasm &>(S);
1418 const MCSymbolWasm *ResolvedSym = resolveSymbol(WS);
1419 LLVM_DEBUG(dbgs() << WS.getName() << ": weak alias of '" << *ResolvedSym
1425 assert(WasmIndices.count(&WS) == 0);
1426 WasmIndices[&WS] = WasmIndex;
1432 DataLocations[&WS] = Ref;
1441 const auto &WS = static_cast<const MCSymbolWasm &>(S);
1442 if (!isInSymtab(WS)) {
1443 WS.setIndex(InvalidIndex);
1446 LLVM_DEBUG(dbgs() << "adding to symtab: " << WS << "\n");
1449 if (WS.isWeak())
1451 if (WS.isHidden())
1453 if (!WS.isExternal() && WS.isDefined())
1455 if (WS.isUndefined())
1457 if (WS.isNoStrip()) {
1463 if (WS.hasImportName())
1465 if (WS.hasExportName())
1469 Info.Name = WS.getName();
1470 Info.Kind = WS.getType();
1472 if (!WS.isData()) {
1473 assert(WasmIndices.count(&WS) > 0);
1474 Info.ElementIndex = WasmIndices.find(&WS)->second;
1475 } else if (WS.isDefined()) {
1476 assert(DataLocations.count(&WS) > 0);
1477 Info.DataRef = DataLocations.find(&WS)->second;
1479 WS.setIndex(SymbolInfos.size());
1492 const MCSymbolWasm &WS = *resolveSymbol(*Rel.Symbol);
1493 uint32_t FunctionIndex = WasmIndices.find(&WS)->second;
1495 if (TableIndices.try_emplace(&WS, TableIndex).second) {
1496 LLVM_DEBUG(dbgs() << " -> adding " << WS.getName()
1499 registerFunctionType(WS);
1511 const auto &WS = static_cast<const MCSectionWasm &>(S);
1512 if (WS.getSectionName().startswith(".fini_array"))
1514 if (!WS.getSectionName().startswith(".init_array"))
1516 if (WS.getFragmentList().empty())
1520 if (WS.getFragmentList().size() != 3)
1523 auto IT = WS.begin();
1541 if (WS.getSectionName().size() > PrefixLength) {
1542 if (WS.getSectionName()[PrefixLength] != '.')
1545 if (WS.getSectionName()