You can assign a thread to on CPU only with:
Code:
cpu_set_t cpuset;
CPU_ZERO (&cpuset);
CPU_SET (cpu_id, &cpuset);
sched_setaffinity (syscall (SYS_gettid), sizeof (cpu_set_t), &cpuset);
Where "cpu_id" is between 0 and the nb of cpu you have less 1.
_BUT_ assigning a thread to a given CPU doesn't mean that any other process can run on this CPU, thus it won't be more deterministic. If you really need determinism you have to use something like xenomai...