Created attachment 71155 [details] ignore PF_X when choosing writable ELF sections Valgrind fails to resolve symbols on a PPC32 platform with old ABI, because: * read_elf_debug_info() do not assume an ELF section which has 'X' flag as a valid section for GOT. * legacy PowerPC ABI had required GOT to be both writable and executable. #(http://sources.redhat.com/ml/binutils/2005-05/msg00391.html) With attached patch, symbols seems to be successfully loaded on such environment (which uses 'bss-plt' layout instead of 'secure-plt').
296318 introduced changes in r12735 which, among other things, relax this requirement for strict R-X or RW- match exactly as the patch proposes, so it is no longer relevant. if ( map->rw && (phdr->p_flags & (PF_R | PF_W)) == (PF_R | PF_W)) { ... TRACE_SYMTAB("PT_LOAD[%ld]: acquired as rw\n", i); } if ( map->rx && (phdr->p_flags & (PF_R | PF_X)) == (PF_R | PF_X)) { ... TRACE_SYMTAB("PT_LOAD[%ld]: acquired as rx\n", i); }
Closing this a duplicate of 296318. If you still have the problem in current svn trunk >= r12375, please re-open. *** This bug has been marked as a duplicate of bug 296318 ***