Click to See Complete Forum and Search --> : Programming For Dual Processors?


softweng
October 3rd, 2001, 12:12 PM
I am going to be writing an app that will run on a dual processor system.
I was wondering if there are any special programming considerations
that should be used in order to take advantage of the dual processors.
If anyone has any experience with this please let know what if anything
different I should do when writing this app. I will probably be
using VB.NET but examples in VB6 will be great.
Thanks for any help you can provide!!!

Kris
Software Engineer
Phoenix,AZ

softweng
October 4th, 2001, 10:39 AM
Has anyone done this before?

Kris
Software Engineer
Phoenix,AZ

DSJ
October 4th, 2001, 11:07 AM
I haven't done it, nor do I claim to know anything about it, so take this for what it's worth.

Used to, in the "old days" I think there were things you could do to make things work better due to the OSes of the time and the actual hardware architecture, but I think with todays machines and OSes you don't have to worry about it, it's all handle internally by the OS and hardware. The exception to this may be if you do any multi-threading (which I wouldn't suggest with VB6). If you are going to use .NET I would hope there would be some documention regarding the matter with that that could help you.

Like I said, I don't KNOW any of this to be true, but it would be my approach...

Boumxyz2
October 4th, 2001, 12:20 PM
There are some considerations when programming for multi-processor systems. First of all if you don't use multi-threading then your program will be run on 1 cpu only UNLESS the OS (which I doubt) can separate your 1 thread in more than 1 thread...

Multi-processing involve multi-threading because of many reasons.. The main reason is if you have only 1 thread then that means you have only 1 next instruction which means there's no way for the second processor to know where to branch itself to continue execution. This is easily explanable because the Next adress to branch is in the Program counter of the Other CPU...

So Multi-processing require multi-threading ( well at least I think )..

I might be wrong but that's what common sense tells me.

Nicolas