Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
why n32 for mips64el (Loongson 2F)?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on Alternative Architectures
View previous topic :: View next topic  
Author Message
LoTeK
Apprentice
Apprentice


Joined: 26 Jul 2012
Posts: 270

PostPosted: Mon Apr 15, 2013 10:53 pm    Post subject: why n32 for mips64el (Loongson 2F)? Reply with quote

hi,
I've tried to gentoo and parabola on my yeeloong 8089 both with 32bit libraries and according to http://dev.lemote.com/trac/linux-loongson-community#Gentoon32 the lemote website there are only n32 distributions. Why? Since the architecture is 64bit wouldn't it be better to choose n64? afaik there are many x86_64 users that use 64bit libraries only.

Moreover there is always the gcc option "mips64el-unknown-gnu-linux", but since stallman is maybe the greatest supporter of this architecture I don't understand why the gcc-developers don't focus more on this CPU. does anybody know anything about this?
_________________
"I want to see gamma rays! I want to hear X-rays! Do you see the absurdity of what I am? I can't even express these things properly because I have to conceptualize complex ideas in this stupid limiting spoken language!"
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7470

PostPosted: Tue Apr 16, 2013 12:31 am    Post subject: Reply with quote

Maybe just because of memory eat by 64bits.
I'm sure you wouldn't enjoy a system that keep swapping and goes oom... Assuming your system have only 1g
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 6920

PostPosted: Tue Apr 16, 2013 1:37 am    Post subject: Re: why n32 for mips64el (Loongson 2F)? Reply with quote

LoTeK wrote:
Since the architecture is 64bit wouldn't it be better to choose n64? afaik there are many x86_64 users that use 64bit libraries only.

x86-64 is only the default there because x32 didn't exist for the first 8 years or so of the architecture. MIPS64/PPC64 had better ABIs from the start.
Back to top
View user's profile Send private message
LoTeK
Apprentice
Apprentice


Joined: 26 Jul 2012
Posts: 270

PostPosted: Tue Apr 16, 2013 12:10 pm    Post subject: Reply with quote

Quote:
Maybe just because of memory eat by 64bits.
I'm sure you wouldn't enjoy a system that keep swapping and goes oom... Assuming your system have only 1g

Can you explain this? Let me sumarize what I believe to know: :)

Loongson 2F is a 64-bit processor, therefore his registers has a size of 64bit. Most of all real world programs have a lot more code and data, therefore RAM exists (which is 1GB on my yeeloong). Then there is cache, something like a middleman between RAM and the CPU registers. Now during an execution of a program there is a always data that will be loaded from RAM to cache and then to the registers and vice versa. Now (besides programs that only work with 32bit) it takes less swapping with a 64bit CPU than with a 32bit CPU. therefore a 64bit system would be faster or at least as fast as a 32bit system.

Moreover why are todays CPU's mostly 64bit CPU's when we don't need them? I thought the only reason for not changing to 64bit only is for backwards compatibility and because I don't need to do "daily work" on the yeeloong I can live with only 64bit programs.

Quote:

LoTeK wrote:
Since the architecture is 64bit wouldn't it be better to choose n64? afaik there are many x86_64 users that use 64bit libraries only.

x86-64 is only the default there because x32 didn't exist for the first 8 years or so of the architecture. MIPS64/PPC64 had better ABIs from the start.

I thought with x86_64 the default are 64bit libs and 32bit libs for backward compatibility and because most of todays software don't exploit the capabilities of a 64bit architecture. And if MIPS64 had better ABI's it should be working even better with only 64bit libraries?!
_________________
"I want to see gamma rays! I want to hear X-rays! Do you see the absurdity of what I am? I can't even express these things properly because I have to conceptualize complex ideas in this stupid limiting spoken language!"
Back to top
View user's profile Send private message
LoTeK
Apprentice
Apprentice


Joined: 26 Jul 2012
Posts: 270

PostPosted: Wed Apr 17, 2013 5:30 pm    Post subject: Reply with quote

@krinn
I do understand your post now, I thought n32 is a 32bit library, not a 64bit library with 32bit pointers. :)

mattst88 told me that the yeeloong is not useable for anything that needs 64bit pointers and therefore it would only use more RAM like you said..
_________________
"I want to see gamma rays! I want to hear X-rays! Do you see the absurdity of what I am? I can't even express these things properly because I have to conceptualize complex ideas in this stupid limiting spoken language!"
Back to top
View user's profile Send private message
mattst88
Developer
Developer


Joined: 28 Oct 2004
Posts: 422

PostPosted: Fri Jul 19, 2013 9:04 pm    Post subject: Reply with quote

N32 *is* a 64-bit ABI. It gives you many advantages over the Old 32-bit ABI, like more floating point registers, a sane function calling convention, and native 64-bit integers.

Your Lemote has a maximum of 2 GB of RAM, which is the per-process limit for N32. Using N64 would give you a higher per-process limit, but in order to use it you'd be swapping badly, so that's not a useful feature. N64 also uses more memory and cache, since the pointers are double in size so you'll actually get worse performance than with N32.

So N32 is what you want to use.
_________________
My Wiki page
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on Alternative Architectures All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum