Re: Scheduling of fork()ed process

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 1 Aug 2006, Daniel de Angelis Cordeiro wrote:

> I have here a very specific workload that I want to test in Linux
> without the "child-runs-first and in the parent's processor" behaviour.
> I know that this behaviour is very good for general workloads because of
> the cache affinity; but in my specific case I want that a short-lived
> fork()ed process starts to run immediately after the fork(), in the
> other CPU.

Either modify cpuset of the newly created task (which is duplicated from
parent in do_fork() -> copy_process() -> cpuset_fork()), or do it 
completely from userspace (hint: look at clone() syscall, CLONE_STOPPED 
flag (in 2.6 kernel) and sys_sched_setaffinity() syscall).

-- 
JiKos.

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux