[RFA/ppc-aix] fix thread support breakage (was: "Re: [PATCH 4/5] powerpc64-aix ptrace64 when defined.")
Joel Brobecker
brobecker@adacore.com
Fri Aug 23 00:48:00 GMT 2013
Hello again,
> Actually, I just found that it breaks thread support on 32bit AIX,
> at least. A simpler way to show the problem is:
>
> (gdb) x /x &__n_pthreads
> 0xf06a8258 <__n_pthreads>: Cannot access memory at address 0xf06a8258
>
> Prior to the patch, we have:
>
> (gdb) x /x &__n_pthreads
> 0xf06a8258 <__n_pthreads>: 0x00000003
Attached is the patch I checked in locally at AdaCore:
gdb/ChangeLog:
* rs6000-nat.c (rs6000_ptrace32): Cast "addr" to "uintptr_t"
instead of "long long" in call to ptrace64.
Tested on ppc-aix in full 32bit mode (both GDB and inferior are
32bit). I think the other scenario would be 64bit GDB debugging
a 32bit inferior, but I don't have a 64bit compiler to try it.
I'd like to commit this patch, unless there are comments/suggestions.
Thank you,
--
Joel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-thread-support-broken-on-ppc-aix.patch
Type: text/x-diff
Size: 2061 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/gdb-patches/attachments/20130823/e1691baa/attachment.bin>
More information about the Gdb-patches
mailing list