From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from albireo.enyo.de (albireo.enyo.de [37.24.231.21]) by sourceware.org (Postfix) with ESMTPS id 8340F3858D3C for ; Tue, 21 Mar 2023 20:43:24 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 8340F3858D3C Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=deneb.enyo.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=deneb.enyo.de Received: from [172.17.203.2] (port=53567 helo=deneb.enyo.de) by albireo.enyo.de ([172.17.140.2]) with esmtps (TLS1.3:ECDHE_SECP256R1__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) id 1peipH-00AtXW-4D; Tue, 21 Mar 2023 20:43:23 +0000 Received: from fw by deneb.enyo.de with local (Exim 4.96) (envelope-from ) id 1peipH-000VOy-08; Tue, 21 Mar 2023 21:43:23 +0100 From: Florian Weimer To: DJ Delorie Cc: libc-alpha@sourceware.org Subject: Re: [patch v3] aligned_alloc: conform to C17 References: Date: Tue, 21 Mar 2023 21:43:23 +0100 In-Reply-To: (DJ Delorie's message of "Tue, 21 Mar 2023 16:21:42 -0400") Message-ID: <87o7ol3kes.fsf@mid.deneb.enyo.de> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-5.5 required=5.0 tests=BAYES_00,KAM_DMARC_STATUS,KAM_NUMSUBJECT,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: * DJ Delorie: > Florian Weimer writes: >> Perhaps you could use this? > > One other difference that isn't obvious in the patch... > > the weak alias for aligned_alloc is inside a conditional: > > #if IS_IN (libc) > . . . > weak_alias (__libc_aligned_alloc, aligned_alloc) > . . . > #endif > > I don't know what, if anything uses malloc.c without being in glibc, but > if such a thing existed, it would break if aligned_alloc weren't inside > this conditional. > > Or the conditional could be removed? Siddhesh added it for libc_malloc_debug, it has !IS_IN (libc). Surely we want libc_malloc_debug to keep defining aligned_alloc, so this shouldn't be conditional on IS_IN (libc).