[Bug general/23370] run-next-cfi-self.sh doesn't handle compressed ELF sections

2018-07-10 Thread mliska at suse dot cz
https://sourceware.org/bugzilla/show_bug.cgi?id=23370

--- Comment #2 from Martin Liska  ---
(In reply to Mark Wielaard from comment #1)
> Although relocations in ET_REL files could be an issue, they aren't actually
> for this test, because the relocations that are there are against the
> addresses inside to .debug_frame section, and we don't care what they are in
> this test case.
> 
> [We do really need some easier way to apply simple relocations when dealing
> with ET_REL files (currently you need to create a Dwfl, which is a bit
> overkill in this case).]
> 
> The real issue in this case is that the toolchain that created this test
> file (size.o) used ELF debug section compression:
> 
> [35] .debug_frame PROGBITS  0057e4 c5  0 C  0  
> 0  4
>  [ELF ZLIB (1) 000154  4]
> 
> (Oddly enough it seems it only does this for ET_REL files and the linker
> again decompresses again when creating the ET_EXEC/DYN files. Which seems
> horribly inefficient.)
> 
> So the real fix is to just uncompress the section in the test:
> 

The suggested patch works for me as we in openSUSE have enabled compression of
debug info section in gas for all targets.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

[Bug general/23370] run-next-cfi-self.sh doesn't handle compressed ELF sections

2018-07-10 Thread mark at klomp dot org
https://sourceware.org/bugzilla/show_bug.cgi?id=23370

Mark Wielaard  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |FIXED

--- Comment #3 from Mark Wielaard  ---
(In reply to Martin Liska from comment #2)
> The suggested patch works for me as we in openSUSE have enabled compression
> of debug info section in gas for all targets.

Thanks for testing. Pushed to master.

commit b40001f67c0809e2fe8c7a78c2a5ac12026f23b4 (HEAD -> master)
Author: Mark Wielaard 
Date:   Thu Jul 5 16:24:57 2018 +0200

tests: Handle compressed sections in next_cfi testcase.

Some toolchains use compressed ELF sections by default.
This would make run-next-cfi-self.sh fail because it would try to
decode the compressed data. Fix by decompressing the section first.

https://sourceware.org/bugzilla/show_bug.cgi?id=23370

Signed-off-by: Mark Wielaard 

-- 
You are receiving this mail because:
You are on the CC list for the bug.