|
From: John R. <jr...@bi...> - 2011-08-11 15:19:38
|
> ==8280== Thread 3: > ==8280== Syscall param read(buf) points to unaddressable byte(s) > ==8280== at 0x40ABF5B: ??? (syscall-template.S:82) > ==8280== by 0x40A496D: start_thread (pthread_create.c:300) > ==8280== by 0x437BA4D: clone (clone.S:130) > ==8280== Address 0x0 is not stack'd, malloc'd or (recently) free'd > ==8280== Thread creation ultimately involves clone(). "man 2 clone" shows that clone() takes at least 4 and up to 7 parameters. Whether each of the last three parameters actually are present depends on flag bits in the third parameter. The behavior is complex and thinly documented. Each of the last three arguments is an address, and 0 (NULL) often means "ignore this address" even if the corresponding flag bit says "the argument is present". The way to track this down is to use strace to determine the actual arguments to clone(), look through the Linux kernel source code to see what the flag bits really mean for each case, then compare with memcheck's code for clone(). Perhaps the valgrind option "--trace-syscalls=yes" will help, too, although that code might already have problems for clone(). File a bug report. Include the output from strace, the complaint from memcheck, the version numbers of memcheck and the OS, and which hardware architecture. -- |