[gdb/testsuite] Fix label reference in implptr-64bit.exp
authorTom de Vries <tdevries@suse.de>
Mon, 24 Jun 2019 16:26:10 +0000 (18:26 +0200)
committerTom de Vries <tdevries@suse.de>
Mon, 24 Jun 2019 16:26:10 +0000 (18:26 +0200)
When running gdb.dwarf2/implptr-64bit.exp with board cc-with-dwz-m, we run into:
...
dwz: dwz.c:2363: checksum_die: \
  Assertion `\
    ((!op_multifile && !rd_multifile && !fi_multifile) || cu != die_cu (ref)) \
    && (!op_multifile || cu->cu_chunk == die_cu (ref)->cu_chunk)' failed.
cc-with-tweaks.sh: line 218: 13030 Aborted  \
  $DWZ -m ${output_file}.dwz "$output_file" ${output_file}.alt > /dev/null
...
In other words, PR dwz/24170.

The trigger for the dwz PR is when intra-CU references are encoded using
section-relative encoding DW_FORM_ref_addr, but could have been encoded using
CU-relative encoding DW_FORM_ref4.

Fix the intra-CU '%' label reference in implptr-64bit.exp.

Tested on x86_64-linux.

gdb/testsuite/ChangeLog:

2019-06-24  Tom de Vries  <tdevries@suse.de>

* gdb.dwarf2/implptr-64bit.exp: Fix intra-CU '%' label reference.

gdb/testsuite/ChangeLog
gdb/testsuite/gdb.dwarf2/implptr-64bit.exp

index a8e47553e4586a313802940de02c19c48b9db3ec..5b702011a77fb2d1de5ec3d7c6f245189f5fa6e8 100644 (file)
@@ -1,3 +1,7 @@
+2019-06-24  Tom de Vries  <tdevries@suse.de>
+
+       * gdb.dwarf2/implptr-64bit.exp: Fix intra-CU '%' label reference.
+
 2019-06-24  Tom de Vries  <tdevries@suse.de>
 
        * gdb.trace/entry-values.exp: Use DW_FORM_udata instead of
index b023ca0f12fe8f88d8285a203e9c3671cdec0938..3e675016d05450aee2737218ae001e75f7571bb3 100644 (file)
@@ -84,7 +84,7 @@ proc test { dwarf_version offset_size addr_size ref_addr_size two_cu } {
                        { name main }
                        { low_pc main addr }
                        { high_pc "main+0x100" addr }
-                       { type %$int_label }
+                       { type :$int_label }
                        { external 1 flag }
                    } {
                        DW_TAG_variable {