[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Libunwind-devel] Fix word size for MIPS architecture
From: |
Vicente Olivert Riera |
Subject: |
Re: [Libunwind-devel] Fix word size for MIPS architecture |
Date: |
Tue, 2 Dec 2014 10:26:56 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.8.0 |
On 12/02/2014 02:35 AM, Arun Sharma wrote:
> On Mon, Dec 1, 2014 at 6:07 PM, Vicente Olivert Riera
> <address@hidden> wrote:
>
>> Both n32 and n64 are MIPS64 ABIs. The only difference is that n32 has
>> 32bit pointers and integers, and n64 has 64bit pointers and integers.
>> But both are a MIPS64 architecture.
>>
>
> This sounds more like:
> http://en.wikipedia.org/wiki/X32_ABI
>
> We don't have a precedent for this in the code base as far as I know.
> I still think it should be exposed as a new ABI for everything to work
> right (eg: n64 unwinder unwinding a n32 target and vice versa).
>
> For the specific patch you attached to the bug report, assuming n32
> has 64 bit registers: Changing unw_word_t to 32 bit will break
> interfaces like:
>
> unw_get_reg (unw_cursor_t *cursor, int regnum, unw_word_t *valp)
Uhm..., I don't think so. Take a look to this:
http://www.imgtec.com/mips/architectures/mips64.asp
The last part:
"[...] the architecture features a 32-bit compatibility mode, in which
all registers and addresses are 32-bit wide [...]"
> Could you solve the X problem by using a different type that
> represents the size of a pointer (Eg: ptrdiff_t or size_t?)
>
> -Arun
>
--
Vicente Olivert Riera
Graduate Software Engineer, MIPS Platforms
Imagination Technologies Limited
t: +44 (0)113 2429814
www.imgtec.com