pthread_attr_setscope fails
Enrique Perez-Terron
enrique.perez-terron@norway.online.no
Thu Aug 26 10:32:00 GMT 2004
On Thu, 2004-08-26 at 10:02, Sebastien Decugis wrote:
> Hi all,
>
> It seems that pthread_attr_setscope(&ta, PTHREAD_SCOPE_PROCESS); fails
> with the error "Operation not supported" whereas
> sysconf(_SC_THREAD_PRIORITY_SCHEDULING); returns 200112 (The Thread
> Execution Scheduling option is supported).
>
> It this a normal behavior?
# cat scope.c
#include <unistd.h>
int main(int argc, char *argv[], char *envp[])
{
long result = sysconf(_SC_THREAD_PRIORITY_SCHEDULING);
if (result == 1)
perror("sysconf");
else
printf("Treadh priority scheduling %d\n",result);
return 0;
}
# gcc -o scope scope.c
# ./scope
sysconf: Success
# uname -s -r -m
Linux 2.6.6-1.435.2.3 i586
# /lib/libc.so.6
GNU C Library stable release version 2.3.3, by Roland McGrath et al.
...
Compiled by GNU CC version 3.3.3 20040412 (Red Hat Linux 3.3.3-7).
Compiled on a Linux 2.4.20 system on 2004-05-11.
Available extensions:
GNU libio by Per Bothner
crypt add-on version 2.1 by Michael Glad and others
linuxthreads-0.10 by Xavier Leroy
The C stubs add-on version 2.1.2.
BIND-8.2.3-T5B
NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk
Glibc-2.0 compatibility add-on by Cristian Gafton
GNU Libidn by Simon Josefsson
libthread_db work sponsored by Alpha Processor Inc
-Enrique
More information about the Libc-alpha
mailing list