This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [Question] ifunc odering in ELF
- From: Szabolcs Nagy <Szabolcs dot Nagy at arm dot com>
- To: Florian Weimer <fweimer at redhat dot com>, Adhemerval Zanella <adhemerval dot zanella at linaro dot org>
- Cc: nd <nd at arm dot com>, "libc-alpha at sourceware dot org" <libc-alpha at sourceware dot org>
- Date: Fri, 20 Sep 2019 16:00:39 +0000
- Subject: Re: [Question] ifunc odering in ELF
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XhQe2TOtkn62D0+RG/XBOQnAGS671JlK1HgoUx7NfWM=; b=M1lfSahhHtu3lefnckywI6fMd7CSXxqmm3ntpV2A8GFMijvgbMJm3g8xuSo3uluBaWCxmSQZlA85BfxTrIdDE/SHvQ3obe7hSO/2Xoxuicg+Tqg+bMEAqU4Y0U5gd6SuT3qttHVlKeM+S6BUiga3lGL74iOPXX2j/I87L0/N8AF2PjWs5N1xvUgI71HTn9nechcaiVLg5wG4djM5lyUfA6/fzDSvYdb63A3keXBu5TLIZ2fOYroMWT8YeI/RALRZHJQAZzqLBWpk/CkVI2QLRBhIGQj7NdqjySxFymToB0mIi3i5wwZI12hKNF2FI9VpSRvj16kKUlJABXwhWAX2Hg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=j8GjCc/BmI/0fowyTEyeThqZCrR26f8Jzy5XOuHvTfVW6hpAmzi38vH+fQaRI9JUCBCAQiHbt7VHwZwThfgktdOk/XVfYAjN7+3PcZNgD2EHdo5E5QDgfSUJWOExEYGRlFxhjSnpK/qwcARcgvthspCc6tkxPdujBSmeCPy4FsCXet+wksIAZfdunA3cK/8g7/75lVrykXwN1jCGPXRK2WRcXcYvSLn0/wh27y/5UbW3re+pTLUP/GrknpGHounVA0mBnzLp/GTPfOYsUhIb7khj5YpIDHgToLA7ryyvaYsXOiGIELDv5yQwT3ADlmkAs8wDcHcafaZIGrUE0SIT/Q==
- Original-authentication-results: spf=none (sender IP is ) smtp.mailfrom=Szabolcs dot Nagy at arm dot com;
- References: <1568314984.28076.65.camel@blackberry.com> <87pnjzy75u.fsf@oldenburg2.str.redhat.com> <66583af6-6049-7f1d-0a31-a77a228cf603@linaro.org> <87v9tnezju.fsf@oldenburg2.str.redhat.com>
On 20/09/2019 16:51, Florian Weimer wrote:
> * Adhemerval Zanella:
>
>> That's was not my impression, I this we should to go this way iff we can't
>> really make IFUNC reordering work on loader. From your initial work on
>> the two-phase IFUNC relocation, which prevents us to move forward?
>
> No one said, “yes, we do need this feature in the loader”.
>
> (Keep in mind that it does not solve all ordering problems, the example
> in this thread would still break.)
if most "reasonable" ordering issues can be fixed, then
i think the ordering should be fixed.
but i seem to remember that for it to work it's not enough
to consider the relocations of a single module, but other
modules have to be considered (in case of copy relocated
function pointers? or extern ifunc code in not yet relocated
modules?).
if relocations have to be processed twice across multiple
modules then i think the complexity is too much (we need to
allocate space for the list of relocs that need reprocessing
etc).