Author Topic: X4 parallel processing  (Read 21491 times)

Offline bly

  • Jr. Member
  • *
  • Posts: 3
X4 parallel processing
« on: June 24, 2010, 01:35:11 AM »
How does one feed intructions to all 4 processors on an X4 in parallel?  Is there a 256 bit register?

Offline Keith Kanios

  • Full Member
  • **
  • Posts: 383
  • Country: us
    • Personal Homepage
Re: X4 parallel processing
« Reply #1 on: June 24, 2010, 07:06:45 AM »
How does one feed intructions to all 4 processors on an X4 in parallel?  Is there a 256 bit register?

With lots of specialized design and locking/syncing, but even then there's no guarantee of absolutely precise parallel processing.

Moreover, you'll probably want to avoid this scenario unless you are processing different data sets in parallel, else any gain in processing speed will probably be negated by cache trashing/locking/syncing.


Is there a 256 bit register?

Yes, the YMM register set that is apart of AVX, but AFAIK no retail x86 processor has them yet.

Offline Phopojijo

  • Jr. Member
  • *
  • Posts: 4
Re: X4 parallel processing
« Reply #2 on: June 24, 2010, 09:36:16 PM »
I think those questions were actually meant to be linked together.

In a 4 core processor... you really do have 4 sets of all the registers we know and love. You don't need a 256-bit register to do 4 64-bit operations... that would actually be ugly as every core would basically need to do the same instruction... which really limits its use.

You might be confused by MMX/SSE which do that tactic for several variables that are kinda tied together (works well for many Vector for instance like -- add two R,G,B,A colours together. Instead of doing 4 additions Red + Red, Green + Green, Blue + Blue, Alpha + Alpha... you do one huge one once).

This is not how multicore processors work... again -- a quadcore CPU has the functional parts of a typical CPU duplicated 4 times on the same chip (+ some other stuff like shared cache, queue, etc. on the side)

It really is almost entirely up to the OS (and the CPU itself) to determine which thread goes on what core at any given time. All you can do is say "Hey I want this string of code and this string of code separate". The OS then shares time based on priority settings, what program has focus, etc.

If you look at the CPU Die itself -- you can actually see the mirroring of the CPUs.

« Last Edit: June 24, 2010, 09:39:50 PM by Phopojijo »

Offline bly

  • Jr. Member
  • *
  • Posts: 3
Re: X4 parallel processing
« Reply #3 on: June 24, 2010, 11:09:02 PM »
Actually, I am looking at making a basic operating system.  Since I am doing this, do I need to try to control what each processor, on a four processor chip, does, or do I leave it up to the chip?

Thanks very much.
« Last Edit: June 24, 2010, 11:21:27 PM by bly »

Offline Phopojijo

  • Jr. Member
  • *
  • Posts: 4
Re: X4 parallel processing
« Reply #4 on: June 25, 2010, 01:04:40 AM »
Ah, your 256-bit question threw me off.

Don't know...

Offline Keith Kanios

  • Full Member
  • **
  • Posts: 383
  • Country: us
    • Personal Homepage
Re: X4 parallel processing
« Reply #5 on: June 25, 2010, 08:29:42 AM »
Actually, I am looking at making a basic operating system.  Since I am doing this, do I need to try to control what each processor, on a four processor chip, does, or do I leave it up to the chip?

Intel's Multiprocessor Specification is a good starting point.

Offline bly

  • Jr. Member
  • *
  • Posts: 3
Re: X4 parallel processing
« Reply #6 on: June 26, 2010, 04:16:56 AM »
Thanks very much Phopojijo and Keith.

I found the specification extremely helpful!
« Last Edit: June 26, 2010, 04:21:28 AM by bly »