This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [commit] [testsuite patch] Fix gdb.btrace/tailcall-only.exp errors on x86_64-m32
On 07/21/2016 02:50 PM, Metzger, Markus T wrote:
> I use the triplet to select the source files for a test. Seems that wasn't such
> a good idea.
>
> Using the pointer size doesn't seem to be such a good idea, either, as x32
> uses x86_64 ISA with 32-bit pointers.
But that's exactly what you want.
>
> Is there a recommended/documented way on how this should be done?
- is_amd64_regs_target detects x86_64 ISA.
- is_lp64_target detects 64-bit/32-bit pointers.
Thus:
is_amd64_regs_target && is_lp64_target == 64-bit
is_amd64_regs_target && !is_lp64_target == x32
!is_amd64_regs_target == 32-bit
See intro comments to is_amd64_regs_target and proc is_x86_like_target.
Thanks,
Pedro Alves