From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16843 invoked by alias); 25 Apr 2012 20:11:17 -0000 Received: (qmail 16775 invoked by uid 22791); 25 Apr 2012 20:10:58 -0000 X-SWARE-Spam-Status: No, hits=-3.6 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from localhost (HELO sourceware.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 25 Apr 2012 20:10:48 +0000 From: "carlos_odonell at mentor dot com" To: glibc-bugs@sources.redhat.com Subject: [Bug libc/11787] Program with large TLS segment fails aio_write Date: Wed, 25 Apr 2012 20:11:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: libc X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: carlos_odonell at mentor dot com X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: carlos_odonell at mentor dot com X-Bugzilla-Target-Milestone: 2.16 X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 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: 2012-04/txt/msg00341.txt.bz2 http://sourceware.org/bugzilla/show_bug.cgi?id=11787 --- Comment #31 from Carlos O'Donell 2012-04-25 20:09:56 UTC --- (In reply to comment #30) > Perhaps I should round it up to the next page size after doing the increment. > In #25 Paul suggested I do the roundup for the increment before adding. > > Or perhaps the safest is to do the roundup of the TLS size and after the add. You need to have a reason for doing the rounding, otherwise you are wasting space. What use and what alignment is required by that use should guide your decision. The size is going to be aligned up to __static_tls_align_m1 in the next statement which is the larger of the stack alignment or the maximum alignment for any given TLS slot (slot minimum alignment is generally 16 bytes). If you are going to use the extra space for stack then you're fine, the alignment in the next line has ensured that you get the right size given the alignment restrictions. -- Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.