launch a program in one core


I need to launch a program in one core, how I can do it ?


Does this link answer your request ? : … inity.html

If you can’t rebuild the process to run, use the “on” command : … 1_4_5_15_4

I think you can also control this using the Adaptive Partitioning scheduler. That may be more than you want to deal with.

Hi nico04,

I used this code to test my programm in first core and second core

unsigned char u8_cpu_run_mask2 =2 ; ThreadCtl(_NTO_TCTL_RUNMASK, (void *) &u8_cpu_run_mask2);

the time of execution is not so much different, so I’m wondering how I can be sure that my programm was running in the core that I want.

I finaly find how to chek with QNX System profiler, with the timeline I noticed that the programm switch between the CPU 1 and 2, it don’t work in the same core.

The run mask has to be a 32 bits unsigned int, not 8 bits unsigned char.

Not only is the mask 32-bits, but read the docs carefully. This is what works - no ampersand.

unsigned cpu_run_mask = 2 ;
ThreadCtl( _NTO_TCTL_RUNMASK, (void *)cpu_run_mask );