[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] Re: Porting QEMU to new hosts with unusual ABI (sizeof(
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] Re: Porting QEMU to new hosts with unusual ABI (sizeof(long) != sizeof(void *)) |
Date: |
Mon, 07 Feb 2011 08:23:08 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) |
Stefan Weil <address@hidden> writes:
> Am 05.02.2011 16:35, schrieb Blue Swirl:
[...]
>> The patch changes also signed longs to uintptr_t. That could introduce
>> regressions, so please use signed/unsigned as original.
>
> I changed the code manually, and there was only one location where
> signed/unsigned made a difference. That single case was an int
> parameter passed in a void pointer, and I used intptr_t there.
>
> I had the impression that in the current code (long) was
> sometimes used because it is shorter than (unsigned long) :-)
>
> As long as changes are made manually with the necessary care,
> I'd recommend using uintptr_t where possible.
I'd recommend not to mix up the intptr portability clean up with the
signedness cleanup. Much easier to review separately. Moreover,
cleaning up signedness changes generated code, while cleaning up the
types shouldn't (except on hosts where the code doesn't work).
Testable, just don't forget to strip the debug info.
[...]
Re: [Qemu-devel] Porting QEMU to new hosts with unusual ABI (sizeof(long) != sizeof(void *)), Stefan Hajnoczi, 2011/02/05
Re: [Qemu-devel] Porting QEMU to new hosts with unusual ABI (sizeof(long) != sizeof(void *)), Rob Landley, 2011/02/11
Re: [Qemu-devel] Porting QEMU to new hosts with unusual ABI (sizeof(long) != sizeof(void *)), Anthony Liguori, 2011/02/11