Best way to force a process preempt (for troubleshooting)

Matthew Hagerty matthew at mundomateo.com
Fri Mar 18 14:13:17 PST 2005


Greetings,

I'm trying to test for the possibility of interleaved data when two more 
more processes are writing to a pipe and more than PIPE_BUF bytes need 
to be written.  How can I make a situation where this scenario can be 
caused reliably so I can make my test case, then apply my patch and make 
sure the changes worked?  Additionally, in one case the processes are 
created from fork() and in another case they are threads (not sure if 
this makes any difference to the scheduler.)

Any insight would be greatly appreciated.

Thank you,
Matthew



More information about the freebsd-hackers mailing list