Community
Participate
Working Groups
Hi, I encountered ELF files which show a loadable segment file_size equal to zero but an higher mem_size. Anyway the function is_p_header_region in tcf_elf.c doesn't recognize these segments and consequently our TCF based debugger can't find the debug info (for resolving addresses to lines for instance.) I don't think the ELF spec is very specific about that as it says file_size can be zero but not if it is only when the segment is empty.
Could you send such ELF file that can be used to reproduce the issue?
Created attachment 244358 [details] Correct file Attached correct version of file that works fine.
Created attachment 244359 [details] File showing issue Attached version of file that shows the issue: LOAD 0x0000000000000000 0x0000000000400000 0x0000000000400000 0x0000000000000000 0x0000000000000764 R E 200000 instead of LOAD 0x0000000000000000 0x0000000000400000 0x0000000000400000 0x0000000000000764 0x0000000000000764 R E 200000 I manually edited a correct file but it looks like it correctly "simulates" the problem seen with our binary.