1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
llvm-mirror/include/llvm/MC
Ali Tamur c283818217 [llvm] Prevent duplicate files in debug line header in dwarf 5: another attempt
Another attempt to land the changes in debug line header to prevent duplicate
files in Dwarf 5. I rolled back my previous commit because of a mistake in
generating the object file in a test. Meanwhile, I addressed some offline
comments and changed the implementation; the largest difference is that
MCDwarfLineTableHeader does not keep DwarfVersion but gets it as a parameter. I
also merged the patch to fix two lld tests that will strt to fail into this
patch.

Original Commit:

https://reviews.llvm.org/D59515

Original Message:
Motivation: In previous dwarf versions, file name indexes started from 1, and
the primary source file was not explicit. Dwarf 5 standard (6.2.4) prescribes
the primary source file to be explicitly given an entry with an index number 0.

The current implementation honors the specification by just duplicating the
main source file, once with index number 0, and later maybe with another
index number. While this is compliant with the letter of the standard, the
duplication causes problems for consumers of this information such as lldb.
(Some files are duplicated, where only some of them have a line table although
all refer to the same file)

With this change, dwarf 5 debug line section files always start from 0, and
the zeroth entry is not duplicated whenever possible. This requires different
handling of dwarf 4 and dwarf 5 during generation (e.g. when a function returns
an index zero for a file name, it signals an error in dwarf 4, but not in dwarf
5) However, I think the minor complication is worth it, because it enables all
consumers (lldb, gdb, dwarfdump, objdump, and so on) to treat all files in the
file name list homogenously.

llvm-svn: 358732
2019-04-19 02:26:56 +00:00
..
MCDisassembler Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCParser Remove ASan asm instrumentation. 2019-03-11 21:50:10 +00:00
ConstantPools.h Fix misspelled filenames in file headers of llvm/{MC,Object,CodeGen}/*.h 2019-02-06 08:02:46 +00:00
LaneBitmask.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MachineLocation.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmBackend.h [RISCV] Insert R_RISCV_ALIGN relocation type and Nops for code alignment when linker relaxation enabled 2019-01-30 11:16:59 +00:00
MCAsmInfo.h Move addInitialFrameState out of line and remove the MCDwarf.h include. 2019-04-12 06:57:45 +00:00
MCAsmInfoCOFF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmInfoDarwin.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmInfoELF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmInfoWasm.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmLayout.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAsmMacro.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCAssembler.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCCodeEmitter.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCCodePadder.h Fix misspelled filenames in file headers of llvm/{MC,Object,CodeGen}/*.h 2019-02-06 08:02:46 +00:00
MCCodeView.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCContext.h NFC: Move API uses of MD5::MD5Result to Optional rather than a pointer. 2019-04-04 23:34:38 +00:00
MCDirectives.h [MC] Teach the MachO object writer about N_FUNC_COLD 2019-01-25 18:30:22 +00:00
MCDwarf.h [llvm] Prevent duplicate files in debug line header in dwarf 5: another attempt 2019-04-19 02:26:56 +00:00
MCELFObjectWriter.h MC/ELF: Allow targets to set ABI version 2019-02-14 22:42:09 +00:00
MCELFStreamer.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCExpr.h [WebAssembly] Add new explicit relocation types for PIC relocations 2019-04-04 17:43:50 +00:00
MCFixedLenDisassembler.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCFixup.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCFixupKindInfo.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCFragment.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCInst.h Replace llvm::isPodLike<...> by llvm::is_trivially_copyable<...> 2019-01-20 21:19:56 +00:00
MCInstBuilder.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCInstPrinter.h [llvm-objdump] Implement -Mreg-names-raw/-std options. 2019-02-26 12:15:14 +00:00
MCInstrAnalysis.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCInstrDesc.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCInstrInfo.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCInstrItineraries.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCLabel.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCLinkerOptimizationHint.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCMachObjectWriter.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCObjectFileInfo.h [Remarks] Emit a section containing remark diagnostics metadata 2019-03-27 01:13:59 +00:00
MCObjectStreamer.h [AsmPrinter] Remove hidden flag -print-schedule. 2019-02-04 12:51:26 +00:00
MCObjectWriter.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCRegisterInfo.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSchedule.h [MC][X86] Correctly model additional operand latency caused by transfer delays from the integer to the floating point unit. 2019-01-23 16:35:07 +00:00
MCSection.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSectionCOFF.h [MC] Clean up unused inline function and non-anchor defaulted destructors; NFCI 2019-02-09 02:11:51 +00:00
MCSectionELF.h [MC] Clean up unused inline function and non-anchor defaulted destructors; NFCI 2019-02-09 02:11:51 +00:00
MCSectionMachO.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSectionWasm.h [WebAssembly] Update MC for bulk memory 2019-02-19 22:56:19 +00:00
MCStreamer.h Move getNumFrameInfos and getDwarfFrameInfos out of line and remove 2019-04-12 07:42:35 +00:00
MCSubtargetInfo.h [Subtarget] Merge ProcSched and ProcDesc arrays in MCSubtargetInfo into a single array. 2019-03-05 18:54:38 +00:00
MCSymbol.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSymbolCOFF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSymbolELF.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCSymbolMachO.h [MC] Teach the MachO object writer about N_FUNC_COLD 2019-01-25 18:30:22 +00:00
MCSymbolWasm.h [WebAssembly] Initial implementation of PIC code generation 2019-03-26 19:46:15 +00:00
MCTargetOptions.h Fix some MCTargetOptions Doxygen comments (NFC) 2019-04-04 20:35:57 +00:00
MCTargetOptionsCommandFlags.inc Remove ASan asm instrumentation. 2019-03-11 21:50:10 +00:00
MCValue.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWasmObjectWriter.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWasmStreamer.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWin64EH.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWinCOFFObjectWriter.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWinCOFFStreamer.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
MCWinEH.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SectionKind.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
StringTableBuilder.h Update the file headers across all of the LLVM projects in the monorepo 2019-01-19 08:50:56 +00:00
SubtargetFeature.h Use bitset for assembler predicates 2019-03-11 17:04:35 +00:00