Date: Thu, 31 Jan 2008 11:17:42 -0800 From: Julian Elischer <julian@elischer.org> To: FreeBSD Current <current@freebsd.org> Subject: needs a tester with an SMP 7.0 box Message-ID: <47A21ED6.5070303@elischer.org>
next in thread | raw e-mail | index | archive | help
if you have a 7.0 SMP (8 way if possible) box and can stand
a little down time, I'm looking for someone to test the following:
This snippet may freeze the process after a while:
#include <sys/types.h>
#include <unistd.h>
#include <pthread.h>
void *forker (void *arg) {
while (1) {
pid_t pid = fork();
if (pid == 0) {
exit(0);
} else if (pid > 0) {
int status;
waitpid(pid, &status, 0);
} else {
printf("Fork failed\n");
abort();
}
}
}
int main(void) {
int i = 0;
for (i = 0; i < 4; i++) {
pthread_t thr;
pthread_create(&thr, NULL, forker, NULL);
pthread_detach(thr);
}
while(1)
sleep(1000);
}
with the following patch applied:
http://www.freebsd.org/~julian/kse-7.diff
it should not.
can someone with a 7.0 machine please confirm this?
(requires a recompile of libkse and linking with libkse.)
(you could call it something else for the test).
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?47A21ED6.5070303>
