FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor


 
 
LinkBack Thread Tools
 
Old 07-30-2012, 04:40 PM
Alecks Gates
 
Default x32 ABI

After a recent update to binutils 2.22 I started to look into the x32
ABI support. It looks very interesting and I am thinking about
installing it via the experimental stage3[1], but I have some
questions to ask first.

What are the benefits and drawbacks of using the x32 ABI, other than
the obvious "experimental" cautions? I currently do not have a
computer with more than 4GB of ram, and one only has 2GB (used as a
media center).

How do I go about installing an x32 ABI system? Is it as simple as
using the x32 stage3 and enabling CONFIG_X86_X32 in the kernel, or is
there more to it? How would I convert a running system to the x32
ABI, if possible?

Alecks

[1] http://distfiles.gentoo.org/experimental/amd64/x32/
 
Old 07-30-2012, 04:55 PM
Alan McKinnon
 
Default x32 ABI

On Mon, 30 Jul 2012 11:40:50 -0500
Alecks Gates <alecks.g@gmail.com> wrote:

> After a recent update to binutils 2.22 I started to look into the x32
> ABI support. It looks very interesting and I am thinking about
> installing it via the experimental stage3[1], but I have some
> questions to ask first.
>
> What are the benefits and drawbacks of using the x32 ABI, other than
> the obvious "experimental" cautions? I currently do not have a
> computer with more than 4GB of ram, and one only has 2GB (used as a
> media center).
>
> How do I go about installing an x32 ABI system? Is it as simple as
> using the x32 stage3 and enabling CONFIG_X86_X32 in the kernel, or is
> there more to it? How would I convert a running system to the x32
> ABI, if possible?

Your first step should be to read flameeye's blog on the matter,
then decide. It's nowhere near at awesome as Intel makes out.

You can find the blog on the front page of gentoo.org under the name
Diego


>
> Alecks
>
> [1] http://distfiles.gentoo.org/experimental/amd64/x32/
>



--
Alan McKinnon
alan.mckinnon@gmail.com
 
Old 07-30-2012, 05:11 PM
Volker Armin Hemmann
 
Default x32 ABI

Am Montag, 30. Juli 2012, 11:40:50 schrieb Alecks Gates:
> After a recent update to binutils 2.22 I started to look into the x32
> ABI support. It looks very interesting and I am thinking about
> installing it via the experimental stage3[1], but I have some
> questions to ask first.
>
> What are the benefits and drawbacks of using the x32 ABI, other than
> the obvious "experimental" cautions? I currently do not have a
> computer with more than 4GB of ram, and one only has 2GB (used as a
> media center).
>
> How do I go about installing an x32 ABI system? Is it as simple as
> using the x32 stage3 and enabling CONFIG_X86_X32 in the kernel, or is
> there more to it? How would I convert a running system to the x32
> ABI, if possible?
>
> Alecks
>
> [1] http://distfiles.gentoo.org/experimental/amd64/x32/

how about: almost zero benefits and lots and lots of downsides?

It was only introduced because ATOM sucks so much in 'real' 64bit mode.

--
#163933
 
Old 07-30-2012, 08:42 PM
"Walter Dnes"
 
Default x32 ABI

On Mon, Jul 30, 2012 at 11:40:50AM -0500, Alecks Gates wrote

> What are the benefits and drawbacks of using the x32 ABI, other than
> the obvious "experimental" cautions? I currently do not have a
> computer with more than 4GB of ram, and one only has 2GB (used as a
> media center).

In theory, real life is identical to theory. In real life, real life
is different from theory. A 32-bit system can directly address 4 gigs
of memory. The problem is that the 4 gigs includes your video ram. So
you lose part of the top end of your 4 gigs of ram, to make room for
your video card's ram. This is true for both linux and Windows. A bit
over 3 gigs is the effective memory max for 32-bit systems.

32-bit linux can access the extra ram for data storage, via some
jumping through flaming hoops, but it's slower than direct addressing
via 64-bit mode. If you have 4 gigs on a machine, it's a candidate for
64-bit mode.

--
Walter Dnes <waltdnes@waltdnes.org>
 
Old 07-31-2012, 02:47 AM
Nikos Chantziaras
 
Default x32 ABI

On 30/07/12 23:42, Walter Dnes wrote:

On Mon, Jul 30, 2012 at 11:40:50AM -0500, Alecks Gates wrote


What are the benefits and drawbacks of using the x32 ABI, other than
the obvious "experimental" cautions? I currently do not have a
computer with more than 4GB of ram, and one only has 2GB (used as a
media center).


In theory, real life is identical to theory. In real life, real life
is different from theory. A 32-bit system can directly address 4 gigs
of memory. The problem is that the 4 gigs includes your video ram. So
you lose part of the top end of your 4 gigs of ram, to make room for
your video card's ram. This is true for both linux and Windows. A bit
over 3 gigs is the effective memory max for 32-bit systems.

32-bit linux can access the extra ram for data storage, via some
jumping through flaming hoops, but it's slower than direct addressing
via 64-bit mode. If you have 4 gigs on a machine, it's a candidate for
64-bit mode.



That's a problem with x86, not x32. x32 is a 64-bit mode. It's a new
ABI :-)
 
Old 07-31-2012, 02:53 AM
Nikos Chantziaras
 
Default x32 ABI

On 30/07/12 19:40, Alecks Gates wrote:

What are the benefits and drawbacks of using the x32 ABI


Benefits: An x32 application is limited to a 32-bit address range but
runs in 64-bit CPU mode. The intent is to not waste any memory, but be
as fast as any other 64-bit application.


Drawbacks: Don't expect to get a fully working system. Many
applications will either not build, or break at runtime when compiled in
this mode. Also, some application will run slower because they come
with hand coded assembly routines for x86 and x86-64, but not for x32.
That means that generic C code paths will be used for x32, and they're
slower compared to the hand optimized assembly routines.


Also note that x32 is not compatible with 32-bit applications. If you
build an x86-64/x32 system, you lose the x86/x86-64 multilib capability
unless there's a way to have a three-way multilib Gentoo with
x86/x32/x86-64.
 
Old 07-31-2012, 03:39 AM
Michael Mol
 
Default x32 ABI

On Mon, Jul 30, 2012 at 10:53 PM, Nikos Chantziaras <realnc@gmail.com> wrote:
> On 30/07/12 19:40, Alecks Gates wrote:
>>
>> What are the benefits and drawbacks of using the x32 ABI
>
>
> Benefits: An x32 application is limited to a 32-bit address range but runs
> in 64-bit CPU mode. The intent is to not waste any memory, but be as fast
> as any other 64-bit application.
>
> Drawbacks: Don't expect to get a fully working system. Many applications
> will either not build, or break at runtime when compiled in this mode.
> Also, some application will run slower because they come with hand coded
> assembly routines for x86 and x86-64, but not for x32. That means that
> generic C code paths will be used for x32, and they're slower compared to
> the hand optimized assembly routines.
>
> Also note that x32 is not compatible with 32-bit applications. If you build
> an x86-64/x32 system, you lose the x86/x86-64 multilib capability unless
> there's a way to have a three-way multilib Gentoo with x86/x32/x86-64.

More specifically, x32 is not compatible with x86 (what we used to
call "32-bit applications on x86"...but since that's ambiguous, it's
better just to say "x86"). In practice, this means you won't be able
to link x32 ELF binaries against x86 ELF binaries.

You'll almost certainly be able to run x86/x32 multilib, since that's
at least part of the argument on behalf of it. But I have no idea when
that'll get set up. When it does, you'll probably be able to run
x86-64/x32/x86 multilib...but then you're compiling apps three ways,
and _that_ seems like it'll be excessive.

On a separate note, I generally recommend amd64 to people who have
processors which can handle it, even if they have as little as 1GB of
RAM. My reasoning is that having the large address space should reduce
memory fragmentation, which should in turn reduce apparent memory
bloat in long-lived applications.




--
:wq
 
Old 07-31-2012, 04:16 AM
Alecks Gates
 
Default x32 ABI

On Mon, Jul 30, 2012 at 10:39 PM, Michael Mol <mikemol@gmail.com> wrote:
> On Mon, Jul 30, 2012 at 10:53 PM, Nikos Chantziaras <realnc@gmail.com> wrote:
>> On 30/07/12 19:40, Alecks Gates wrote:
>>>
>>> What are the benefits and drawbacks of using the x32 ABI
>>
>>
>> Benefits: An x32 application is limited to a 32-bit address range but runs
>> in 64-bit CPU mode. The intent is to not waste any memory, but be as fast
>> as any other 64-bit application.
>>
>> Drawbacks: Don't expect to get a fully working system. Many applications
>> will either not build, or break at runtime when compiled in this mode.
>> Also, some application will run slower because they come with hand coded
>> assembly routines for x86 and x86-64, but not for x32. That means that
>> generic C code paths will be used for x32, and they're slower compared to
>> the hand optimized assembly routines.
>>
>> Also note that x32 is not compatible with 32-bit applications. If you build
>> an x86-64/x32 system, you lose the x86/x86-64 multilib capability unless
>> there's a way to have a three-way multilib Gentoo with x86/x32/x86-64.
>
> More specifically, x32 is not compatible with x86 (what we used to
> call "32-bit applications on x86"...but since that's ambiguous, it's
> better just to say "x86"). In practice, this means you won't be able
> to link x32 ELF binaries against x86 ELF binaries.
>
> You'll almost certainly be able to run x86/x32 multilib, since that's
> at least part of the argument on behalf of it. But I have no idea when
> that'll get set up. When it does, you'll probably be able to run
> x86-64/x32/x86 multilib...but then you're compiling apps three ways,
> and _that_ seems like it'll be excessive.
>
> On a separate note, I generally recommend amd64 to people who have
> processors which can handle it, even if they have as little as 1GB of
> RAM. My reasoning is that having the large address space should reduce
> memory fragmentation, which should in turn reduce apparent memory
> bloat in long-lived applications.
>
>
>
>
> --
> :wq
>

I have just started the process of installing Gentoo from scratch on
on my 2GB RAM machine, and am going to fully compare the two, probably
using Phoronix Test Suite unless someone here can give me some other
recommendations -- I don't do benchmarking and I like how you can do
the comparisons with OpenBenchmarking.org. Hopefully Phornoix Test
Suite runs properly, I suppose I'll have to install php and the like.

Anyway, I don't think anyone addressed this. What would be the
best/cleanest/quickest way to switch from x86-64 to x32 ABI? I'm
planning on just backing up the partition once I've got the x86-64
ready to go and doing a new from scratch install with x32... but I'd
love to know about an easier way.

Alecks
 
Old 07-31-2012, 04:21 AM
"Walter Dnes"
 
Default x32 ABI

On Tue, Jul 31, 2012 at 05:47:22AM +0300, Nikos Chantziaras wrote

> That's a problem with x86, not x32. x32 is a 64-bit mode. It's a
> new ABI :-)

The original poster asked...

> What are the benefits and drawbacks of using the x32 ABI, other
> than the obvious "experimental" cautions? I currently do not have
> a computer with more than 4GB of ram, and one only has 2GB (used as
> a media center).

x32 is a backwards compatability shim for use under 64-bit mode. The
point I was trying to make was that the minimum memory where 64-bit has
clear advantages is 4 gigs. If you have 3 gigs or less, you can stick
with 32-bit mode, and x32 libs become moot.

--
Walter Dnes <waltdnes@waltdnes.org>
 
Old 07-31-2012, 04:43 AM
Nikos Chantziaras
 
Default x32 ABI

On 31/07/12 07:16, Alecks Gates wrote:

I have just started the process of installing Gentoo from scratch on
on my 2GB RAM machine, and am going to fully compare the two, probably
using Phoronix Test Suite unless someone here can give me some other
recommendations -- I don't do benchmarking and I like how you can do
the comparisons with OpenBenchmarking.org. Hopefully Phornoix Test
Suite runs properly, I suppose I'll have to install php and the like.


There's app-benchmarks/phoronix-test-suite. It's 3.8 rather than 4.0
though. I've no idea whether 4.0 has anything important in it though.
 

Thread Tools




All times are GMT. The time now is 02:24 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org