[issue1343] panic: vm_map_entry_link, dup addr map

Alex Hornung (via DragonFly issue tracker) sinknull at crater.dragonflybsd.org
Thu Apr 23 10:40:59 PDT 2009

Alex Hornung <ahornung at gmail.com> added the comment:

new test case I'm using. Remember to compile with -lthread_xu, as it only seems
to affect this lib.

DragonFly issue tracker <bugs at lists.dragonflybsd.org>
_____________________________________________________#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#include <sys/types.h>
#include <dirent.h>
#include <errno.h>
#include <unistd.h>

void* tester(void *arg)
	for(;;) sleep(1);	

void* checker(void *arg)
	printf("Passed barrier!\n");

int main(int argc, char *argv[])
	int i, ret, nthreads;
	pthread_t th;

	if (argc <= 1)
		printf("Need one argument\n");

	nthreads = atoi(argv[1]);
	printf("Trying with %d threads\n", nthreads);	

	printf("Creating checker thread\n");
	pthread_create(&th, NULL, checker, NULL);

	printf("Creating tester threads\n");

	for (i = 0; i < nthreads; i++)
		pthread_create(&th, NULL, tester, NULL);

	return 0;

More information about the Bugs mailing list