From patchwork Fri Dec 6 23:46:40 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Burgess X-Patchwork-Id: 36580 Received: (qmail 108595 invoked by alias); 6 Dec 2019 23:46:50 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Delivered-To: mailing list gdb-patches@sourceware.org Received: (qmail 108514 invoked by uid 89); 6 Dec 2019 23:46:49 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-21.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_PASS autolearn=ham version=3.3.1 spammy= X-HELO: mail-wm1-f66.google.com Received: from mail-wm1-f66.google.com (HELO mail-wm1-f66.google.com) (209.85.128.66) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 06 Dec 2019 23:46:48 +0000 Received: by mail-wm1-f66.google.com with SMTP id g206so9526576wme.1 for ; Fri, 06 Dec 2019 15:46:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=embecosm.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=3EIFxoVQhaMiFZy8AcI2wL4efXdemFJOwzQJvI9VOBg=; b=A5gwOZKoQpcW6tk9cIN4W00cHh6RLB0pUM8Yn+sYdkLUul8Om91sV992CJduHFlytG +r8iYMZ9fLgixd3vqQLpbmct18ueQfiBLZWtA3UuZDfTc/+AnEfiwwH5HzDHy2PsHgu1 m5VuhfSnb6DNQS7sqSVGOXYQgUT1LtqysF7poTTAJGRuM9bZ6yLrAbGTEd7feIaHxoJD MJV9en5w/36dlvstlmnDwnLTr46D7sgLq8lqe6/iSfAn6Ns7jEjqQ87luYU/9fa8ENGD 0q0H5jlBA6UHQ8ww2QX3Oh+MFgzuW0KGsOQV/NMUarBwGE/TeTP2e4tZbWlcpnS7rsgB jwNQ== Return-Path: Received: from localhost (host86-186-80-236.range86-186.btcentralplus.com. [86.186.80.236]) by smtp.gmail.com with ESMTPSA id f16sm4654412wrm.65.2019.12.06.15.46.45 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 06 Dec 2019 15:46:46 -0800 (PST) From: Andrew Burgess To: gdb-patches@sourceware.org Cc: Andrew Burgess Subject: [PATCH 1/2] gdb/testsuite: Allow DWARF assembler to create multiple line tables Date: Fri, 6 Dec 2019 23:46:40 +0000 Message-Id: In-Reply-To: References: In-Reply-To: References: X-IsSubscribed: yes Fixes a bug in the DWARF assembler that prevents multiple line tables from being created in a test. We currently don't initialise a couple of flags, as a result we will only ever generate one end of file list, and one end of header, in the first line table. Any additional line tables will be missing these parts, and will therefore be corrupt. This fix will be required for a later commit. There should be no change in the testsuite after this commit. gdb/testsuite/ChangeLog: * lib/dwarf.exp (Dwarf::lines): Reset _line_saw_program and _line_saw_file. Change-Id: Id7123f217a036f26ee32d608db3064dd43164596 --- gdb/testsuite/ChangeLog | 5 +++++ gdb/testsuite/lib/dwarf.exp | 2 ++ 2 files changed, 7 insertions(+) diff --git a/gdb/testsuite/lib/dwarf.exp b/gdb/testsuite/lib/dwarf.exp index 75d19abf802..c7f7cee722d 100644 --- a/gdb/testsuite/lib/dwarf.exp +++ b/gdb/testsuite/lib/dwarf.exp @@ -1309,6 +1309,8 @@ namespace eval Dwarf { set is_64 0 set _unit_version 4 set _unit_addr_size default + set _line_saw_program 0 + set _line_saw_file 0 foreach { name value } $options { switch -exact -- $name {