Solved

choosing the processor for a program!

Posted on 2000-03-02
3
200 Views
Last Modified: 2010-04-02
I have a NT server with 4 processors. I need to know how to start up programs from my TrafficCop on each separate processor so the four programs run parallel to each other. I have noticed that we are not using the full potential, let alone all of the processors. Is it up to my program to decide which processors to run on or is it up to the OS? How is this performed?
0
Comment
Question by:rrrrr80
3 Comments
 
LVL 3

Expert Comment

by:Iexpert
ID: 2576875
Obviously the OS must deal with it.
If a program supports running seperate instances of itself then
doing this allows the OS to spread them out over multiple processors.
If only one intance of a program can be started, then the program
must be explicitly written to use multiple threads, and again the
OS can share these out amoung the processors.
In summary it depends on how the programs are written.
0
 
LVL 32

Accepted Solution

by:
jhance earned 40 total points
ID: 2576906
See the:

SetProcessAffinityMask()

in the SDK if you want to specify.  Otherwise NT will decide for you based on load.
0
 

Author Comment

by:rrrrr80
ID: 2589132
That is exactly what I was looking for!
Sorry it took me this long to get back to you! thanks again for the info!
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The goal of the video will be to teach the user the concept of local variables and scope. An example of a locally defined variable will be given as well as an explanation of what scope is in C++. The local variable and concept of scope will be relat…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now