Bug 31618 - [gdb/testsuite] Require end_sequence in dwarf assembly test-cases
Summary: [gdb/testsuite] Require end_sequence in dwarf assembly test-cases
Status: RESOLVED FIXED
Alias: None
Product: gdb
Classification: Unclassified
Component: testsuite (show other bugs)
Version: HEAD
: P2 normal
Target Milestone: 15.1
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-04-08 08:27 UTC by Tom de Vries
Modified: 2024-04-17 10:56 UTC (History)
0 users

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom de Vries 2024-04-08 08:27:51 UTC
I submitted a patch series here ( https://sourceware.org/pipermail/gdb-patches/2024-April/207826.html ) to clean up dwarf assembly test-cases related to the end_sequence usage.

However, I forgot to require a terminating end_sequence, as described by the dwarf standard:
...
Every line number program sequence must end with a DW_LNE_end_sequence instruction which creates a row whose address is that of the byte
after the last target machine instruction of the sequence.
...
Comment 2 Sourceware Commits 2024-04-17 10:55:06 UTC
The master branch has been updated by Tom de Vries <vries@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=0f91492fcf3e75a014c605bc61fc7eed8ad5100e

commit 0f91492fcf3e75a014c605bc61fc7eed8ad5100e
Author: Tom de Vries <tdevries@suse.de>
Date:   Wed Apr 17 12:55:00 2024 +0200

    [gdb/testsuite] Require DW_LNE_end_sequence
    
    The dwarf standard requires that every line number program sequence ends
    with a DW_LNE_end_sequence instruction.
    
    Enforce this in the dwarf assembler for the last sequence in a line number
    program (we have no means to enforce this for earlier sequences), and fix a
    few test-case that don't have it.
    
    Tested on aarch64-linux.
    
    PR testsuite/31618
    Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=31618
Comment 3 Tom de Vries 2024-04-17 10:56:57 UTC
Fixed.