mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-12-02 06:43:58 +08:00
Add a testcase for PR binutils/27202
PR binutils/27202 * testsuite/gas/elf/dwarf-5-loc0.d: New file. * testsuite/gas/elf/dwarf-5-loc0.s: Likewise. * testsuite/gas/elf/elf.exp: Run dwarf-5-loc0.
This commit is contained in:
parent
8e4e0c7a49
commit
689580daaa
16
gas/testsuite/gas/elf/dwarf-5-loc0.d
Normal file
16
gas/testsuite/gas/elf/dwarf-5-loc0.d
Normal file
@ -0,0 +1,16 @@
|
||||
#as: -gdwarf-5
|
||||
#readelf: -wL
|
||||
#name: DWARF5 .loc 0
|
||||
# The am33 cr16 crx ft32 mn10 msp430 nds32 and rl78 targets do not evaluate the subtraction of symbols at assembly time.
|
||||
# The riscv targets do not support the subtraction of symbols.
|
||||
#xfail: am3*-* cr16-* crx-* ft32*-* mn10*-* msp430-* nds32*-* riscv*-* rl78-*
|
||||
|
||||
Contents of the \.debug_line section:
|
||||
|
||||
CU: \./foo\.c:
|
||||
File name +Line number +Starting address +View +Stmt
|
||||
|
||||
\./foo.c:\[\+\+\]
|
||||
foo\.c +1 +0x8 +x
|
||||
foo\.c +2 +0x10 +x
|
||||
foo\.c +- +0x10
|
11
gas/testsuite/gas/elf/dwarf-5-loc0.s
Normal file
11
gas/testsuite/gas/elf/dwarf-5-loc0.s
Normal file
@ -0,0 +1,11 @@
|
||||
.file "foo.c"
|
||||
.text
|
||||
.balign 16
|
||||
.globl _start
|
||||
_start:
|
||||
.file 0 "foo.c"
|
||||
.quad 0
|
||||
.loc 0 1 view 0
|
||||
.balign 16
|
||||
.loc 0 2 view 0
|
||||
.size _start, .-_start
|
@ -300,6 +300,7 @@ if { [is_elf_format] } then {
|
||||
run_dump_test "dwarf-5-file0" $dump_opts
|
||||
run_dump_test "dwarf-5-file0-2" $dump_opts
|
||||
run_dump_test "dwarf-5-dir0" $dump_opts
|
||||
run_dump_test "dwarf-5-loc0" $dump_opts
|
||||
run_dump_test "dwarf-4-cu" $dump_opts
|
||||
run_dump_test "dwarf-5-cu" $dump_opts
|
||||
run_dump_test "dwarf-5-nop-for-line-table" $dump_opts
|
||||
|
Loading…
Reference in New Issue
Block a user