• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Multithreading on Multiprocessor

 
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I am trying to run a multithreaded program on an SGI Origin 2000 running IRIX 6.5. The program does not appear to be utilizing multiple processors. Other programs show parallel execution, so it appesars that I have the system configured properly. Here is the code that starts the threads:
/**
*/
public void initiate() {
Iterator procs = processor_map.values().iterator();
LocalOptProcessor curr_proc = null;
int i = 0;
while ( procs.hasNext() ) {
curr_proc = (LocalOptProcessor)procs.next();
Thread th = new Thread(curr_proc, "Proc"+i);
th.start();
threads[i] = th;
i++;
}
}
If anyone can offer any suggetions as to why this does not work, I would greatly appreciate it. Thanks.
...Mike
 
Ranch Hand
Posts: 111
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please tell first what's "processor_map" and "LocalOptProcessor ". How do you implement them??
 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey,
It works now. I did the following.
 
reply
    Bookmark Topic Watch Topic
  • New Topic