project-navigation
Personal tools

Author Topic: Symmetric Multi Processing  (Read 3826 times)

Offline mikeg

  • Rookie
  • ***
  • Posts: 24
    • View Profile
Symmetric Multi Processing
« on: October 09, 2010, 03:29:19 pm »
Hello,

I just think about the possibility to support more than one CPU core. I have a AMD 64 X2 Dual core. What about to support that by using e.g. OpenMP library?

Regards

Mike

Offline Crystan

  • Project Artist
  • Captain
  • ***
  • Posts: 572
  • UFO:AI Lead Sound Artist
    • View Profile
    • http://crysea.cr.funpic.de/
Re: Symmetric Multi Processing
« Reply #1 on: October 09, 2010, 03:55:53 pm »
It does already, not sure about 2.3.


Offline mikeg

  • Rookie
  • ***
  • Posts: 24
    • View Profile
Re: Symmetric Multi Processing
« Reply #2 on: October 09, 2010, 04:19:30 pm »
Thank you for the information, I never saw this.

Offline Mattn

  • Administrator
  • PHALANX Commander
  • *****
  • Posts: 4831
  • https://github.com/mgerhardy/vengi
    • View Profile
    • Vengi Voxel Tools
Re: Symmetric Multi Processing
« Reply #3 on: October 09, 2010, 04:50:15 pm »
we are using threads for the server logic, random map assembly and the renderer (sv_threads and r_threads cvars)

but we are not using opemmp

Offline mikeg

  • Rookie
  • ***
  • Posts: 24
    • View Profile
Re: Symmetric Multi Processing
« Reply #4 on: October 10, 2010, 10:13:55 am »
Hello Mattn,

am I right with that when I'm saying that a thread is <not> a multi processing with more than one core? I mean that thread <main> is executed by core 1 and thread <renderer> is executed e.g. by core 2 while sound generation is done by core 3, and so on.

As I read the specs correct, threads simulate by processor-time-sharing that many processes are executed at the same time. The operating system will do this using software interrupts. This is why threads are working on single core cpus, too.

I will just take a look into the source where threads are generated and see how this is done. Maybe there is a possible issue to speed up performance.

Best regards

Mike