A place to discuss everything related to Newton Dynamics.
Moderators: Sascha Willems, walaber
by ruslannow » Tue Aug 17, 2010 11:35 am
Hi all, need your advice ..
For example, we have the processor 4 cores (1,2,3,4)
how to tell the Newton, it is possible to use only 2,3,4 but 1 - do not use?
Thanks!
I probably wrote a raving
I need to reserve for rendering one stream
so it will be correct?
NewtonSetThreadsCount(3)
-

ruslannow
-
- Posts: 13
- Joined: Fri May 28, 2010 1:09 pm
- Location: Ukraine
by Julio Jerez » Tue Aug 17, 2010 1:21 pm
yes you can,
In a PC there is not much control an end application has over what core is executing what thread.
The best you can hope is to make the jobs load big enought so thar the OS assign the same core to the same job in each time slice.
In my expirience, if you have a core duo or a quad core that does not have shared memory, two threads works very good.
if you haveaintel ICore7 then 3 threads is better than 4, bu 4 is goo for very large set.
-
Julio Jerez
- Moderator

-
- Posts: 12452
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
by ruslannow » Tue Aug 17, 2010 1:50 pm
Thank you very much
-

ruslannow
-
- Posts: 13
- Joined: Fri May 28, 2010 1:09 pm
- Location: Ukraine
by Stucuk » Tue Aug 17, 2010 7:03 pm
You can have multiple threads running on one core. Applications have used multiple threads before Duel Cores were invented.
-

Stucuk
-
- Posts: 801
- Joined: Sat Mar 12, 2005 3:54 pm
- Location: Scotland
-
by Julio Jerez » Tue Aug 17, 2010 8:17 pm
No to confuse, yes you are right you can have many threads with only one core serving then, but this is good for Operating system running several application.
because it makes then feel more responsive to the user, but for a single apps using many thread, in general makes the application slower.
It is only when you have more cores or CPU than a single app benefic from running several sub systems in separate threads.
when you have more thread than cores, and each thread does some actual work, the you start to get diminishing return.
basically when you run a newton update, the engine have number of tjhred tah are sliping.
the teh main core set and nome of job into and array of quees an dsen deach ques to each thread,
the the main thead goes to sleep int a barrier until the main thread child threa compile teh jobs.
so when yo uget is a numeb oftread each with large jobs, teh hop i the the core are all busse serving one job with out spenig too much time in task swrting.
The word fine if there are not too many operation system tread working,
In the future this will be modifed to use microthreads.
where there will be just one task job array each with a small job, then the job will be dispach to an array of thread ans ther are completed.
this system is better for computer with sevaral CPs, lie eh 8 cores and 16 cores intel is planning.
for now for syetm wih 2 or 4 cores the syetem we have now works fine.
I may use the Intel Thread Library whis support all those configration rather than meanu my own threa pool manager.
-
Julio Jerez
- Moderator

-
- Posts: 12452
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
Return to General Discussion
Who is online
Users browsing this forum: No registered users and 382 guests