llvm-6502/test/MC/ELF
Ulrich Weigand 4df4bccc71 [MC/DWARF] Generate multiple .debug_line entries for adjacent .loc directives
The compiler occasionally generates multiple .loc directives in a row
(at the same instruction address).  These need to be transformed into
multple actual .debug_line table entries, since they are used to signal
certain information to the debugger (e.g. if the opening brace of a
function body is on the same line as the declaration).

The MCAsmStreamer version of EmitDwarfLocDirective handles this
correctly by emitting a .loc directive every time it is called.
However, the MCObjectStream version simply defaults to recording
the information and emitting only a single table entry later,
e.g. when EmitInstruction is called.

This patch introduces a MCAsmStreamer::EmitDwarfLocDirective
version that emits a line table entry for a .loc directive
that may already be pending before recording the new directive.
(This is similar to how this is handled in GNU as.)

With this patch (and the code alignment factor patch) applied,
I'm now getting identical DWARF .debug sections for all test-suite
object files on PowerPC for the internal and the external assembler.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184357 91177308-0d34-0410-b5e6-96231b3b80d8
2013-06-19 21:27:27 +00:00
..
abs.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
alias-reloc.s Don't hide the first ELF symbol. 2013-06-05 20:33:54 +00:00
alias.s Don't hide the first ELF symbol. 2013-06-05 20:33:54 +00:00
align-bss.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
align-nops.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
align-size.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
align-text.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
align.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
bad-section.s Jörg Sonnenberger noticed that we were missing this test. 2011-01-24 19:40:38 +00:00
basic-elf-32.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
basic-elf-64.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
bracket-exprs.s split this test into arch specific pieces, so the ARM 2011-02-25 19:06:35 +00:00
bracket.s Restore r125595 (reverted in r126336) with modifications: 2011-02-24 21:59:22 +00:00
bss.ll
call-abs.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
cfi-adjust-cfa-offset.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-advance-loc2.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-def-cfa-offset.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-def-cfa-register.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-def-cfa.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-escape.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-offset.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-reg.s PR13754: llvm-mc/x86 crashes on .cfi directives without the % prefix for registers. 2012-09-07 14:51:35 +00:00
cfi-register.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-rel-offset2.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-rel-offset.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-remember.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-restore.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-same-value.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-sections.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
cfi-signal-frame.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
cfi-undefined.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi-zero-addr-delta.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
cfi.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
comdat.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
common2.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
common.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
comp-dir.s Now that llvm-dwarfdump supports flags to specify which DWARF section to dump, 2013-01-25 21:44:53 +00:00
debug-line2.s [MC/DWARF] Generate multiple .debug_line entries for adjacent .loc directives 2013-06-19 21:27:27 +00:00
debug-line.s Add support for DWARF line number table entries for values in the instruction 2013-05-25 21:56:53 +00:00
debug-loc.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
diff2.s
diff.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
elf_directive_previous.s
elf_directive_section.s
empty-dwarf-lines.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
empty.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
entsize.ll Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
entsize.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
fde.s Give this test an explicit triple. 2012-08-12 08:21:27 +00:00
file.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
gen-dwarf.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
global-offset.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
got.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
ident.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
invalid-symver.s Produce an error for an invalid use of .symver. 2010-10-27 17:56:18 +00:00
lcomm.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
leb128.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
lit.local.cfg Continue cleanup of LIT, getting rid of the remaining artifacts from dejagnu 2012-03-25 09:02:19 +00:00
local-reloc.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
many-section.s In the ObjectFile interface, replace isInternal(), isAbsolute(), isGlobal(), and isWeak(), with a bitset of flags. 2012-02-28 23:47:53 +00:00
many-sections-2.s Implements low-level object file format specific output for COFF and 2013-04-03 18:31:38 +00:00
merge.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
n_bytes.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
no-fixup.s Rewrite a test to check actual output rather than intermediate implementation 2013-03-01 20:54:00 +00:00
noexec.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
norelocation.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
org.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
pic-diff.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
plt.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
pr9292.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
relax-all-flag.s Add a test for explicitly exercising the mc-relax-all flag. 2012-12-10 20:36:01 +00:00
relax-arith.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
relax-crash.s Relax dwarf line fragments. This fixes a crash in the included testcase. 2010-11-07 02:07:12 +00:00
relax.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
relocation-386.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
relocation-pc.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
relocation.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
rename.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
section-quoting.s Be nice to Xcore and the XMOS assembler and avoid quoting section names 2011-03-04 20:03:14 +00:00
section.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
set.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
sleb.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
subsection.s Add support for subsections to the ELF assembler. Fixes PR8717. 2013-04-17 21:18:16 +00:00
symref.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
tls-i386.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
tls.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
type.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
uleb.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
undef2.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
undef.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
version.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
weak-relocation.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
weak.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
weakref-plt.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
weakref-reloc.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00
weakref.s Don't hide the first ELF symbol. 2013-06-05 20:33:54 +00:00
x86_64-reloc-sizetest.s Change how we iterate over relocations on ELF. 2013-05-30 03:05:14 +00:00
zero.s Replace coff-/elf-dump with llvm-readobj 2013-04-12 04:06:46 +00:00