1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00
llvm-mirror/lib/MC
Wouter van Oortmerssen c0b486e8f3 [WebAssembly] Fix assert in lookup of section symbols
Fixes assert in: https://bugs.llvm.org/show_bug.cgi?id=49036

getWasmSection creates sections if they don't exist, but doesn't add them to the Symbols table. This may cause problems in subsequent calls to getOrCreateSymbol which checks this table, the calls createSymbol assuming it doesn't exist, which then checks UsedNames and finds out it does exist, causing an assert on trying to rename a non-temp symbol.

I tried also fixing the somewhat unintuitive forced suffixing (adding `0`), but it turns out that WasmObjectWriter currently assumes these section symbols are unique, so that may have to be a separate fix: https://bugs.llvm.org/show_bug.cgi?id=49252

Also worth noting is that getWasmSection calling createSymbol may not be correct to start with, given that createSymbol seems to assume it is creating non-section symbols. But again, for a future fix.

Related: where some of this was introduced: 8d396acac3

Differential Revision: https://reviews.llvm.org/D96473
2021-02-18 11:50:14 -08:00
..
MCDisassembler llvmbuildectomy - replace llvm-build by plain cmake 2020-11-13 10:35:24 +01:00
MCParser [MC][ELF] Support for zero flag section groups 2021-02-16 14:23:40 -08:00
CMakeLists.txt [CSSPGO] Pseudo probe encoding and emission. 2020-12-10 17:29:28 -08:00
ConstantPools.cpp
ELFObjectWriter.cpp [MC][ELF] Fix gcc "enumeral and non-enumeral type in conditional expression" warning (NFC) 2021-02-18 14:58:59 +08:00
MachObjectWriter.cpp
MCAsmBackend.cpp
MCAsmInfo.cpp [llvm] Use isAlpha/isAlnum (NFC) 2021-01-22 23:25:03 -08:00
MCAsmInfoCOFF.cpp
MCAsmInfoDarwin.cpp
MCAsmInfoELF.cpp
MCAsmInfoWasm.cpp
MCAsmInfoXCOFF.cpp [XCOFF][AIX] Alternative path in EHStreamer for platforms do not have uleb128 support 2020-12-02 20:03:15 +00:00
MCAsmMacro.cpp [ms] [llvm-ml] Enable support for MASM-style macro procedures 2020-11-04 10:29:57 -05:00
MCAsmStreamer.cpp [CSSPGO] Pseudo probe encoding and emission. 2020-12-10 17:29:28 -08:00
MCAssembler.cpp MCDwarf: Delete uneeded parameter 2021-01-21 00:55:07 -08:00
MCCodeEmitter.cpp
MCCodeView.cpp [CodeView] Fix inline sites that are missing code offsets. 2020-12-07 13:01:53 -08:00
MCContext.cpp [WebAssembly] Fix assert in lookup of section symbols 2021-02-18 11:50:14 -08:00
MCDwarf.cpp [MC] Use std::make_tuple to make some toolchains happy again 2021-01-21 14:05:14 +01:00
MCELFObjectTargetWriter.cpp
MCELFStreamer.cpp [MC][ELF] Support for zero flag section groups 2021-02-16 14:23:40 -08:00
MCExpr.cpp [AVR] Fix global references to function symbols 2021-02-10 00:40:49 +13:00
MCFragment.cpp [CSSPGO] Pseudo probe encoding and emission. 2020-12-10 17:29:28 -08:00
MCInst.cpp [WebAssembly] Support single-floating-point immediate value 2021-02-04 18:05:06 -08:00
MCInstPrinter.cpp
MCInstrAnalysis.cpp
MCInstrDesc.cpp
MCInstrInfo.cpp
MCLabel.cpp
MCLinkerOptimizationHint.cpp
MCMachObjectTargetWriter.cpp
MCMachOStreamer.cpp [MC] Make MCStreamer aware of AsmParser's StartTokLoc 2020-11-02 12:32:07 -08:00
MCNullStreamer.cpp [MC] Make MCStreamer aware of AsmParser's StartTokLoc 2020-11-02 12:32:07 -08:00
MCObjectFileInfo.cpp [XCOFF][NFC] make csect properties optional for getXCOFFSection 2021-02-17 20:51:42 -05:00
MCObjectStreamer.cpp [MC] Split MCContext::createTempSymbol, default AlwaysAddSuffix to true, and add comments 2020-12-21 14:04:13 -08:00
MCObjectWriter.cpp
MCPseudoProbe.cpp [CSSPGO] Pseudo probe encoding and emission. 2020-12-10 17:29:28 -08:00
MCRegisterInfo.cpp
MCSchedule.cpp [ARM][SchedModels] Convert IsPredicatedPred to MCSchedPredicate 2020-10-19 11:37:54 +03:00
MCSection.cpp [llvm] Use llvm::lower_bound and llvm::upper_bound (NFC) 2021-01-29 23:23:36 -08:00
MCSectionCOFF.cpp
MCSectionELF.cpp [MC][ELF] Support for zero flag section groups 2021-02-16 14:23:40 -08:00
MCSectionMachO.cpp [llvm] Use llvm::find_if (NFC) 2021-01-11 18:48:06 -08:00
MCSectionWasm.cpp [WebAssembly] Support COMDAT sections in assembly syntax 2020-12-10 16:43:59 -08:00
MCSectionXCOFF.cpp [XCOFF][NFC] make StorageMappingClass/SymbolType member optional 2021-02-18 04:46:05 -05:00
MCStreamer.cpp [MC] Split MCContext::createTempSymbol, default AlwaysAddSuffix to true, and add comments 2020-12-21 14:04:13 -08:00
MCSubtargetInfo.cpp
MCSymbol.cpp
MCSymbolELF.cpp
MCSymbolXCOFF.cpp
MCTargetOptions.cpp
MCTargetOptionsCommandFlags.cpp
MCValue.cpp
MCWasmObjectTargetWriter.cpp
MCWasmStreamer.cpp [WebAssembly][MC] Remove useless overrides in MCWasmStreamer 2020-11-17 07:09:49 -08:00
MCWin64EH.cpp Reapply "[CodeGen] [WinException] Only produce handler data at the end of the function if needed" 2020-11-23 23:17:03 +02:00
MCWinCOFFStreamer.cpp [MC] Make MCStreamer aware of AsmParser's StartTokLoc 2020-11-02 12:32:07 -08:00
MCWinEH.cpp
MCXCOFFObjectTargetWriter.cpp
MCXCOFFStreamer.cpp [MC] Make MCStreamer aware of AsmParser's StartTokLoc 2020-11-02 12:32:07 -08:00
StringTableBuilder.cpp [MC] Adjust StringTableBuilder for linked Mach-O binaries 2020-10-22 19:19:41 -07:00
SubtargetFeature.cpp
WasmObjectWriter.cpp [MC][WebAssembly] Fix provisional values for data alias relocations 2021-02-08 16:56:57 -08:00
WinCOFFObjectWriter.cpp ELFObjectWriter: Make STT_FILE precede associated local symbols 2021-02-07 17:51:40 -08:00
XCOFFObjectWriter.cpp [NFC][AIX][XCOFF] Fix compile warning on strncpy 2021-01-19 14:07:11 +08:00