From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx0b-0010f301.pphosted.com (mx0b-0010f301.pphosted.com [148.163.153.244]) by sourceware.org (Postfix) with ESMTPS id 1D6B838537A9 for ; Mon, 11 Apr 2022 20:24:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 1D6B838537A9 Received: from pps.filterd (m0102860.ppops.net [127.0.0.1]) by mx0b-0010f301.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 23BHh3Xu016527; Mon, 11 Apr 2022 15:24:23 -0500 Received: from mx2.mail.rice.edu (mx2.mail.rice.edu [128.42.199.100]) by mx0b-0010f301.pphosted.com (PPS) with ESMTPS id 3fb7h3tgxq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Mon, 11 Apr 2022 15:24:23 -0500 Received: from mx2.mail.rice.edu (localhost [127.0.0.1]) by mx2.mail.rice.edu (Postfix) with ESMTP id 6F205416F37; Mon, 11 Apr 2022 15:24:22 -0500 (CDT) Received: from localhost (localhost [127.0.0.1]) by mx2.mail.rice.edu (Postfix) with ESMTP id 6C785416F34; Mon, 11 Apr 2022 15:24:22 -0500 (CDT) X-Virus-Scanned: by amavis-2.12.1 at mx2.mail.rice.edu, auth channel Received: from mx2.mail.rice.edu ([127.0.0.1]) by localhost (mx2.mail.rice.edu [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id 1cwbhwhe3Cvi; Mon, 11 Apr 2022 15:24:22 -0500 (CDT) Received: from [76.30.110.10] (c-76-30-110-10.hsd1.tx.comcast.net [76.30.110.10]) (using TLSv1.2 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jma14) by mx2.mail.rice.edu (Postfix) with ESMTPSA id D5EFA233DC1; Mon, 11 Apr 2022 15:24:21 -0500 (CDT) Message-ID: Date: Mon, 11 Apr 2022 15:24:21 -0500 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 From: Jonathon Anderson Subject: LD_AUDIT: Not enough space in static TLS block To: Carlos O'Donell , Florian Weimer , Ben Woodard , Adhemerval Zanella , "Legendre, Matthew P." Cc: libc-alpha@sourceware.org, John Mellor-Crummey Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.858,Hydra:6.0.425,FMLib:17.11.64.514 definitions=2022-04-11_08,2022-04-11_01,2022-02-23_01 X-Spam-Status: No, score=-3.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Apr 2022 20:24:31 -0000 Hello all, We (the HPCToolkit team) have encountered another critical LD_AUDIT bug. When LD_AUDIT is specified, the allocation of the static TLS block does not account for the TLS requirements of executable dependencies or of the auditors themselves. If:  - an executable accesses a thread-local variable in a linked library with sufficiently large TLS requirements, or  - an auditor itself uses sufficiently large TLS and optimizes access with `-ftls-model=initial-exec`, then the process or auditor will fail with the error "cannot allocate memory in static TLS block." This is a critical issue for us. We have observed this issue affecting RAJA, a template-based library for efficient parallel computation and widely-used among HPC applications. It would help us greatly if this issue was fixed for 2.36 and backported along with the other LD_AUDIT-related patches. We have added this issue and a minimal reproducer to our document of auditor bugs: https://docs.google.com/document/d/1dVaDBdzySecxQqD6hLLzDrEF18M1UtjDna9gL5BWWI0 -Jonathon