From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from bee.birch.relay.mailchannels.net (bee.birch.relay.mailchannels.net [23.83.209.14]) by sourceware.org (Postfix) with ESMTPS id 855203983804 for ; Fri, 9 Jul 2021 08:13:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 855203983804 X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org Received: from relay.mailchannels.net (localhost [127.0.0.1]) by relay.mailchannels.net (Postfix) with ESMTP id D82FE541C36; Fri, 9 Jul 2021 08:13:22 +0000 (UTC) Received: from pdx1-sub0-mail-a31.g.dreamhost.com (100-96-11-33.trex.outbound.svc.cluster.local [100.96.11.33]) (Authenticated sender: dreamhost) by relay.mailchannels.net (Postfix) with ESMTPA id 304EA541353; Fri, 9 Jul 2021 08:13:22 +0000 (UTC) X-Sender-Id: dreamhost|x-authsender|siddhesh@gotplt.org Received: from pdx1-sub0-mail-a31.g.dreamhost.com (pop.dreamhost.com [64.90.62.162]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384) by 100.96.11.33 (trex/6.3.3); Fri, 09 Jul 2021 08:13:22 +0000 X-MC-Relay: Neutral X-MailChannels-SenderId: dreamhost|x-authsender|siddhesh@gotplt.org X-MailChannels-Auth-Id: dreamhost X-Exultant-Whimsical: 37ca369c6bdb8236_1625818402687_348584603 X-MC-Loop-Signature: 1625818402687:2567940682 X-MC-Ingress-Time: 1625818402687 Received: from pdx1-sub0-mail-a31.g.dreamhost.com (localhost [127.0.0.1]) by pdx1-sub0-mail-a31.g.dreamhost.com (Postfix) with ESMTP id D920B852E0; Fri, 9 Jul 2021 01:13:21 -0700 (PDT) Received: from [192.168.1.137] (unknown [1.186.101.110]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: siddhesh@gotplt.org) by pdx1-sub0-mail-a31.g.dreamhost.com (Postfix) with ESMTPSA id 18C698080F; Fri, 9 Jul 2021 01:13:19 -0700 (PDT) Subject: Re: [PATCH v7 3/8] Move malloc hooks into a compat DSO To: Florian Weimer Cc: libc-alpha@sourceware.org, carlos@redhat.com, dj@redhat.com References: <20210708174325.3243721-1-siddhesh@sourceware.org> <20210708174325.3243721-4-siddhesh@sourceware.org> <87czrrkiyg.fsf@oldenburg.str.redhat.com> X-DH-BACKEND: pdx1-sub0-mail-a31 From: Siddhesh Poyarekar Message-ID: <74c790ec-1a38-9d1a-142a-4edbec064e47@sourceware.org> Date: Fri, 9 Jul 2021 13:43:14 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.10.1 MIME-Version: 1.0 In-Reply-To: <87czrrkiyg.fsf@oldenburg.str.redhat.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3486.1 required=5.0 tests=BAYES_00, JMQ_SPF_NEUTRAL, KAM_DMARC_NONE, KAM_DMARC_STATUS, NICE_REPLY_A, RCVD_IN_BARRACUDACENTRAL, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NEUTRAL, TXREP, URIBL_BLACK autolearn=no 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: Fri, 09 Jul 2021 08:13:26 -0000 On 7/9/21 1:38 PM, Florian Weimer wrote: > * Siddhesh Poyarekar: > >> Remove all malloc hook uses from core malloc functions and move it >> into a new library libc_malloc_debug.so. With this, the hooks now no >> longer have any effect on the core library. >> >> libc_malloc_debug.so is a malloc interposer that needs to be preloaded >> to get hooks functionality back so that the debugging features that >> depend on the hooks, i.e. malloc-check, mcheck and mtrace work again. >> Without the preloaded DSO these debugging features will be nops. >> These features will be ported away from hooks in subsequent patches. >> >> Similarly, legacy applications that need hooks functionality need to >> preload libc_malloc_debug.so. >> >> The symbols exported by libc_malloc_debug.so are maintained at exactly >> the same version as libc.so. >> >> Finally, static binaries will no longer be able to use malloc >> debugging features since they cannot preload the debugging DSO. > > Commit subject could be adjusted because the DSO contains more than just > the hooks. OK, I'll update it to "Introduce malloc debug DSO" > This patch needs to update the shlib-versions file on architectures > which do not use DEFAULT. For example, on ia64-linux-gnu, there is a > malloc/check-abi-libc_malloc_debug failure that looks like this: Thanks, fixed locally. Siddhesh