FW: [PATCH] readelf: attach location views to DW_LLE_startx_endx/startx_length loclists

"Kamil Bucki \(Nokia\) via Binutils" <[email protected]>
Newsgroups gmane.comp.gnu.binutils
Message-ID <AM8PR07MB8310A1AD8CF6A572F05DBE49EDFE2@AM8PR07MB8310.eurprd07.prod.outlook.com>
display_loclists_list only read the GNU location-view pair
(DW_AT_GNU_locviews) for DW_LLE_offset_pair, DW_LLE_start_end and
DW_LLE_start_length entries.  For the indexed bounded forms
DW_LLE_startx_endx and DW_LLE_startx_length the range was decoded but
the matching view pair was left unread, so vstart lagged behind next and
the adjacency heuristic emitted a spurious

  Warning: Hole and overlap detection requires adjacent view lists and loclists.

Add the two indexed bounded forms to the guard so their view pair is
consumed and printed like the other bounded entries.  This is not target
specific; it reproduces on any DWARF 5 object whose producer emits
startx_* loclist entries together with location views.

	PR binutils/34366
	* dwarf.c (display_loclists_list): Also read and print the
	location view pair for DW_LLE_startx_endx and
	DW_LLE_startx_length entries.

Signed-off-by: Kamil Bucki <[email protected]>
---
 binutils/dwarf.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/binutils/dwarf.c b/binutils/dwarf.c
index 829bcb761f7..d3e101704ca 100644
--- a/binutils/dwarf.c
+++ b/binutils/dwarf.c
@@ -8177,7 +8177,9 @@ display_loclists_list (struct dwarf_section *  section,
 
       if (vstart && (llet == DW_LLE_offset_pair
 		     || llet == DW_LLE_start_end
-		     || llet == DW_LLE_start_length))
+		     || llet == DW_LLE_start_length
+		     || llet == DW_LLE_startx_endx
+		     || llet == DW_LLE_startx_length))
 	{
 	  off = offset + (vstart - *start_ptr);
 
-- 
2.51.0
0001-readelf-attach-location-views-to-DW_LLE_startx_endx (application/octet-stream, 1.7 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.