From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25136 invoked by alias); 24 Jun 2019 11:49:57 -0000 Mailing-List: contact gdb-testers-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-testers-owner@sourceware.org Received: (qmail 25126 invoked by uid 89); 24 Jun 2019 11:49:57 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-15.9 required=5.0 tests=AWL,BAYES_00,GIT_PATCH_0,GIT_PATCH_1,GIT_PATCH_2,GIT_PATCH_3,SPF_PASS autolearn=ham version=3.3.1 spammy= X-HELO: kwanyin.sergiodj.net Received: from kwanyin.sergiodj.net (HELO kwanyin.sergiodj.net) (158.69.185.54) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 24 Jun 2019 11:49:54 +0000 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [binutils-gdb] [gdb/testsuite] Fix DW_AT_decl_file in gdb.trace tests From: gdb-buildbot@sergiodj.net To: gdb-testers@sourceware.org Message-Id: <824eacee59ea8c5625b9fad5b6eb0861b4d0f691@gdb-build> Date: Mon, 24 Jun 2019 18:57:00 -0000 X-SW-Source: 2019-q2/txt/msg06588.txt.bz2 *** TEST RESULTS FOR COMMIT 824eacee59ea8c5625b9fad5b6eb0861b4d0f691 *** commit 824eacee59ea8c5625b9fad5b6eb0861b4d0f691 Author: Tom de Vries AuthorDate: Mon Jun 24 13:29:23 2019 +0200 Commit: Tom de Vries CommitDate: Mon Jun 24 13:29:23 2019 +0200 [gdb/testsuite] Fix DW_AT_decl_file in gdb.trace tests When running gdb.trace/{entry-values.exp,unavailable-dwarf-piece.exp} with board cc-with-dwz, we run into two failures related to the DW_AT_decl_file attribute: - The encoding DW_FOR_sdata is used for DW_AT_decl_file, while the attribute is required to have a an "unsigned integer constant" value. - The DW_AT_decl_file attributes refer to a file with index one, while there's no such file. Fix this by using DW_FOR_udata and the value 0, meaning "no file specified". Tested on x86_64-linux with board native-gdbserver. gdb/testsuite/ChangeLog: 2019-06-24 Tom de Vries * gdb.trace/entry-values.exp: Use DW_FORM_udata instead of DW_FOR_sdata for DW_AT_decl_file. Use 0 for DW_AT_decl_file. * gdb.trace/unavailable-dwarf-piece.exp: Same. diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 4d48d2f63a..a8e47553e4 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,5 +1,11 @@ 2019-06-24 Tom de Vries + * gdb.trace/entry-values.exp: Use DW_FORM_udata instead of + DW_FOR_sdata for DW_AT_decl_file. Use 0 for DW_AT_decl_file. + * gdb.trace/unavailable-dwarf-piece.exp: Same. + +2019-06-24 Tom de Vries + * gdb.dwarf2/inlined_subroutine-inheritance.exp: 2019-06-21 Tom de Vries diff --git a/gdb/testsuite/gdb.trace/entry-values.exp b/gdb/testsuite/gdb.trace/entry-values.exp index 13619bad9a..6637e5ecff 100644 --- a/gdb/testsuite/gdb.trace/entry-values.exp +++ b/gdb/testsuite/gdb.trace/entry-values.exp @@ -109,7 +109,7 @@ Dwarf::assemble $asm_file { } foo_label: subprogram { - {decl_file 1 sdata} + {decl_file 0 udata} {MACRO_AT_func { foo ${srcdir}/${subdir}/${srcfile} }} } { formal_parameter { @@ -126,7 +126,7 @@ Dwarf::assemble $asm_file { subprogram { {name bar} - {decl_file 1 sdata} + {decl_file 0 udata} {low_pc $bar_start addr} {high_pc "$bar_start + $bar_length" addr} {GNU_all_call_sites 1 sdata} diff --git a/gdb/testsuite/gdb.trace/unavailable-dwarf-piece.exp b/gdb/testsuite/gdb.trace/unavailable-dwarf-piece.exp index c62e344ee0..87177857e3 100644 --- a/gdb/testsuite/gdb.trace/unavailable-dwarf-piece.exp +++ b/gdb/testsuite/gdb.trace/unavailable-dwarf-piece.exp @@ -44,7 +44,7 @@ Dwarf::assemble $asm_file { struct_s_label: DW_TAG_structure_type { {name s} {byte_size 3 DW_FORM_sdata} - {decl_file 1 DW_FORM_sdata} + {decl_file 0 DW_FORM_udata} {decl_line 1 DW_FORM_sdata} } { DW_TAG_member { @@ -73,7 +73,7 @@ Dwarf::assemble $asm_file { struct_t_label: DW_TAG_structure_type { {name t} {byte_size 3 DW_FORM_sdata} - {decl_file 1 DW_FORM_sdata} + {decl_file 0 DW_FORM_udata} {decl_line 1 DW_FORM_sdata} } { DW_TAG_member { @@ -174,7 +174,7 @@ Dwarf::assemble $asm_file { DW_TAG_subprogram { {name foo} - {decl_file 1 sdata} + {decl_file 0 udata} {low_pc foo_start_lbl addr} {high_pc foo_end_lbl addr} } { @@ -219,7 +219,7 @@ Dwarf::assemble $asm_file { DW_TAG_subprogram { {name bar} - {decl_file 1 sdata} + {decl_file 0 udata} {low_pc bar_start_lbl addr} {high_pc bar_end_lbl addr} } {