From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30572 invoked by alias); 2 Jul 2010 23:02:26 -0000 Received: (qmail 26524 invoked by uid 48); 2 Jul 2010 23:02:13 -0000 Date: Fri, 02 Jul 2010 23:02:00 -0000 From: "ppluzhnikov at google dot com" To: glibc-bugs@sources.redhat.com Message-ID: <20100702230212.11787.ppluzhnikov@google.com> Reply-To: sourceware-bugzilla@sourceware.org Subject: [Bug libc/11787] New: Program with large TLS segment fails aio_write X-Bugzilla-Reason: CC Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org X-SW-Source: 2010-07/txt/msg00003.txt.bz2 This is a continuation of issue 10643. Using test case from issue 10643 (will reattach shortly), built with -DCRASH results in: do_aio_write: Invalid argument do_aio_write: Invalid argument failure: Invalid argument failure: Invalid argument AFAICT, this is happening because size of TLS and TCB is subtracted from the stack size that the application requested (in the test case, aio_write is trying to create a thread with 16K stack, but if user requested a thread with small stack size, pthread_create would have failed just as well). Since glibc is the only library that knows TLS and TCB sizes, shouldn't it *add* these sizes to the user requested size, so the user gets exactly 16K of stack he asked for, and not 16K minus "some value we wouldn't tell you"? -- Summary: Program with large TLS segment fails aio_write Product: glibc Version: 2.12 Status: NEW Severity: normal Priority: P2 Component: libc AssignedTo: drepper at redhat dot com ReportedBy: ppluzhnikov at google dot com CC: glibc-bugs at sources dot redhat dot com GCC build triplet: x86_64-unknown-linux-gnu GCC host triplet: x86_64-unknown-linux-gnu GCC target triplet: x86_64-unknown-linux-gnu http://sourceware.org/bugzilla/show_bug.cgi?id=11787 ------- You are receiving this mail because: ------- You are on the CC list for the bug, or are watching someone who is.