This is the mail archive of the glibc-bugs@sources.redhat.com mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug nptl/347] New: pthread_create hang after a failure


When trying to create threads with a high priority, as a normal user, the
function pthread_create will return EPERM on the first try then hang in the
second call.

Compiler is gcc 3.4.1

Kernel is 2.6.8.1 smp running on a 2-way i686.

Glibc is a recent CVS with NPTL addon (tried with CVS from 2004-07-26 and
2004-08-23).

Here is the strace output corresponding to the attached sample:
[...skip...]
sched_get_priority_max(SCHED_FIFO)      = 99
sched_get_priority_min(SCHED_FIFO)      = 1
mmap2(NULL, 8392704, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) =
0x40144000
brk(0)                                  = 0x804a000
brk(0x806b000)                          = 0x806b000
mprotect(0x40144000, 4096, PROT_NONE)   = 0
sched_get_priority_min(SCHED_FIFO)      = 1
sched_get_priority_max(SCHED_FIFO)      = 99
clone(child_stack=0x40944b28,
flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID,
parent_tidptr=0x40944bf8, {entry_number:6, base_addr:0x40944bb0, limit:1048575,
seg_32bit:1, contents:0, read_exec_only:0, limit_in_pages:1, seg_not_present:0,
useable:1}, child_tidptr=0x40944bf8) = 17737
sched_setscheduler(0, SCHED_FIFO, { 99 }) = -1 EPERM (Operation not permitted)
tgkill(17736, 0, SIGRTMIN)              = -1 EINVAL (Invalid argument)
sched_get_priority_min(SCHED_FIFO)      = 1
sched_get_priority_max(SCHED_FIFO)      = 99
futex(0x40944d94, FUTEX_WAIT, 2, NULL <unfinished ...>

-- 
           Summary: pthread_create hang after a failure
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: nptl
        AssignedTo: drepper at redhat dot com
        ReportedBy: sebastien dot decugis at ext dot bull dot net
                CC: glibc-bugs at sources dot redhat dot com


http://sources.redhat.com/bugzilla/show_bug.cgi?id=347

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]