Nick Winters

If I remember correctly, there are 3 dual core processors in the 360. So how fast is threading on it I apologize in advance if this question is vague. This is my first time using something other than a single single core processor.

If I do everything without threads, will the other threads just be idling Or will work be distributed to them automatically

-Nick


Re: XNA Game Studio Express Efficiency of Threads on the 360?

Peter D.

With the 360, you have access to 4 of the 6 threads. The other two are reserved for the operating system and device control.

To use the threads you simply need to set a thread processor affinity. this does nothing on the PC but, is used by the 360 to determine which processor a thread is allocated to.

The threads on the 360 are fast so you can speed up your program considerably if you use them in the correct way.





Re: XNA Game Studio Express Efficiency of Threads on the 360?

Ely

Peter D. wrote:

To use the threads you simply need to set a thread processor affinity. this does nothing on the PC

Is this true on multi core PC cpus






Re: XNA Game Studio Express Efficiency of Threads on the 360?

Peter D.

In windows, the operating system does the allocation for you based on cpu usage. You can set the affinity but, it will not determine which processor you run on. On the 360 however, the affinity is needed otherwise the 360 will not allocate your thread to a seperate processor at all.

The 360 is designed to do multithreading for games and so the Microsoft guys needed to ensure that the cpu cores could be best used by developers hence thread affinity is actually taken into account when allocating resources.

In the world of windows, the operating system decides resource allocation and so is free to ignore your processor requests based on system load at the time the request was issued.






Re: XNA Game Studio Express Efficiency of Threads on the 360?

Ely

Good to know, thanks!




Re: XNA Game Studio Express Efficiency of Threads on the 360?

Jon Watte

Actually, if you use the Win32 thread affinity API, that does decide what CPU core or cores the thread will run on. What you may mean to say is that the thread affinity functions found for the Xbox in XNA are implemented to do nothing on Windows -- this may be true; I don't really know.