[{"id":3679302,"web_url":"http://patchwork.ozlabs.org/comment/3679302/","msgid":"<aeXpUaZLnmRN1wbk@arm.com>","list_archive_url":null,"date":"2026-04-20T08:52:33","subject":"Re: [PATCH 2/2] malloc: introduce ifuncs for malloc functions","submitter":{"id":88214,"url":"http://patchwork.ozlabs.org/api/people/88214/","name":"Yury Khrustalev","email":"yury.khrustalev@arm.com"},"content":"Thanks for the comments, I'll wait a bit for more feedback and then send\nv2 with the fixes.\n\nOn Fri, Apr 17, 2026 at 04:37:43PM -0400, DJ Delorie wrote:\n> \n> Yury Khrustalev <yury.khrustalev@arm.com> writes:\n> > Introduce ifuncs and resolvers for functions pertinent to the\n> > malloc interface.\n> >\n> > In order to do this, we first rename all core implementations by\n> > adding the '_core' suffix. These functions are supposed to be strictly\n> \n> Not wanting to bikeshed, but don't we have a history of using _generic\n> for this purpose?  Or is it your intention that all specific variants\n> will always call the \"core\" variants (vs replacing them), and thus a\n> different suffix is warranted?\n\nI'm happy to change the suffix here, however it's not just a \"generic\"\nimplementation. It represents \"core\" functionality of Glibc's malloc.\nA generic (i.e. default-for-all-targets-that-don't-have-their-own-way)\nimplementation just happens to be the same as the \"core\" one, and some\ntargets may choose to use the \"core\" functions as part of their own\nimplementation.\n\nSo, yes, like you say, I think a different suffix should be used here.\n\n> ... \n> \n> > diff i--git a/malloc/malloc.c b/malloc/malloc.c\n> > index 57b58382b1..215feeebb0 100644\n> > --- a/malloc/malloc.c\n> > +++ b/malloc/malloc.c\n> > @@ -216,8 +216,6 @@\n> >  #include <assert.h>\n> >  #include <intprops.h>\n> >  \n> > -#include <shlib-compat.h>\n> \n> SHLIB_COMPAT is still used though, in the !HAVE_IFUNC case.\n\nTrue, I'll fix this in v2.\n\n> ...\n>\n> > -void     __libc_free(void*);\n> > -libc_hidden_proto (__libc_free)\n> > +void __libc_free_core (void *);\n> > +libc_hidden_proto (__libc_free_core)\n> \n> Arbitrary whitespace changes, but new way is better.  Ok.\n\nYeah, I thought I'd fix code style while I'm at it.\n\n> ...\n>\n> > -void*  __libc_valloc(size_t);\n> > -\n> > +void *__libc_valloc_core (size_t);\n> > +libc_hidden_proto (__libc_valloc_core)\n> \n> Ok.\n> \n> Did we check that the pusblished (non-hidden) symbol list is the same\n> before and after?\n\nIf I understand this bit correctly, there are tests that check public\nsymbols, and I've hit a few failures while working on this patch and\nfixed them.\n\nAlso, the public symbols related to valloc() are done via aliases that\ndidn't change. Strictly speaking, we only need libc_hidden_{def,proto}\nhere to avoid PLT-based call when local call is enough.\n\n> ...\n>\n> > @@ -3142,7 +3143,7 @@ tcache_double_free_verify (tcache_entry *e)\n> >       or user data that happens to match the key.  Since we are not sure,\n> >       clear the key and retry freeing it.  */\n> >    e->key = 0;\n> > -  __libc_free (e);\n> > +  __libc_free_core (e);\n> >  }\n> \n> This is only called from within __libc_free_core itself anyway, and only\n> for the same block, so any ifunc wrapper would have already had its\n> chance at this chunk.  Thus, not calling the ifunc wrapper again seems\n> correct to me.\n\nIs this \"OK\" or \"Not OK\"? :)\n\nThis is the fragile part of any abstractions around malloc (ifunc-based or\notherwise). It is important that whenever an internal function needs to\nused __libc_foo() it uses __libc_foo_core(). If it uses a non-_core symbol,\nthe returned result may not be suitable for subsequent use of it internally.\n\nNon-_core functions return and accept user-pointers which are different from\ninternal pointers that are used by the _core function. Unfortunately, at\nthis stage there is no semantic way to differentiate those, and this part\nrequires further refactoring in malloc.\n\nOff-topic, but I think that all internal _core functions should operate on\nsomething like\n\n  struct internal_ptr_t {\n      void *ptr;\n  }\n\ninstead of 'void *'. But I digress. The non-_core functions should not be\nused in malloc.c. Perhaps, we need some grep-based test here.\n\n> ...\n>\n> >    /* realloc of null is supposed to be same as malloc */\n> >    if (oldmem == NULL)\n> > -    return __libc_malloc (bytes);\n> > +    return __libc_malloc_core (bytes);\n> \n> Ok.  We continue to assume that any wrapper will have its chance at the\n> interface between internal stuff and the user's program.\n> \n> I wonder, though... we current do tagging operations inside malloc\n> internals, like splitting chunks.  How will the ifunc interface handle\n> these?\n\nThat's left for the next patch series, stay tuned! Core parts of malloc\nshould not be aware of any tagging or whatnot. I'm working on it now.\n\nHaving ifuncs is essential step to facilitate this work.\n\n> ...\n>\n> > diff --git a/sysdeps/aarch64/malloc-ifuncs.c b/sysdeps/aarch64/malloc-ifuncs.c\n> \n> ...\n> \n> > +#if IS_IN (libc)\n> \n> Is there ever a case where we're not in libc?\n\nI think not, but I might be missing something here. FWIW, the 'malloc' and\n'__malloc' (now gone) aliases were only declared under this macro, so I\nthink the same should be done for ifunc resolvers that now back these\naliases.\n\n> \n> > +#include <malloc/malloc-internal.h>\n> > +#include <malloc-ifuncs.h>\n> > +\n> > +/* AArch64-specific resolvers for malloc ifuncs.  */\n> > +\n> > +IFUNC_PROTO (__libc_malloc);\n> > +IFUNC_RESOLVER (__libc_malloc, arg0, arg1)\n> \n> It would be nice if there were some hint as to what these arguments are,\n> or are used for.  Ifuncs are complicated enough without obfuscating this\n> information.\n\nThat's why I kept them as part of macro arguments. Perhaps, we should make\nit even more explicit. I'll think about it. Maybe at least argument types\nshould be here too. As for the names, I think they have to be pretty generic.\n\n> ...\n> \n> > diff --git a/sysdeps/generic/malloc-ifuncs.c b/sysdeps/generic/malloc-ifuncs.c\n>\n> ...\n>\n> > +\n> > +# if HAVE_IFUNC\n> > +\n> > +/* These resolvers are used by default unless overridden by a target.\n> > +   The target-specific resolvers must respect this logic if the default\n> > +   resolvers replicating it where appropriate.\n> \n> Grammar?  \"if..where\" sounds like something is missing.\n\nShould be: of the default resolvers, replicating it where appropriate.\nWill fix.\n\n> \n> > +   Any aliases for mallo API functions must be defined here as well\n> \n> typo \"mallo\"\n\nWill fix.\n\nCheers,\nYury","headers":{"Return-Path":"<libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org>","X-Original-To":["incoming@patchwork.ozlabs.org","libc-alpha@sourceware.org"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","libc-alpha@sourceware.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256\n header.s=selector1 header.b=Zwnd1Fp2;\n\tdkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com\n header.a=rsa-sha256 header.s=selector1 header.b=Zwnd1Fp2;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org\n (client-ip=38.145.34.32; helo=vm01.sourceware.org;\n envelope-from=libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org;\n receiver=patchwork.ozlabs.org)","sourceware.org;\n\tdkim=pass (1024-bit key,\n unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256\n header.s=selector1 header.b=Zwnd1Fp2;\n\tdkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com\n header.a=rsa-sha256 header.s=selector1 header.b=Zwnd1Fp2","sourceware.org;\n dmarc=pass (p=none dis=none) header.from=arm.com","sourceware.org; spf=pass smtp.mailfrom=arm.com","server2.sourceware.org;\n arc=pass smtp.remote-ip=2a01:111:f403:c201::6"],"Received":["from vm01.sourceware.org (vm01.sourceware.org [38.145.34.32])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4fzfRn60yZz1yD4\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 20 Apr 2026 18:54:13 +1000 (AEST)","from vm01.sourceware.org (localhost [127.0.0.1])\n\tby sourceware.org (Postfix) with ESMTP id B5C1D4A98F09\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 20 Apr 2026 08:54:11 +0000 (GMT)","from AM0PR02CU008.outbound.protection.outlook.com\n (mail-westeuropeazlp170130006.outbound.protection.outlook.com\n [IPv6:2a01:111:f403:c201::6])\n by sourceware.org (Postfix) with ESMTPS id B10024A98F00\n for <libc-alpha@sourceware.org>; Mon, 20 Apr 2026 08:53:47 +0000 (GMT)","from DU2PR04CA0303.eurprd04.prod.outlook.com (2603:10a6:10:2b5::8)\n by AM8PR08MB5603.eurprd08.prod.outlook.com (2603:10a6:20b:1d4::11) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9818.25; Mon, 20 Apr\n 2026 08:53:42 +0000","from DU6PEPF00009525.eurprd02.prod.outlook.com\n (2603:10a6:10:2b5:cafe::2b) by DU2PR04CA0303.outlook.office365.com\n (2603:10a6:10:2b5::8) with Microsoft SMTP Server (version=TLS1_3,\n cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48 via Frontend Transport; Mon,\n 20 Apr 2026 08:53:42 +0000","from outbound-uk1.az.dlp.m.darktrace.com (4.158.2.129) by\n DU6PEPF00009525.mail.protection.outlook.com (10.167.8.6) with Microsoft SMTP\n Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48 via\n Frontend Transport; Mon, 20 Apr 2026 08:53:42 +0000","from CWLP265CA0413.GBRP265.PROD.OUTLOOK.COM (2603:10a6:400:1b6::19)\n by AS8PR08MB10026.eurprd08.prod.outlook.com (2603:10a6:20b:632::15)\n with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9818.25; Mon, 20 Apr\n 2026 08:52:35 +0000","from AM1PEPF000252DC.eurprd07.prod.outlook.com\n (2603:10a6:400:1b6:cafe::ed) by CWLP265CA0413.outlook.office365.com\n (2603:10a6:400:1b6::19) with Microsoft SMTP Server (version=TLS1_3,\n cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48 via Frontend Transport; Mon,\n 20 Apr 2026 08:52:35 +0000","from nebula.arm.com (172.205.89.229) by\n AM1PEPF000252DC.mail.protection.outlook.com (10.167.16.54) with Microsoft\n SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.20.9791.48 via Frontend Transport; Mon, 20 Apr 2026 08:52:35 +0000","from AZ-NEU-EX03.Arm.com (10.240.25.137) by AZ-NEU-EX04.Arm.com\n (10.240.25.138) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Mon, 20 Apr\n 2026 08:52:34 +0000","from arm.com (10.1.33.20) by mail.arm.com (10.240.25.137) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29 via Frontend\n Transport; Mon, 20 Apr 2026 08:52:34 +0000"],"DKIM-Filter":["OpenDKIM Filter v2.11.0 sourceware.org B5C1D4A98F09","OpenDKIM Filter v2.11.0 sourceware.org B10024A98F00"],"DMARC-Filter":"OpenDMARC Filter v1.4.2 sourceware.org B10024A98F00","ARC-Filter":"OpenARC Filter v1.0.0 sourceware.org B10024A98F00","ARC-Seal":["i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1776675227; cv=pass;\n b=kfnmpV7X2j3Omg0bWKPZk/3EgLBTcEA8r83e/LkMJEqPzNxkoH+mPR/MMH/nc0OyKp9dNHwSmGpXpKX61WcbEoM9Y0RIPfLtHy3c2kr1RBC0KyiZmgTBwB3ec2J5rznLOwUe0oFwU0g7d7/6YMogYD8vn4h7WorwglSsA8fFsXY=","i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass;\n b=RpOhMtAWAYG/C5iwrgCBm/qWnmG9PsTzSTLFVJOok6br0FRqFgY1h5i0WWccILJcBQLqiTukDOCALTtRP1/izYyAaEAhdHv1V7gGFfjZiog3VDfhJSl+6QOXtEbQbYvpDgRGon4pVLmpN85Imx6PeO9M/lnlwtFgc8KwpTweh+rbdLw0ALTkH5ClXmUY73Zjcg3PdPmrWVjeVxr+3EGnThj6SWwJCm/PBYZa5+u0unRwjFKN3SJ0ivD1HDqALXa5Ru61HTvfh3x8kUkR/pNuPBeUsetcuz8TfiT/amjSfG6Ap8wyDEUZVFzAzJWrw33bQckO3h6ZzR8grUIrdOYHjg==","i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none;\n b=eLsCbhF6O7+d/Nuj4Cr/s6cjl2OAGKHopb+up42KuJYia2p17s1cBIpcTIGkXV4VKYtJheDpVDA3FhL2e3d6nW6UjmRu36CSP8kfaxSAlKZBWqGtTUw4pd/2UK+j8J8IhLz2/yh6/XWNWT256MW97fXzycmKT0NydF55NjnX2vKhMA6kowucjDdNbACQ5NndxiwAyLOuiGxHypltnTh6aJ51x+qhU7mrjqEmopRhjamIoqxBLEzltM4cZmUweEZxHyMY8hF+ScUM574vafZZ3SYbuzac3gPvtRzRMMD5+0HtlszNc/poZ3mFVClzKJ9fTHLkqtHeAiToA+m6BacWdQ=="],"ARC-Message-Signature":["i=3; a=rsa-sha256; d=sourceware.org; s=key;\n t=1776675227; c=relaxed/simple;\n bh=VIvXe7yf3SCAvk6Jd+KH7Q11eaBXj/L7Rl2A0rDpX+A=;\n h=DKIM-Signature:DKIM-Signature:Date:From:To:Subject:Message-ID:\n MIME-Version;\n b=wyzGPco2y0J++qVX07iN+vZzOxeFyaty/34dsfaiMTeQ15jR7uX/oh/NTWTdvFmF1w+SaHo1iHkc1/Y2bzw8LRTIg+b5OfocyZwWovDPoZ9ETIh92xtBLnOd20jKXGfVmHfus4ovP9M5oIogfcVs7qov0StYuX8FQrMdMVcx1yM=","i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector10001;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=ybO4u8NUAK4pPvM+XALX0tyyOrU2stvuwV2dxENPgYk=;\n b=NLYolRisTRjBoxdfquFbARLLSvWoOpQfA+V0ryknqvu/VS2t34ypf6vxvvVnFCsVPN/vtNSM23u1xQF49PsIQ+5IlEW5qkPCPTBKDUibqXyavWRVh6v30edaGRiovSfxCd4DSGBfFtFsqQfKAQBcqxXqDeWfUDtUZgTQahMZQhOB9bhkGJNEGA2QeBAHltWMkGq595d/GIf+QaVnGFoX84ldx2w1Cnjx+B5jk3HH1Zk91i2F6eexfqIx9pwWQwlPtxu1+NJZ3eKD2hygbq/C9kN0XMzy2kuKeo2RnCtRJ/AYiZhjDNpxxPHc34QVvrGp7dZ2DFLVkp8e7CQfioULHw==","i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector10001;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=ybO4u8NUAK4pPvM+XALX0tyyOrU2stvuwV2dxENPgYk=;\n b=RyY0MYv7b/KGyfFTd3g8XCDlBtmoazldQY5Mu+Tb2g9IfsOHnu4As9hDl7RqA++NK6vfD7B+uCPUvwjLajEE5L4KtaGYik+Uv9XfTEud90uj1M9YxQclf8OtCmShnM4MEr9sC2XuemaRVbERMx8EZXPd8+StUC+ntWKZNKYIq7y7GZanSml/XanqRAtyoveMMf8gtX9g0byU5i3spmVYLWq+JR+BVH2E5n+4C4NM9URiXgdwV7djPdKyiZeI7tmPgAhKzGIjxLN4MPkXbLjSs69xzYYHFs0RADVKAeWB336KwusO/hNDZHFC8n/g41u+3I7CnOHdx3CSn0xY58Yi3A=="],"ARC-Authentication-Results":["i=3; server2.sourceware.org","i=2; mx.microsoft.com 1; spf=pass (sender ip is\n 4.158.2.129) smtp.rcpttodomain=redhat.com smtp.mailfrom=arm.com; dmarc=pass\n (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass\n (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1\n spf=[1,1,smtp.mailfrom=arm.com] dmarc=[1,1,header.from=arm.com])","i=1; mx.microsoft.com 1; spf=pass (sender ip is\n 172.205.89.229) smtp.rcpttodomain=redhat.com smtp.mailfrom=arm.com;\n dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com;\n dkim=none (message not signed); arc=none (0)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=ybO4u8NUAK4pPvM+XALX0tyyOrU2stvuwV2dxENPgYk=;\n b=Zwnd1Fp2jpFZqiRl2RmxBsZ97OXbqUVnWpsq/38k1sLy4G+jEC2gA43j/suiEHDHdQQ0KQWA7vRg4bLT4u5nRfcz8pQuJDlJZQkmCUGyrUZjuQRrZll3OyP+DgkBOid7/23MphdG5OFZfRlEcHRksRI/J6cosPE58hL6K1oumGg=","v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=ybO4u8NUAK4pPvM+XALX0tyyOrU2stvuwV2dxENPgYk=;\n b=Zwnd1Fp2jpFZqiRl2RmxBsZ97OXbqUVnWpsq/38k1sLy4G+jEC2gA43j/suiEHDHdQQ0KQWA7vRg4bLT4u5nRfcz8pQuJDlJZQkmCUGyrUZjuQRrZll3OyP+DgkBOid7/23MphdG5OFZfRlEcHRksRI/J6cosPE58hL6K1oumGg="],"X-MS-Exchange-Authentication-Results":["spf=pass (sender IP is 4.158.2.129)\n smtp.mailfrom=arm.com; dkim=pass (signature was verified)\n header.d=arm.com;dmarc=pass action=none header.from=arm.com;","spf=pass (sender IP is 172.205.89.229)\n smtp.mailfrom=arm.com; dkim=none (message not signed)\n header.d=none;dmarc=pass action=none header.from=arm.com;"],"Received-SPF":["Pass (protection.outlook.com: domain of arm.com designates\n 4.158.2.129 as permitted sender) receiver=protection.outlook.com;\n client-ip=4.158.2.129; helo=outbound-uk1.az.dlp.m.darktrace.com; pr=C","Pass (protection.outlook.com: domain of arm.com designates\n 172.205.89.229 as permitted sender) receiver=protection.outlook.com;\n client-ip=172.205.89.229; helo=nebula.arm.com; pr=C"],"Date":"Mon, 20 Apr 2026 09:52:33 +0100","From":"Yury Khrustalev <yury.khrustalev@arm.com>","To":"DJ Delorie <dj@redhat.com>","CC":"<libc-alpha@sourceware.org>","Subject":"Re: [PATCH 2/2] malloc: introduce ifuncs for malloc functions","Message-ID":"<aeXpUaZLnmRN1wbk@arm.com>","References":"<20260416092751.11653-3-yury.khrustalev@arm.com>\n <xntst9492g.fsf@greed.delorie.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Disposition":"inline","In-Reply-To":"<xntst9492g.fsf@greed.delorie.com>","X-EOPAttributedMessage":"1","X-MS-TrafficTypeDiagnostic":"\n AM1PEPF000252DC:EE_|AS8PR08MB10026:EE_|DU6PEPF00009525:EE_|AM8PR08MB5603:EE_","X-MS-Office365-Filtering-Correlation-Id":"ea0250f4-030f-46e6-3320-08de9eba52bf","x-checkrecipientrouted":"true","NoDisclaimer":"true","X-MS-Exchange-SenderADCheck":"1","X-MS-Exchange-AntiSpam-Relay":"0","X-Microsoft-Antispam-Untrusted":"BCL:0;\n ARA:13230040|1800799024|30052699003|36860700016|376014|82310400026|56012099003|18002099003|22082099003;","X-Microsoft-Antispam-Message-Info-Original":"\n UqfgGXKgtWjAdlUjPY91/DqW0BhoIOJBK/QEzghR5MFzbUNIOAFx+7RZh8ramKQmW97RhlP8XQ7fVioHNB72su/N4ZzeMHeL7onnL+l6KmZmFGbCfZm5oaSN2a6kgsQQFevGEMj8xPJf3hOg8ZG9fr72bz6rBZ/fYW/89AUYK8/Sik/vCRjTIsvAFuZUHnHCOFT8KQf3wXvZb6VyJyu6BX9LHR/UxGo2paiYNpCPqF1HiG8+Eg+bY9nu6qSAeu0utZdJHyZpJOhbtsVwfPsueWWLKMeFoooIlnnyFOeARneGkmCGBL5P6qaBK0P2pI9TDKkC0npz+whYMlVXedeIjCrW45vyTYTohDC+iYpuDTCMp4yTpGAckV1XyYAht2ViDMWiVJyy7xJIrHAA5INuChUDNPLLeMlxqkkY/vpCw7aH4zeKOBSiqd2X0rujBllJZfF8UXuCt/jCR7iBlX+LLBsgp6XH446WJzABvqPqZnFtjiUZeJVRYQNsST7syjghAJYORJF7trMdwTSZcAhQZws77lfC7ouJkexWJQL0Hp2TbUXUfV1u60Rg23dxKiPwrvtAEP8IByhjqXe/LQVuhX93xK7zGN2p6quS3x14G5r88ChKaiBQHk2JAjKeuGjMSe8Lvs3hvdFZg2X3M+uFir9iQu1xwKrz/DW+R9NJUZQjFrfjkdqlBKm47S2UTs75IjE+/KcJGGZf6MW0pVzJIqhWIyjpnFlyQjqtmG/ZaqBvy3Jd82Ul8ur/U0/ORX8PglGEMBSO43hst3Ukll/77A==","X-Forefront-Antispam-Report-Untrusted":"CIP:172.205.89.229; CTRY:IE; LANG:en;\n SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent;\n CAT:NONE;\n SFS:(13230040)(1800799024)(30052699003)(36860700016)(376014)(82310400026)(56012099003)(18002099003)(22082099003);\n DIR:OUT; SFP:1101;","X-Exchange-RoutingPolicyChecked":"\n A6WPqXhQT8ULXXL+wAAT+0f0Dv6VZNxkGgHWGPjCJ6o5XaY/Swkg++zyNMRQ8Xqttd58/tLYnnmWveFXpaImw0MQ4NOMt/IFjPYvcpT+jps/ME0yU2Tt2YAJ8wfpeyEA2dYw5WTQRF1u3BlXryppStxysQDIzgnNxT94ingWwPRYoKefJ0aP+gyB6IJUvk4e2ouWJD0IiFnPE3PGSSB2Uy3Fvx7oAvxA4GPiksHSiCdiiB6pWGB9z/6e1+LI9nde35/+0CLvuHCrv9+5LjF1JMap1gs5IPTJZ7FBpK2gjdL2pDu9OV3SICCg22Hk3KGlS4n0byPpyjuUOAZczB3Jgg==","X-MS-Exchange-Transport-CrossTenantHeadersStamped":["AS8PR08MB10026","AM8PR08MB5603"],"X-MS-Exchange-Transport-CrossTenantHeadersStripped":"\n DU6PEPF00009525.eurprd02.prod.outlook.com","X-MS-PublicTrafficType":"Email","X-MS-Office365-Filtering-Correlation-Id-Prvs":"\n 989b3994-bbf0-4126-9bfd-08de9eba2b08","X-Microsoft-Antispam":"BCL:0;\n ARA:13230040|1800799024|376014|36860700016|82310400026|14060799003|35042699022|56012099003|18002099003|22082099003;","X-Microsoft-Antispam-Message-Info":"\n vEMuC1d3qzA97InUxueqFfFkQz4B9MeljMRPyT42hxgATrD8xl8skgpXFD+eXY/ui1x/nLafjaj2MxHvjWzGCju0jENFxpu0fRyotsJsrtOuSNjJhUwNzn3lvPKztJ5k3ckI2a5xBTkj0F18F+uatfqLVhC4EpU1cE4qx2k8K/Dvki3JcrIGM5FFOjR5AOF9bwNgyeJtT3dqPdXq+lRrIoRYf7RuoN6xC1gi6oVrGRPBr/JWmHBOtEv9onIKlgdmAskE4mjWuidwm9mcz9VvU64a6xKhm+cKYbmxidF/fHWTDRNZb99Ra0O7bV+zBrNMkxpL3Nd8AMmXD+K3gYFNiNjJlYaUJw2UwSXq10odvjeDdyTj8YCrSHboU+T8IGkO4G8Ky/O80icmaYn09IrJW81PK1dS33Q1g60r+Juf5Ac+yiFZDy1agZgqbbGzvYOX1KSmm/89lEo37xLUOF9E087nUyXop13SV/SXYcOzQRXEpftpot/NGfcWYwSJw8gdlfTjCxBKMAfZRQphDvSJItryn46/4iTi6m1GcbZF/gNExyEgEjlwxBBgB95DvXBhfoqF0mK+67PEYYDMKaRZ6825a0cTGHqT+6oaMtmLecioH0a59TEIQk3vDeg2Ktia/SuCjgkdetmhP8qy3kNj+ptH+A4Yf//o6jVDBNQ+3/BRh83Sye7Rin0a8qdM2U4gly0u+W8Y+/MESumW8gbVj5nBw+x9vj+lkqocy5RoQOOvoJTcure2pc/tWUo5zy6SFZz+77t9C6oTqTA/qVL+WQ==","X-Forefront-Antispam-Report":"CIP:4.158.2.129; CTRY:GB; LANG:en; SCL:1; SRV:;\n IPV:NLI; SFV:NSPM; H:outbound-uk1.az.dlp.m.darktrace.com;\n PTR:InfoDomainNonexistent; CAT:NONE;\n SFS:(13230040)(1800799024)(376014)(36860700016)(82310400026)(14060799003)(35042699022)(56012099003)(18002099003)(22082099003);\n DIR:OUT; SFP:1101;","X-MS-Exchange-AntiSpam-MessageData-ChunkCount":"1","X-MS-Exchange-AntiSpam-MessageData-0":"\n GtvT0QUjPTvNmUMl4Hjy5zk76Yehyr8cpennn2EjwU+ActG9ihlNpJFHVQ7lygWCXXGwozOktOJHLhlj83E7YNnAhPots7e4ccUWgHZEbuKb8oxy54uxtBNVtWOlub4Jgb0Iust6fuhGlSbfgB8TKbu11CACYxKK0DZbT1TJIieBIDTWao1CEtj83lXmYgJFuyKgPgvSP+iuH2YyKjXdORVgxUI5vSYg2uiF8fhbVaaWxOBIMfhtMnXr2rsLH7ZixL15c/RCH5r8/kQISa6ZAO36REElTo3KWZI+AWL97EDHycmtrAAUEEf3v+QTg1YrZr3WLuj8ZDGNXnk+0Ir8JwsGh4isWtUSSp5R6XcJBKU/4PTLSLbpcudZ8R7tkHBHR+WOC1ciTWjDecs2dv3VDO/rJ5qX9tBIL/edtaPb0xveC/Al00HEcETtqOpYYwsf","X-OriginatorOrg":"arm.com","X-MS-Exchange-CrossTenant-OriginalArrivalTime":"20 Apr 2026 08:53:42.2074 (UTC)","X-MS-Exchange-CrossTenant-Network-Message-Id":"\n ea0250f4-030f-46e6-3320-08de9eba52bf","X-MS-Exchange-CrossTenant-Id":"f34e5979-57d9-4aaa-ad4d-b122a662184d","X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp":"\n TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[4.158.2.129];\n Helo=[outbound-uk1.az.dlp.m.darktrace.com]","X-MS-Exchange-CrossTenant-AuthSource":"\n DU6PEPF00009525.eurprd02.prod.outlook.com","X-MS-Exchange-CrossTenant-AuthAs":"Anonymous","X-MS-Exchange-CrossTenant-FromEntityHeader":"HybridOnPrem","X-BeenThere":"libc-alpha@sourceware.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"Libc-alpha mailing list <libc-alpha.sourceware.org>","List-Unsubscribe":"<https://sourceware.org/mailman/options/libc-alpha>,\n <mailto:libc-alpha-request@sourceware.org?subject=unsubscribe>","List-Archive":"<https://sourceware.org/pipermail/libc-alpha/>","List-Post":"<mailto:libc-alpha@sourceware.org>","List-Help":"<mailto:libc-alpha-request@sourceware.org?subject=help>","List-Subscribe":"<https://sourceware.org/mailman/listinfo/libc-alpha>,\n <mailto:libc-alpha-request@sourceware.org?subject=subscribe>","Errors-To":"libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org"}},{"id":3679743,"web_url":"http://patchwork.ozlabs.org/comment/3679743/","msgid":"<aec3VhIwZSVZmZU8@arm.com>","list_archive_url":null,"date":"2026-04-21T08:37:42","subject":"Re: [PATCH 2/2] malloc: introduce ifuncs for malloc functions","submitter":{"id":88214,"url":"http://patchwork.ozlabs.org/api/people/88214/","name":"Yury Khrustalev","email":"yury.khrustalev@arm.com"},"content":"On Mon, Apr 20, 2026 at 12:06:03PM -0400, DJ Delorie wrote:\n> Yury Khrustalev <yury.khrustalev@arm.com> writes:\n>\n> ...\n>\n> > This is the fragile part of any abstractions around malloc\n> > (ifunc-based or otherwise).\n> \n> Yeah, that's why I put my thoughts in writing, in case they were faulty.\n> \n> > Off-topic, but I think that all internal _core functions should operate on\n> > something like\n> \n> In practice, most operate on a CHUNK* (mchunkptr) but we don't have a\n> special type for pointers to the user data part.\n\nYeah, and CHUNK* is not distinguishable from any other raw pointer from\nthe C language point of view. If it was like this:\n\ntypedef struct {\n  struct malloc_chunk *chunk;\n} mchunkptr;\n\nthen chunk pointer would be a different type and it would be not easy to\naccidentally mess things up.\n\nPart of the reason why current memtag implementation in malloc is broken\nis because user and chunk pointers got mixed up.\n\n> >> I wonder, though... we current do tagging operations inside malloc\n> >> internals, like splitting chunks.  How will the ifunc interface handle\n> >> these?\n> >\n> > That's left for the next patch series, stay tuned! Core parts of malloc\n> > should not be aware of any tagging or whatnot. I'm working on it now.\n> \n> I will find it interesting how you do that, because we intentionally\n> change the tagging when we do that to avoid certain types of attack\n> vectors.\n\nI have a draft patch, but it depends on this patch series. I'll post it\nas soon as we have this settled and merged.\n\nThe threat model that we are trying to address with memory tagging in\nmalloc will have to evolve over time as we need to look after\nperformance as well. At this stage we need to make it right functionally\nfirst so we have functional reference point for making changes to harden\nor optimise the implementation.\n\n> >> It would be nice if there were some hint as to what these arguments are,\n> >> or are used for.  Ifuncs are complicated enough without obfuscating this\n> >> information.\n> >\n> > That's why I kept them as part of macro arguments. Perhaps, we should make\n> > it even more explicit. I'll think about it. Maybe at least argument types\n> > should be here too. As for the names, I think they have to be pretty generic.\n> \n> Sorry, I meant the names should give a hint as to what the arguments\n> *are*, or a comment that says \"these will be passed the following\n> data...\".\n\nYes, I got this I think. I've posted v2 where I changed this bit. The\ngeneric versions of resolvers will have to have no arguments, as this is\nhow ifunc resolvers are supposed to be. Target-specific ones may have\nargs as per respective ABIs (e.g. in aarch64 we have 2 uint64_t).\n\n> Just saying \"arg0\" and \"argv[]\" tells the reader nothing about what\n> those values *mean* or where they come from.\n\nI agree. Since it's target dependent, I will add brief description and\nthe link to the document that explains the arguments in details.\n\nCheers,\nYury","headers":{"Return-Path":"<libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org>","X-Original-To":["incoming@patchwork.ozlabs.org","libc-alpha@sourceware.org"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","libc-alpha@sourceware.org"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (1024-bit key;\n unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256\n header.s=selector1 header.b=QNnX0cwY;\n\tdkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com\n header.a=rsa-sha256 header.s=selector1 header.b=QNnX0cwY;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org\n (client-ip=2620:52:6:3111::32; helo=vm01.sourceware.org;\n envelope-from=libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org;\n receiver=patchwork.ozlabs.org)","sourceware.org;\n\tdkim=pass (1024-bit key,\n unprotected) header.d=arm.com header.i=@arm.com header.a=rsa-sha256\n header.s=selector1 header.b=QNnX0cwY;\n\tdkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com\n header.a=rsa-sha256 header.s=selector1 header.b=QNnX0cwY","sourceware.org;\n dmarc=pass (p=none dis=none) header.from=arm.com","sourceware.org; spf=pass smtp.mailfrom=arm.com","server2.sourceware.org;\n arc=pass smtp.remote-ip=40.107.159.7"],"Received":["from vm01.sourceware.org (vm01.sourceware.org\n [IPv6:2620:52:6:3111::32])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g0G4b2ZXrz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 21 Apr 2026 18:39:43 +1000 (AEST)","from vm01.sourceware.org (localhost [127.0.0.1])\n\tby sourceware.org (Postfix) with ESMTP id 5126D4B9DB44\n\tfor <incoming@patchwork.ozlabs.org>; Tue, 21 Apr 2026 08:39:41 +0000 (GMT)","from OSPPR02CU001.outbound.protection.outlook.com\n (mail-norwayeastazon11013007.outbound.protection.outlook.com [40.107.159.7])\n by sourceware.org (Postfix) with ESMTPS id 0DA874BA2E09\n for <libc-alpha@sourceware.org>; Tue, 21 Apr 2026 08:39:03 +0000 (GMT)","from CWLP123CA0256.GBRP123.PROD.OUTLOOK.COM (2603:10a6:400:19e::16)\n by DB8PR08MB5532.eurprd08.prod.outlook.com (2603:10a6:10:f8::8) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9818.33; Tue, 21 Apr\n 2026 08:38:55 +0000","from AMS0EPF0000019C.eurprd05.prod.outlook.com\n (2603:10a6:400:19e:cafe::df) by CWLP123CA0256.outlook.office365.com\n (2603:10a6:400:19e::16) with Microsoft SMTP Server (version=TLS1_3,\n cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48 via Frontend Transport; Tue,\n 21 Apr 2026 08:38:55 +0000","from outbound-uk1.az.dlp.m.darktrace.com (4.158.2.129) by\n AMS0EPF0000019C.mail.protection.outlook.com (10.167.16.248) with Microsoft\n SMTP Server (version=TLS1_3, cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48\n via Frontend Transport; Tue, 21 Apr 2026 08:38:55 +0000","from DU7P191CA0013.EURP191.PROD.OUTLOOK.COM (2603:10a6:10:54e::17)\n by VI1PR08MB9983.eurprd08.prod.outlook.com (2603:10a6:800:1c8::12) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.9818.32; Tue, 21 Apr\n 2026 08:37:45 +0000","from DU6PEPF00009529.eurprd02.prod.outlook.com\n (2603:10a6:10:54e:cafe::c7) by DU7P191CA0013.outlook.office365.com\n (2603:10a6:10:54e::17) with Microsoft SMTP Server (version=TLS1_3,\n cipher=TLS_AES_256_GCM_SHA384) id 15.20.9791.48 via Frontend Transport; Tue,\n 21 Apr 2026 08:37:44 +0000","from nebula.arm.com (172.205.89.229) by\n DU6PEPF00009529.mail.protection.outlook.com (10.167.8.10) with Microsoft SMTP\n Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id\n 15.20.9791.48 via Frontend Transport; Tue, 21 Apr 2026 08:37:44 +0000","from AZ-NEU-EXJ02.Arm.com (10.240.25.139) by AZ-NEU-EX03.Arm.com\n (10.240.25.137) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Tue, 21 Apr\n 2026 08:37:44 +0000","from AZ-NEU-EX04.Arm.com (10.240.25.138) by AZ-NEU-EXJ02.Arm.com\n (10.240.25.139) with Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29; Tue, 21 Apr\n 2026 08:37:44 +0000","from arm.com (10.1.25.51) by mail.arm.com (10.240.25.138) with\n Microsoft SMTP Server (version=TLS1_2,\n cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.2562.29 via Frontend\n Transport; Tue, 21 Apr 2026 08:37:44 +0000"],"DKIM-Filter":["OpenDKIM Filter v2.11.0 sourceware.org 5126D4B9DB44","OpenDKIM Filter v2.11.0 sourceware.org 0DA874BA2E09"],"DMARC-Filter":"OpenDMARC Filter v1.4.2 sourceware.org 0DA874BA2E09","ARC-Filter":"OpenARC Filter v1.0.0 sourceware.org 0DA874BA2E09","ARC-Seal":["i=3; a=rsa-sha256; d=sourceware.org; s=key; t=1776760743; cv=pass;\n b=h3Fj3y4MGNezooRkDbfs1BhR6EjEigJyiDPhC4YhwASrXoGivJ6h0aLPorHsbDtHRxHp9lGob0cugt07RHf6KkJdJOeEflWgDg6tklG2RrR4qmLKni0dM3MBwFQNJ6H9SlMH9NVH8xqUVx64GZP35DslTRGbwV5PCvQnDI+SYRI=","i=2; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=pass;\n b=Ag7uJQwS8cdWwbuTvVbnyYdCqBXFuV7RVlvOl6SUZoD/nZMNl3RsFFL0N11ieH3VcUH46diN/M5KUmFhTpbcxtQNMb2KMN967d7fuD/zYJQ56uBOQ0vhSD81QA2vGELMc9SvYpVEqV/tIb9osfIcIJHhs3nFNIgWfTErjfB89dvrbWOIAivD2frZgp1DJWc/vXP1DShvUMmEgLdOq0EksvWjiJu3dbgxXNtaZggHcP6+pnx+xEIAPtq3E5itOqW7/xCbhiN0w6rR7bgo1oowXlIQ8qQcEBgKLYebVAHPzE9LTYIBuYKr4r20LivEZM3VU5Jd12z06Dr4i58SUP5T0Q==","i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none;\n b=itK5nk0F7bwFERI+AZkIxXTULI7JAnc6f+1nxYAuc8Um2fCmc2XtHh66cWsfiRrFOJqOG4dKwgWweBvi9RsGgpJV5AaPziWgV+PWAIluzcZgP5XUmW3/pFYQ9IdXqLbOI9ykrRnk4r+VW98eusro7i7CQpqBMxOLD22aDfjHNd8TgNBOHUI/1lx4XLYsbCqkvg+NkbYpAQXqM6mjdYI63Mmhp06Y09OrSSEl5dQOVcMXMjlOQpHhLBtAuFFQPwXTUOHlilhVijFkIYoVeWWZgNfQn4jnW51jpSq1fWy/Sidzbj3GPkJbz3pZV7W9eyz7lY5w9/1dNcqVbN73gkq/DQ=="],"ARC-Message-Signature":["i=3; a=rsa-sha256; d=sourceware.org; s=key;\n t=1776760743; c=relaxed/simple;\n bh=PDQ6WhovjgOx2k7D2yrlkX5yRUuOB+xS0NAudgv33hE=;\n h=DKIM-Signature:DKIM-Signature:Date:From:To:Subject:Message-ID:\n MIME-Version;\n b=uRflxr/lqiqcrVPZB6Aew8Bd6ljRMr9Qrhr/PXtftO/Si5NMR7xHCKzawbaGqFaamBAn36ADCGIQuqq8YKQj3qYjKeYv86QYXwzq/ozmkr3Ls618OywLSgOxcmTtHTIyhiXq7pZ4VIfo35BYXmQAW1xOLdzqVZ6NS0N7xrYOSC0=","i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector10001;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=Gq48wau7fca9twqUajfoUNk4wGQpDyhaIiiSSACkJjM=;\n b=nw2pWXTknu89AtMO1z1gn9D9pZekFARX5BZLn/APrKmqe76L5GE3DZHj5nFvV0XCZCq8rcUYeHzS+8zEUeDNR3N79YxIJnx1ruQCPrd1rD+KUtIOaOGpemuychsGNLXf/86E1/JCxQgDUHBrkky4ove9vnn36LHwVJMmHxuwS22DV6j/do8u0brmid8hgy30iMCjPGd3FnTcdnijOy00sFzuWvyfH+bfjW9hHc/N02aWMzPzNt5m+hr+9t8lbGJR5bnb+TTKAIQLHRr1AeC+spMT5XoGaDtHboNahDQxjkxQgW5L8e8Y/nJQdET9KCmp17Y7M4G9CbY84IfhliEmdw==","i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com;\n s=arcselector10001;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1;\n bh=Gq48wau7fca9twqUajfoUNk4wGQpDyhaIiiSSACkJjM=;\n b=qmkcBYEd5g56hpDBMKhbRlWiNF9WK/vyxQYqlixTCOs/61uLM+TCoOmdOLOndHgaajVeceNWq3TVke2gMDq4RR1N61gZ1oGsND4TdjLCdtLcsKpyVAm+Fc/EwF2yCoSGwy8aN1R4Y6vKrFCDoPKtc0GcOwEFEey1jFT076/IIS1Q0eDd7TNvuBmiiWm2kAy+A+BmV0cSBNUGLBfZ5odVkWJHm4YEbQ9/S1zaIX42AQ3iaqRJeHg8pRABMXN/H9Bt/HLglhZnqXDTQeTcSZRt+xuTXy5+udKceaf3jMum0WNbeucgj5FRJbcS+7OhCQDKnKF1+7N98xfCoNuTfIPriw=="],"ARC-Authentication-Results":["i=3; server2.sourceware.org","i=2; mx.microsoft.com 1; spf=pass (sender ip is\n 4.158.2.129) smtp.rcpttodomain=redhat.com smtp.mailfrom=arm.com; dmarc=pass\n (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass\n (signature was verified) header.d=arm.com; arc=pass (0 oda=1 ltdi=1\n spf=[1,1,smtp.mailfrom=arm.com] dmarc=[1,1,header.from=arm.com])","i=1; mx.microsoft.com 1; spf=pass (sender ip is\n 172.205.89.229) smtp.rcpttodomain=redhat.com smtp.mailfrom=arm.com;\n dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com;\n dkim=none (message not signed); arc=none (0)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=Gq48wau7fca9twqUajfoUNk4wGQpDyhaIiiSSACkJjM=;\n b=QNnX0cwYfDpAPgZ+dz6lt3aNm8awn9e/h7u/K8+hR/ebNhF+fdfaaARNbHG5S4nOPbRXTQCfbcpjeNHZZx2uvPGyoiMjmS/xkpsp72oJOklzd+F5WgCBacbnBKtWgueXascT94LtSrGHk/mdlH37Ebprt6VR6nPBt8aEE5kimTU=","v=1; a=rsa-sha256; c=relaxed/relaxed; d=arm.com; s=selector1;\n h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck;\n bh=Gq48wau7fca9twqUajfoUNk4wGQpDyhaIiiSSACkJjM=;\n b=QNnX0cwYfDpAPgZ+dz6lt3aNm8awn9e/h7u/K8+hR/ebNhF+fdfaaARNbHG5S4nOPbRXTQCfbcpjeNHZZx2uvPGyoiMjmS/xkpsp72oJOklzd+F5WgCBacbnBKtWgueXascT94LtSrGHk/mdlH37Ebprt6VR6nPBt8aEE5kimTU="],"X-MS-Exchange-Authentication-Results":["spf=pass (sender IP is 4.158.2.129)\n smtp.mailfrom=arm.com; dkim=pass (signature was verified)\n header.d=arm.com;dmarc=pass action=none header.from=arm.com;","spf=pass (sender IP is 172.205.89.229)\n smtp.mailfrom=arm.com; dkim=none (message not signed)\n header.d=none;dmarc=pass action=none header.from=arm.com;"],"Received-SPF":["Pass (protection.outlook.com: domain of arm.com designates\n 4.158.2.129 as permitted sender) receiver=protection.outlook.com;\n client-ip=4.158.2.129; helo=outbound-uk1.az.dlp.m.darktrace.com; pr=C","Pass (protection.outlook.com: domain of arm.com designates\n 172.205.89.229 as permitted sender) receiver=protection.outlook.com;\n client-ip=172.205.89.229; helo=nebula.arm.com; pr=C"],"Date":"Tue, 21 Apr 2026 09:37:42 +0100","From":"Yury Khrustalev <yury.khrustalev@arm.com>","To":"DJ Delorie <dj@redhat.com>","CC":"<libc-alpha@sourceware.org>","Subject":"Re: [PATCH 2/2] malloc: introduce ifuncs for malloc functions","Message-ID":"<aec3VhIwZSVZmZU8@arm.com>","References":"<aeXpUaZLnmRN1wbk@arm.com>\n <xno6jd4nx0.fsf@greed.delorie.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Disposition":"inline","In-Reply-To":"<xno6jd4nx0.fsf@greed.delorie.com>","X-EOPAttributedMessage":"1","X-MS-TrafficTypeDiagnostic":"\n DU6PEPF00009529:EE_|VI1PR08MB9983:EE_|AMS0EPF0000019C:EE_|DB8PR08MB5532:EE_","X-MS-Office365-Filtering-Correlation-Id":"5661248e-3290-4918-dbcd-08de9f816cb7","x-checkrecipientrouted":"true","NoDisclaimer":"true","X-MS-Exchange-SenderADCheck":"1","X-MS-Exchange-AntiSpam-Relay":"0","X-Microsoft-Antispam-Untrusted":"BCL:0;\n ARA:13230040|82310400026|36860700016|376014|1800799024|56012099003|22082099003|18002099003;","X-Microsoft-Antispam-Message-Info-Original":"\n EvGSPwUJN+NfHUleED5HIuNhq2Zrjzf1eDrwGdnfXT7rzcKuz0DpITEmDh37CtYfk3ZDZLn6KePdL2gKPMuN+USbRQg+anZFNBJP+NPuXTg0m/WxPFMhc1rt8rqg5enPre8Zt6oPu+JST2NmqdCvrqZlDVt6J4DmG/H48t2+VA9gunnrPey+9BMduPq8/f1AOqEYkASAeSAty2EL+jloFPDo9TNU2exoenYZfyprCMQKMwMO43uooqq+gKETj5hS+oS8pZcN2pnbHxZV9ORh/uQtW2yhKBCJXDZll5Ge15NdGt8c4bNKqTIQ4/ioZ+NNqgxAKasetqbM9i4wuVzbqYqUp7xyhskJ7HB1N1tKRcmWjsZK3cKyaI8M7ivMi1tfK6Sm4/Ns+puNz/ddfAFS8MMXYW6CT5qG8a0IYfwY229iaP5ew5Lr0AYJonUjFcz1d4rT9d8OcBH3ifCp3df/tkww5B1jIQA1aAW8BzY0Fj8i/y0O6T8cawVVJirJKJ9EAoAoUNGWDFc1iOMUsus6PqEkW2tYPq+IKebSaNlJC2SjR/+ZFjKc2yed4710ZkXGJIY1u+kdKuZesM1KQ4IHAHGet1AvayT4hxNwbYys/lML8cm28tZFJiDZ136jqK3QW1muojweMkJA28jjsiEnDUYi0EHCtWag9OyO5Ua2usgaELqkk6E+97lQQbdp6e1wKAbseybJMAnvkrALEFHRfAv2pmGBqWoAyHe/i196lmMTWsbLrwfGV4ESH2pxiUpsPNYz4rPwnMInv/DTV1FrJg==","X-Forefront-Antispam-Report-Untrusted":"CIP:172.205.89.229; CTRY:IE; LANG:en;\n SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:nebula.arm.com; PTR:InfoDomainNonexistent;\n CAT:NONE;\n SFS:(13230040)(82310400026)(36860700016)(376014)(1800799024)(56012099003)(22082099003)(18002099003);\n DIR:OUT; SFP:1101;","X-Exchange-RoutingPolicyChecked":"\n L/OQN3XhmQXinGBwn9UK4+AzNsil58DF+0k08WtgCCI3mpAQ9t/z0Ks+7yGABXAAlNsXA6COx3OJNY44KJmEVYucCeb39sP9GsHQgMZMIVOgT+HirzqrP2toXQuN3nQ9X4BXmSmMmBEs4dDkcsBuwqrJT6582GSxggNjwnMUG0S11D9oSP5ulNyLoit/rj7Xx+sBpk6R+0bh9xVMvLCwsKFGPFHzZ+WNSjyhgF8fpow0TiE0Sm2pGoceGdemWJqx1q212TLWr8A1e/h7NSUUv/vXjBpvw+cNuRtCR/ykVqzAlS5jT7tAmcw7FNBeyFZULpu6aL8VGMcVFNFeckdJYQ==","X-MS-Exchange-Transport-CrossTenantHeadersStamped":["VI1PR08MB9983","DB8PR08MB5532"],"X-MS-Exchange-Transport-CrossTenantHeadersStripped":"\n AMS0EPF0000019C.eurprd05.prod.outlook.com","X-MS-PublicTrafficType":"Email","X-MS-Office365-Filtering-Correlation-Id-Prvs":"\n 4cb3cdbd-0170-42ab-e278-08de9f814292","X-Microsoft-Antispam":"BCL:0;\n ARA:13230040|82310400026|36860700016|14060799003|376014|35042699022|1800799024|56012099003|18002099003|22082099003;","X-Microsoft-Antispam-Message-Info":"\n Xu4KK8iRYgNakH4rmxrukbd+F/VDf+ZXAQusxSY7f5g4rqH5RjsLBsw2h1ew/3AfBZT4h+Iv+VqjKA8deujKGkWy+FbwQscxn1cPHacqqa6d583wbalmLmJL6hNsZJU7MRRv2PyjrXG89lDIJo1CWCEj3NNXu/54zaI2NFUItuqliR/fNs6is2BD9AnW+BT4lDHYz0iFBikyaP89noM37hmcTL2ir6k3pYHlgtKGV+xMBlm2zYuo9pkUedllF5dP/OfoOQns3pXi2bcwYbJtjAeHAqfNqME4/C6L659U/dOSPFTIpmCq1M+HIFg8bu/z+S/WJmRLGesAagtQGzGIU0ji+KqaJluFZM/LubNSDgzosbqj4bwd2TpUT3MLLfts/uX6cqCGLp56bvkM4Jni7F7k5D49aiuPwuccvrB2XvGvmaeWmQoSNj/hQBbu4sHyOQHmq+dD13tcMscOS/UcVsHqtnoNkdWFT64C+6X0h9e6+jevECNbSlUlpOaFyA5E6geVRGWjpvS5dUkuvhd35H7/zwlW9O4vyt1C3YM6zrGpinswhPrMfIueqPtv/D1uT+C67mBGh6I4OzLQKTnvZxjeJm2pxkEhzWP0JgCQuuaFNqdyKgx+DoLrpwrvFUq+oSWgJ13N0bXZQCYxrj5ka8JJ+Yw1MGtJLo0n9SQVzU59Szt6G1S8ABez1I37uKg1QTnxjA84I5UMFtJe4whN0M95Sn3XqzUOZkBtLHouW37a5+0ULE6GnTZr3XF3+W9XC5GB4UiYvXFe15ia5zTQ3w==","X-Forefront-Antispam-Report":"CIP:4.158.2.129; CTRY:GB; LANG:en; SCL:1; SRV:;\n IPV:NLI; SFV:NSPM; H:outbound-uk1.az.dlp.m.darktrace.com;\n PTR:InfoDomainNonexistent; CAT:NONE;\n SFS:(13230040)(82310400026)(36860700016)(14060799003)(376014)(35042699022)(1800799024)(56012099003)(18002099003)(22082099003);\n DIR:OUT; SFP:1101;","X-MS-Exchange-AntiSpam-MessageData-ChunkCount":"1","X-MS-Exchange-AntiSpam-MessageData-0":"\n VKS8NsdsxK45Rm2YZpjbITI2bVNKqgJiOqxHhWZ9YUYKAbp4IYGvfAFY7s4U9kPPQNd8/YR7qi7W0nR9XLdhmaWz8uqoZjy0/hy1m2Zi+QDqbAEvaNW3pKP6dA38Xz8UQH5fminSjH+KNKqwbdTuWlORCbxd9b8y5vvKVVyJunJO0Y3lgVdyfKeyMTdulWSvpHd+g5MuKuudoQlOEMSYOy1w8M+DKP9MdCeCz8EPmwP3oQfQERIvro03XXnftJzlRV8oxE5eDfnfZnoLNGNU77pBhngYc6VwTed1zcg5sGZhK49rLNxbVKkuiQrKxUFQtgOconqFdJWclfgMxKBJv3uUsL6APx3RHqQMlyRCazOkr3XnNgOsJTa+53F55+BOD2d9gcwHMo91/agZnYjyV1q7EGzRJh7mmyRLZ22faxkTN3f0feYmbePEmIGF+N6P","X-OriginatorOrg":"arm.com","X-MS-Exchange-CrossTenant-OriginalArrivalTime":"21 Apr 2026 08:38:55.6282 (UTC)","X-MS-Exchange-CrossTenant-Network-Message-Id":"\n 5661248e-3290-4918-dbcd-08de9f816cb7","X-MS-Exchange-CrossTenant-Id":"f34e5979-57d9-4aaa-ad4d-b122a662184d","X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp":"\n TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d; Ip=[4.158.2.129];\n Helo=[outbound-uk1.az.dlp.m.darktrace.com]","X-MS-Exchange-CrossTenant-AuthSource":"\n AMS0EPF0000019C.eurprd05.prod.outlook.com","X-MS-Exchange-CrossTenant-AuthAs":"Anonymous","X-MS-Exchange-CrossTenant-FromEntityHeader":"HybridOnPrem","X-BeenThere":"libc-alpha@sourceware.org","X-Mailman-Version":"2.1.30","Precedence":"list","List-Id":"Libc-alpha mailing list <libc-alpha.sourceware.org>","List-Unsubscribe":"<https://sourceware.org/mailman/options/libc-alpha>,\n <mailto:libc-alpha-request@sourceware.org?subject=unsubscribe>","List-Archive":"<https://sourceware.org/pipermail/libc-alpha/>","List-Post":"<mailto:libc-alpha@sourceware.org>","List-Help":"<mailto:libc-alpha-request@sourceware.org?subject=help>","List-Subscribe":"<https://sourceware.org/mailman/listinfo/libc-alpha>,\n <mailto:libc-alpha-request@sourceware.org?subject=subscribe>","Errors-To":"libc-alpha-bounces~incoming=patchwork.ozlabs.org@sourceware.org"}}]