jahboater
Posts: 4837
Joined: Wed Feb 04, 2015 6:38 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 12:45 pm

dickon wrote:
Tue Aug 06, 2019 12:29 pm
Vanishingly few, for good and obvious reasons. But that's rather beside the point.

The actual question is how many functions do I have which require local scalar variables to be preserved between function calls, and that's a: a *very* different question, and b: a much, much greater set.
Perhaps take a look at the output from a recent version of GCC?
It seems to waste more space keeping the stack aligned to 16 bytes :(

LTolledo
Posts: 2146
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Why moving to 64bit?

Tue Aug 06, 2019 1:24 pm

rpdom wrote: LTolledo wrote: ↑
Tue Aug 06, 2019 7:11 pm
Will GPIO inputs be read faster with 64bit?

will GPIO outputs switch faster on 64bit?
No, because unless things have changed a lot, the GPIOs are 32 bit based and are in banks of 32 bits.
Ok then.... I'll move to 64bit if the RPF supplied OS (and apps) goes 64bit.... otherwise I'll stick to the present 32bit...
(or unless enacted as a law that carries stiff penalties for non-compliance) :mrgreen:
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

jahboater
Posts: 4837
Joined: Wed Feb 04, 2015 6:38 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 2:24 pm

LTolledo wrote:
Tue Aug 06, 2019 1:24 pm
rpdom wrote: LTolledo wrote: ↑
Tue Aug 06, 2019 7:11 pm
Will GPIO inputs be read faster with 64bit?

will GPIO outputs switch faster on 64bit?
No, because unless things have changed a lot, the GPIOs are 32 bit based and are in banks of 32 bits.
Ok then.... I'll move to 64bit if the RPF supplied OS (and apps) goes 64bit.... otherwise I'll stick to the present 32bit...
(or unless enacted as a law that carries stiff penalties for non-compliance) :mrgreen:
You can do 32-bit reads and writes in aarch64 anyway.

ldr w5, ....
str w5, ...

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 24139
Joined: Sat Jul 30, 2011 7:41 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 2:44 pm

jahboater wrote:
Tue Aug 06, 2019 12:17 pm
It does work, and my experiments showed quite small performance decrease not being scheduled for the new CPU. It just seems incongruous to me! How wide will the gap get - a Pi6 with an A77 CPU running ARMv6 code?

I don't want Raspbian to end up being frozen in time like RISC-OS (which is hand written ARM 32 assembler, mostly very old).
I expect by Pi6 (and Pi5 TBH) that we will have an official 64bit OS. It's being worked on by various community people, whilst we get on with bug fixing the current stuff (which of course is often applicable to 64bit as well). People need to remember we are a tiny team, about 8 SW guys on Linux & firmware with a contractor on Chromium stuff, and there are limits to how much and how fast we can get stuff down. We do contract in Mesa/KMS stuff as well, which is a godsend as we have no-one in house with the relevant experience, although we are learning by osmosis.

So if anyone want to help out, check out our issues list here https://github.com/raspberrypi/linux/issues , pick a bug, and get fixing! That's the beauty of OSS, anyone can pitch in! * The more bugs that get fixed, the more time we have to spend on getting an official 64bit distro.




(* although hardly anyone ever does...)
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

jerrm
Posts: 200
Joined: Wed May 02, 2018 7:35 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 3:14 pm

The same no/limited benefit arguments were made for 32 bit, and will be made for the next generation.

I agree 64 bit vs 32 bit is irrelevant for most workloads, but some do benefit. Beyond the number of bits are the compiler optimizations that can be enabled leaving older CPU support behind, and is likely where larger general performance gains will be found.

64 bit is inevitable, go ahead move forward as quickly as practical (but it doesn't have be overnight).

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 24139
Joined: Sat Jul 30, 2011 7:41 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 3:17 pm

jerrm wrote:
Tue Aug 06, 2019 3:14 pm
64 bit is inevitable, go ahead move forward as quickly as practical (but it doesn't have be overnight).
Exactly what we are doing....
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

LTolledo
Posts: 2146
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Why moving to 64bit?

Tue Aug 06, 2019 3:20 pm

jerrm wrote:
Tue Aug 06, 2019 3:14 pm
64 bit is inevitable, go ahead move forward as quickly as practical (but it doesn't have be overnight).
therefore 128bit is also inevitable... as well as 256bit.... so on and so forth....(but it doesn't have be overnight). <-- borrowing this ;)
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

jerrm
Posts: 200
Joined: Wed May 02, 2018 7:35 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 5:13 pm

LTolledo wrote:
Tue Aug 06, 2019 3:20 pm
therefore 128bit is also inevitable... as well as 256bit.... so on and so forth....(but it doesn't have be overnight). <-- borrowing this ;)
The difference being that 64bit OS's have been common and mainstream for pushing 15 years or so, and the default OS platform on desktops for 10 years.

But bring the 64 bit subject up here and your a heretic.

I think things would be better served with a published roadmap type FAQ entry with some proper disclaimers and point users to existing 64bit options. Put it on someones calendar to update every six months or so to keep it current(ish). Anytime someone brings up 64 bit, point them to it and let that be the end of it.

webbsmurfen
Posts: 59
Joined: Fri Jun 27, 2014 12:22 pm
Location: Sweden

Re: Why moving to 64bit?

Tue Aug 06, 2019 6:12 pm

jamesh wrote:
Tue Aug 06, 2019 2:44 pm
jahboater wrote:
Tue Aug 06, 2019 12:17 pm
It does work, and my experiments showed quite small performance decrease not being scheduled for the new CPU. It just seems incongruous to me! How wide will the gap get - a Pi6 with an A77 CPU running ARMv6 code?

I don't want Raspbian to end up being frozen in time like RISC-OS (which is hand written ARM 32 assembler, mostly very old).
I expect by Pi6 (and Pi5 TBH) that we will have an official 64bit OS. It's being worked on by various community people, whilst we get on with bug fixing the current stuff (which of course is often applicable to 64bit as well). People need to remember we are a tiny team, about 8 SW guys on Linux & firmware with a contractor on Chromium stuff, and there are limits to how much and how fast we can get stuff down. We do contract in Mesa/KMS stuff as well, which is a godsend as we have no-one in house with the relevant experience, although we are learning by osmosis.

So if anyone want to help out, check out our issues list here https://github.com/raspberrypi/linux/issues , pick a bug, and get fixing! That's the beauty of OSS, anyone can pitch in! * The more bugs that get fixed, the more time we have to spend on getting an official 64bit distro.




(* although hardly anyone ever does...)
Oftopic
You know, even though you guys are few, you have really managed to get a stable and good Debian based OS, almost as stable and smooth as Windows. Now look at other OSes based on Debian that you can run on a Raspberry PI. Some are extremely sluggish, Ethernet connection seems to have at least one bug. It won’t connect through ethernet without some “heavy terminal karate” some times. You can’t just connect the cable and its working. It drops some wireless USB keyboard/mouse combination in minutes (it drops it on Raspbian as well but maybe in 35-45 minutes) and so on with many small bugs

We should all be grateful for your work. If changing it to a 64 bit will result in a likewise sluggish OS its better to let it be a 32 bit, and go for a solution that allows some specific programs to run in 64 bit mode .

jahboater
Posts: 4837
Joined: Wed Feb 04, 2015 6:38 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 6:31 pm

webbsmurfen wrote:
Tue Aug 06, 2019 6:12 pm
You know, even though you guys are few, you have really managed to get a stable and good Debian based OS,
Exactly. That's the problem! If Raspbian was not such a great, well supported, well produced OS, then I'd abandon it and use Ubuntu 64 or whatever the latest thing is.
webbsmurfen wrote:
Tue Aug 06, 2019 6:12 pm
almost as stable and smooth as Windows.
Raspbian is more stable and smooth than any Windows version I have ever used. It doesn't BSOD, it doesn't do random updates and reboots, and so on. Stability is one reason why Linux is dominant in the server market.
webbsmurfen wrote:
Tue Aug 06, 2019 6:12 pm
It won’t connect through ethernet without some “heavy terminal karate” some times. You can’t just connect the cable and its working. It drops some wireless USB keyboard/mouse combination in minutes (it drops it on Raspbian as well but maybe in 35-45 minutes)
Maybe there is something wrong with your router?

Ethernet works fine on Raspbian, and for years at a time by all accounts.

chipace
Posts: 79
Joined: Sat Jun 29, 2019 2:56 am
Location: brown paper bag in a septic tank

Re: Why moving to 64bit?

Tue Aug 06, 2019 7:12 pm

From a historical perspective, I believe Microsoft waited many years after x86-64 hardware was in circulation before it offered a 64bit OS.

Maybe we could have a kickstarter to get the Zero hardware upgraded to an a53 core? Put it on a newer process and get even lower current consumption. When the Zero is 64bit hardware, I am thinking the Foundation would consider a 64bit Raspbian.

drgeoff
Posts: 9917
Joined: Wed Jan 25, 2012 6:39 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 7:21 pm

chipace wrote:
Tue Aug 06, 2019 7:12 pm
Maybe we could have a kickstarter to get the Zero hardware upgraded to an a53 core? Put it on a newer process and get even lower current consumption.
Please reply with your estimate of much would need to be pledged.

If your estimate is too low, we can have a good laugh at how little you know about the NRE required.

If your estimate is about correct we can have a good laugh at your optimism of a Kickstarter raising that much.

plugwash
Forum Moderator
Forum Moderator
Posts: 3476
Joined: Wed Dec 28, 2011 11:45 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 7:21 pm

chipace wrote:
Tue Aug 06, 2019 7:12 pm
From a historical perspective, I believe Microsoft waited many years after x86-64 hardware was in circulation before it offered a 64bit OS.
Windows XP proffesional x64 edition was released in april 2005, about 2 years after the first x86-64 chips started shipping. Unfortunately windows XP proffesional x64 edition was only available through the OEM and volume license channels, not retail and most computer vendors either didn't offer it at all or only offered it on high end workstation/server systems.

Vista made x64 support a first class citizen, but most people avoided it, so it was only with windows 7 that x64 windows started to go mainstream.

W. H. Heydt
Posts: 11085
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: Why moving to 64bit?

Tue Aug 06, 2019 7:48 pm

chipace wrote:
Tue Aug 06, 2019 7:12 pm
From a historical perspective, I believe Microsoft waited many years after x86-64 hardware was in circulation before it offered a 64bit OS.

Maybe we could have a kickstarter to get the Zero hardware upgraded to an a53 core? Put it on a newer process and get even lower current consumption. When the Zero is 64bit hardware, I am thinking the Foundation would consider a 64bit Raspbian.
Don't forget the CM, which has availability guarantees. (Though if a 64-bit capable Pi0 were feasible, the same SoC could probably be implemented on a pin compatible CM.)

jamesh
Raspberry Pi Engineer & Forum Moderator
Raspberry Pi Engineer & Forum Moderator
Posts: 24139
Joined: Sat Jul 30, 2011 7:41 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 8:51 pm

jerrm wrote:
Tue Aug 06, 2019 5:13 pm
But bring the 64 bit subject up here and your a heretic.
Not really. It's discussed a lot without any one saying "Burn the witch, burn her with FIRE"
jerrm wrote:
Tue Aug 06, 2019 5:13 pm
I think things would be better served with a published roadmap type FAQ entry with some proper disclaimers and point users to existing 64bit options. Put it on someones calendar to update every six months or so to keep it current(ish). Anytime someone brings up 64 bit, point them to it and let that be the end of it.
We don't have a SW road map. We have a list of stuff that needs doing and that changes regularly! One could argue this approach is a bit haphazard, but the amount of works that comes out the other end it's quite large so it works. I suspect a larger team would require something a little more solid to stand on.

We do have a HW roadmap, and on the whole we need software to run on that hardware, which drives the SW side
Principal Software Engineer at Raspberry Pi (Trading) Ltd.
Contrary to popular belief, humorous signatures are allowed. Here's an example...
“I think it’s wrong that only one company makes the game Monopoly.” – Steven Wright

chipace
Posts: 79
Joined: Sat Jun 29, 2019 2:56 am
Location: brown paper bag in a septic tank

Re: Why moving to 64bit?

Tue Aug 06, 2019 9:23 pm

jamesh wrote:
Tue Aug 06, 2019 8:51 pm
We do have a HW roadmap, and on the whole we need software to run on that hardware, which drives the SW side
Would a 64bit Zero be in the roadmap? If there was, would that help the transition to a 64bit Raspbian?

jerrm
Posts: 200
Joined: Wed May 02, 2018 7:35 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 9:25 pm

plugwash wrote:
Tue Aug 06, 2019 7:21 pm
Windows XP proffesional x64 edition was released in april 2005, about 2 years after the first x86-64 chips started shipping. Unfortunately windows XP proffesional x64 edition was only available through the OEM and volume license channels, not retail and most computer vendors either didn't offer it at all or only offered it on high end workstation/server systems.

Vista made x64 support a first class citizen, but most people avoided it, so it was only with windows 7 that x64 windows started to go mainstream.
To be really irrelevant, Windows XP 64 bit for Itanium goes back to 2001. WinXP x86-64 was available months after the first INTEL x86-64 chips shipped, pretty much in sync with the first volume availability of Intel x86-64. There is a reason Debian calls it amd64.

WinXP x86-64 was readily available to anyone that wanted it. It wasn't consumer retail. but OEM only never stopped anyone and it was available via the license programs.

Win Server 2003 x86-64 uptake was widespread from the day it was released alongside XP x86-64.
Last edited by jerrm on Wed Aug 07, 2019 1:42 am, edited 1 time in total.

MisterEd
Posts: 104
Joined: Mon Apr 16, 2018 5:28 am
Location: Huntsville, AL USA

Re: Why moving to 64bit?

Tue Aug 06, 2019 9:43 pm

As long as there are Raspberry Pis with 1GB or less RAM and those with minimal hardware requirements there will be a need for a 32-bit version of Raspbian. Once a 64-bit version of Raspbian is developed both a 32-bit and 64-bit versions will have to be maintained for period of time. The same for software and drivers. The question is can the Raspberry Pi Foundation handle this burden?

BTW, Microsoft has been supporting both 32-bit and 64-bit versions of Windows for 12 years now. Of course Microsoft has plenty of resources to do this.

jerrm
Posts: 200
Joined: Wed May 02, 2018 7:35 pm

Re: Why moving to 64bit?

Tue Aug 06, 2019 10:14 pm

MisterEd wrote:
Tue Aug 06, 2019 9:43 pm
BTW, Microsoft has been supporting both 32-bit and 64-bit versions of Windows for 12 years now. Of course Microsoft has plenty of resources to do this.
More like 18 years, as have virtually all linux distros.

Hopefully there are making higher margins on the 2GB and 4GB boards to justify some extra resources.

I could see Bullseye being the first official full 64 bit release and maybe the last 32 bit. Assuming a 64 bit zero or similar is in the future. Debian LTS will take Bullseye through the announced obsolescence dates for the existing boards. Maybe extend 32 bit one more release through Bookworm for some overlap. All depends on what hardware they have in the pipeline.

MisterEd
Posts: 104
Joined: Mon Apr 16, 2018 5:28 am
Location: Huntsville, AL USA

Re: Why moving to 64bit?

Tue Aug 06, 2019 11:55 pm

jerrm wrote:
Tue Aug 06, 2019 10:14 pm
MisterEd wrote:
Tue Aug 06, 2019 9:43 pm
BTW, Microsoft has been supporting both 32-bit and 64-bit versions of Windows for 12 years now. Of course Microsoft has plenty of resources to do this.
More like 18 years, as have virtually all linux distros.
I hate to quibble but while it was true a test version of 64-bit linux was demonstrated in 2001 it was on a simulator. The reason was there were no x86 based 64-bit CPUs at the time.

AMD introduced the first x86 based 64-bit processors the Opteron in April 2003 followed by the Athlon 64 in September 2003. Intel did not have an x86 based 64-bit processor until 2004. Since AMD was first with its AMD64 architecture Intel ended up licensing it and renaming it Intel 64.

The first 64-bit Linux distributions were released in 2003 after AMD released its 64-bit CPUs with its AMD64 architecture. People wanting to run it on an Intel CPU had to wait a year or more after that because there were no x86 based Intel 64-bit CPUs until 2004.

Microsoft followed suit in April 2005 with the release of Window XP Professional x64 which supported AMD64 and EM64T (later renamed Intel 64).

The ARMv8-A architecture was the first to support 64-bits in 2011.

The first Arm64 release of Debian was Jessie in 2015. It was followed by Stretch in 2017.

This shows that 64-bit support on ARM CPUs is still relatively recent compared to Intel and AMD CPUs.

ejolson
Posts: 3820
Joined: Tue Mar 18, 2014 11:47 am

Re: Why moving to 64bit?

Wed Aug 07, 2019 12:52 am

MisterEd wrote:
Tue Aug 06, 2019 11:55 pm
jerrm wrote:
Tue Aug 06, 2019 10:14 pm
MisterEd wrote:
Tue Aug 06, 2019 9:43 pm
BTW, Microsoft has been supporting both 32-bit and 64-bit versions of Windows for 12 years now. Of course Microsoft has plenty of resources to do this.
More like 18 years, as have virtually all linux distros.
I hate to quibble but while it was true a test version of 64-bit linux was demonstrated in 2001 it was on a simulator. The reason was there were no x86 based 64-bit CPUs at the time.
As far as quibbling goes, 64-bit Linux first ran on DEC Alpha in 1995. That appears to be 24 years ago. It is possible support for SUN UltraSPARC running in 64-bit mode happened around the same time, but I was not paying attention.

jerrm
Posts: 200
Joined: Wed May 02, 2018 7:35 pm

Re: Why moving to 64bit?

Wed Aug 07, 2019 1:38 am

MisterEd wrote:
Tue Aug 06, 2019 11:55 pm
jerrm wrote:
Tue Aug 06, 2019 10:14 pm
MisterEd wrote:
Tue Aug 06, 2019 9:43 pm
BTW, Microsoft has been supporting both 32-bit and 64-bit versions of Windows for 12 years now. Of course Microsoft has plenty of resources to do this.
More like 18 years, as have virtually all linux distros.
I hate to quibble but while it was true a test version of 64-bit linux was demonstrated in 2001 it was on a simulator. The reason was there were no x86 based 64-bit CPUs at the time.
Yeah, things got conflated there a little. MS has been maintaining 32/64 bit editions of Windows since 2001 (18 years). General Linux distros maybe not quite as long. I suspect there was probably some early IA64 Linux builds out there but off my radar, my primary *nix's at the time were probably Solaris & FreeBSD.

wren
Posts: 78
Joined: Mon May 28, 2018 9:06 pm

Re: Why moving to 64bit?

Wed Aug 07, 2019 4:08 am

You're only supposed to use hardware a year or two then throw it away. i686 is on the support chopping block and it wont be long until 32-bit ARM is too.

dickon
Posts: 563
Joined: Sun Dec 09, 2012 3:54 pm
Location: Home, just outside Reading

Re: Why moving to 64bit?

Wed Aug 07, 2019 8:52 am

I had a 64b Alpha workstation in 1998-1999, after leaving university with its fleet of 64b Irix desktops. So yes, at least 20 years.

The x86 world was an irrelevance to serious computing back then. It's hideous even now.

LTolledo
Posts: 2146
Joined: Sat Mar 17, 2018 7:29 am
Location: Anime Heartland

Re: Why moving to 64bit?

Wed Aug 07, 2019 11:07 am

in our current world where going from "32bit to 64bit is inevitable"

8bit microprocessors/micro-controllers still proliferate.....and so signs of fading out (yet).....
"Don't come to me with 'issues' for I don't know how to deal with those
Come to me with 'problems' and I'll help you find solutions"

Some people be like:
"Help me! Am drowning! But dont you dare touch me nor come near me!"

Return to “General discussion”