[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 64bit GNUstep Was: Problem with Cenon
From: |
Luboš Doležel |
Subject: |
Re: 64bit GNUstep Was: Problem with Cenon |
Date: |
Sat, 26 Jan 2013 14:38:21 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 |
On 01/26/2013 02:10 PM, Fred Kiefer wrote:
I am not sure I understand this mail correctly. Are you revering to
places in GNUstep gui where we aren't properly using NSInteger and
NSUInteger? In this case we should fix the code. If this once more
breaks the ABI it is a shame, but we have to do it anyway to get the
code consistent.
If you are revering to application or library code outside of core
things get more complicated. Apple allows the code to use 32bit versions
of the core bundles even on 64bit system. I don't know how they do it
exactly, most likely they have two versions of the library and link in
the correct one depending on the settings.
It's not that different from a Linux multilib system. The difference is
only in Fat Mach-O support on OS X, i.e. they don't have the
/usr/lib{64,32} split commonly seen in Linux and BSDs.
For the headers they use a
define, I think it is LP64 to decide how NSInteger gets defined. GNUstep
base does so unconditionally, depending on some compiler settings (or
rather depending on the installed headers, that on my machine use
__x86_64__ to decide the word size and the definition of intptr_t
depends on that)
I think the current declaration of NSInteger in GNUstep is correct. The
problem is that NSInteger is not used where it should be.
Given the System V AMD64 ABI, the only breakage I see are negative
numbers. A negative int argument in methods with >4 arguments is stored
on stack in 8 bytes, but is not sign extended to 8 bytes.
movl $0xfffffff7,0x10(%rsp) <-- this won't work when loaded into int64_t
movl $0xfffffff8,0x8(%rsp) <--- ditto
movl $0x7,(%rsp) <--- this will keep working
--
Luboš Doležel
- Problem with Cenon, A. Arias, 2013/01/24
- Re: Problem with Cenon, Fred Kiefer, 2013/01/24
- Re: Problem with Cenon, A. Arias, 2013/01/24
- Re: Problem with Cenon, Georg Fleischmann, 2013/01/25
- Re: Problem with Cenon, David Chisnall, 2013/01/26
- 64bit GNUstep Was: Problem with Cenon, Fred Kiefer, 2013/01/26
- Re: 64bit GNUstep Was: Problem with Cenon,
Luboš Doležel <=
- Re: 64bit GNUstep Was: Problem with Cenon, David Chisnall, 2013/01/26
- Re: 64bit GNUstep Was: Problem with Cenon, Fred Kiefer, 2013/01/26
- Re: 64bit GNUstep Was: Problem with Cenon, David Chisnall, 2013/01/26
- Re: 64bit GNUstep Was: Problem with Cenon, Fred Kiefer, 2013/01/26
- Re: 64bit GNUstep Was: Problem with Cenon, Ivan Vučica, 2013/01/27
- Re: 64bit GNUstep Was: Problem with Cenon, Chan Maxthon, 2013/01/27
- Re: Problem with Cenon, Fred Kiefer, 2013/01/26
- Re: Problem with Cenon, Georg Fleischmann, 2013/01/29
- Re: Problem with Cenon, Fred Kiefer, 2013/01/30