Re: [PATCH] Fix possible alignment issue with dw2-dir-file-name test case

Pedro Alves
2014-01-22T13:15:22Z

On 01/20/2014 07:47 PM, Andreas Arnez wrote:

> * On s390x, the test case fails like this:
>
> Breakpoint 1, 0x00000000800005d2 in func (param=<error reading
> variable: Cannot access memory at address 0x0>)
> (gdb) p/x param
> Cannot access memory at address 0x0
>
> Note that the debug info looks correct, and all addresses fit into
> four bytes. Still, the failure disappears when changing the DWARF
> pointer size to 8. Thus it seems that the address size mismatch
> causes confusion somewhere in GDB on big-endian systems.

Hmm, yeah. A little odd that dw2-dir-file-name also uses .byte 4
and doesn't have this issue.

> * On PPC64, 'func' and 'main' are function descriptors and don't point
> to the actual code. Thus the usage of these symbols in
> dw2-ifort-parameter-debug.S is broken (similar to what has been
> discussed in the thread, I think).

Thanks. I believe this alone would fix Thumb. I think this bit should
go in as is (maybe with a comment), and independently of whatever
is the fix for the 64-bit issue.

--
Pedro Alves