LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-04-2022, 02:10 AM   #1
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
On a 32bit OS on 64bit hardware, can a single or multiple processes utilize all CPU cores?


For historical reasons*, I am running a 32bit PAE Debian system on a 64bit machine with <4GB RAM and 4 logical cores.

I know about the RAM limitations for 32bit, but what about CPU?
I always thought 32bit means it can run only on 1 core at a time - without really thinking much about it.

htop shows all 4 CPUs.
I have a long-running script with some external commands, htop says that CPU utilization is well above 100%, meaning more than 1 core is active at any given time.
Is this actually possible on a 32bit system?

Can a single process utilize more than 1 core?

Can I launch several processes (say, 4) in parallel, so they all utilize all 4 cores @ 100%?

htop's output sure looks like that is possible, but I'm not sure if it's deluding me somehow.

Because if that is possible, what is the limitation of 32bit vs 64bit CPU-wise?

* and yes, I will change that soon
 
Old 03-04-2022, 03:30 AM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,152

Rep: Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125
Quote:
Originally Posted by ondoho View Post
I always thought 32bit means it can run only on 1 core at a time - without really thinking much about it.

htop shows all 4 CPUs.
I have a long-running script with some external commands, htop says that CPU utilization is well above 100%, meaning more than 1 core is active at any given time.
Is this actually possible on a 32bit system?

Can a single process utilize more than 1 core?
Certainly - if (properly) multi-threaded.
Some ditros used to insist on a mono-CPU configuration - (very) early on there were reasons, but not later in the 32-bit cycle. Check your kernel config - it obviously has the SMP option set for you. There will be a limit to the CPU count in there also - maybe 16 or 32; been too many years since I looked for 32-bit.
 
Old 03-04-2022, 04:07 AM   #3
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 22,039

Rep: Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347
Quote:
Originally Posted by ondoho View Post
Because if that is possible, what is the limitation of 32bit vs 64bit CPU-wise?
As far as I know there is no any difference between 32 and 64 bit systems (from this point of view). So both can have parallel execution (multitask) and multithreaded environment.
 
Old 03-04-2022, 11:30 AM   #4
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,691
Blog Entries: 4

Rep: Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947Reputation: 3947
32-bit software can run on a 64-bit machine in a processor compatibility mode. Consider running the 32-bit system as a virtual machine guest on a 64-bit native host.
 
Old 03-04-2022, 12:21 PM   #5
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872

Original Poster
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by syg00 View Post
Check your kernel config - it obviously has the SMP option set for you. There will be a limit to the CPU count in there also - maybe 16 or 32
SMP means Symmetric multiprocessing, yes?
Quote:
Originally Posted by pan64 View Post
As far as I know there is no any difference between 32 and 64 bit systems (from this point of view). So both can have parallel execution (multitask) and multithreaded environment.
Thinking about it more I can see how 32/64 bitness does not define a computer's capability to multitask or use multiple processors in parallel.

Funny, this came as a bit of a surprise for me, never had much interest in the underlying technology...

So, to recap, unless I have lots of RAM or lots of processors it really doesn't matter (almost at all) whether the OS is 32 or 64bit, even if the hardware is clearly 64bit capable?

Am I remembering correctly that 64bitness and multiple processors in consumer hardware just showed up at the same time? And it's a coincidence?
 
Old 03-04-2022, 12:27 PM   #6
EdGr
Senior Member
 
Registered: Dec 2010
Location: California, USA
Distribution: I run my own OS
Posts: 1,003

Rep: Reputation: 474Reputation: 474Reputation: 474Reputation: 474Reputation: 474
Quote:
Originally Posted by ondoho View Post
Am I remembering correctly that 64bitness and multiple processors in consumer hardware just showed up at the same time? And it's a coincidence?
64-bit word size and chip multiprocessors showed up at about the same time in PCs (circa 2005).

However, the symmetric multiprocessor programming model has been around since the 1980s. There were multiprocessor 486 and Pentium PCs (just not single-chip).
Ed
 
1 members found this post helpful.
Old 03-04-2022, 01:22 PM   #7
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 22,039

Rep: Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347Reputation: 7347
Quote:
Originally Posted by ondoho View Post
So, to recap, unless I have lots of RAM or lots of processors it really doesn't matter (almost at all) whether the OS is 32 or 64bit, even if the hardware is clearly 64bit capable?
Yes, looks like it is true.
Quote:
Originally Posted by ondoho View Post
Am I remembering correctly that 64bitness and multiple processors in consumer hardware just showed up at the same time? And it's a coincidence?
I think the 64bit intel based CPUs were born at about 2000: https://en.wikipedia.org/wiki/64-bit_computing,
multicore CPUs were released a few years later probably. In a nutshell both were "enabled" by the same improvements in technology (= density and count of transistors) https://en.wikipedia.org/wiki/Transistor_count
 
1 members found this post helpful.
Old 03-04-2022, 09:35 PM   #8
vmelkon
Member
 
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 549

Rep: Reputation: 84
Quote:
Originally Posted by ondoho View Post
For historical reasons*, I am running a 32bit PAE Debian system on a 64bit machine with <4GB RAM and 4 logical cores.

I know about the RAM limitations for 32bit, but what about CPU?
I always thought 32bit means it can run only on 1 core at a time - without really thinking much about it.

htop shows all 4 CPUs.
I have a long-running script with some external commands, htop says that CPU utilization is well above 100%, meaning more than 1 core is active at any given time.
Is this actually possible on a 32bit system?

Can a single process utilize more than 1 core?

Can I launch several processes (say, 4) in parallel, so they all utilize all 4 cores @ 100%?

htop's output sure looks like that is possible, but I'm not sure if it's deluding me somehow.

Because if that is possible, what is the limitation of 32bit vs 64bit CPU-wise?

* and yes, I will change that soon
People claim that a 32 bit CPU uses 32 bit address which means 2^32 = 4 GB and so, such a CPU can only address a maximum of 4 GB of RAM.
However, in the case of x86 CPUs that support PAE, they can address more than that. The Pentium Pro was the first one capable of this and if you have the right Win NT version, it would utilize PAE.

Source:
https://en.wikipedia.org/wiki/Physic...ress_Extension

I think the Pentium Pro was able to do 36 bit addressing = 2^36 = 64 GB
It seems as if in general, the various Windowses did not use PAE since some drivers did not work properly.
So, there is this myth that x86 CPUs are limited to 4 GB and Windows is limited to 3.3 GB.

According to that page, x86_64 CPUs use 4 level of paging.

A single process usually means 1 thread which means it can use 1 core. The program needs to spawn worker threads and the OS can schedule the other threads onto the other CPUs cores.
The OS might even move a thread from one core to the next.
I think they do this to keep the cores cool enough on modern CPUs and modern CPUs sometimes boost the clock speed for short periods of time (Intel calls it Turbo and AMD calls it something else).

Other than that, x86 CPUs have 8 registers: eax, ebx, ecx, edx, esp, ebp, ip, flag and they might also have the SSE registers, xmm0 to xmm7 and the FPU would have fp0 to fp7.
x86_64 CPUs double the register count.
 
Old 03-05-2022, 01:12 AM   #9
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872

Original Poster
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Thanks all, I think this is SOLVED now!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
64bit distros bootloop. 32bit distro don't. But CPU is 64bit? dfhhsthtrjnb Linux - Hardware 14 08-09-2021 03:55 AM
LXer: Parallel shells with xargs: Utilize all your cpu cores on UNIX and Windows LXer Syndicated Linux News 0 02-17-2021 11:43 AM
How to get physical CPU count, cores per CPU, and CPU type on RHEL and CentOS anon091 Linux - Server 7 01-08-2015 10:57 AM
[SOLVED] what will it take for KVM-Qemu to utilize multi processors(cores)? Static27 Linux - Virtualization and Cloud 10 03-17-2011 11:55 PM
32bit(i386) or 64bit(amd64) on an amd 64bit cpu (amd 6000+)? d-_-b Debian 7 10-28-2007 07:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration