From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oa1-x2d.google.com (mail-oa1-x2d.google.com [IPv6:2001:4860:4864:20::2d]) by sourceware.org (Postfix) with ESMTPS id 70D763889E13 for ; Wed, 22 Mar 2023 17:51:38 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 70D763889E13 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-oa1-x2d.google.com with SMTP id 586e51a60fabf-17aeb49429eso19893106fac.6 for ; Wed, 22 Mar 2023 10:51:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679507497; h=content-transfer-encoding:in-reply-to:organization:from:references :to:content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=ynQH3VF7qaKmajg1XFVne+AXwCvrWQdeKfiW3KUrcN0=; b=M8K9e6nwWuh7rLtHU5c/Y0uh1HxrkhLn7t/C/LCpRvhMcLSKEP3d0LadreMFeubDSL 9RNJj5+Y6MoSky2ookbvGWofShXt32HuG/9f4LbteML3ObTEKgisjeLY4+nQwlVkeqPI /y82MRVSfOYSn8/e4koO7gBN4u3sT57HZreUXD/hNmxKBPGfuNy0M687/Os1YLbRrTSp ltnEj1EWO+k9rbw8vuJfk8v6WElLDYr214LV8IF/7qbzOOCeSuYAJl0m+qRbi+GF6Ex5 QgS03JN3c5rJ0JfwZmJe/EBvqmuyKRqZejMKRlkb6+ta3aer27abnUopHO5WAmHep34A /qjQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679507497; h=content-transfer-encoding:in-reply-to:organization:from:references :to:content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=ynQH3VF7qaKmajg1XFVne+AXwCvrWQdeKfiW3KUrcN0=; b=JkFJ+uLa1AWtk5UvxmMmeUh+3S8sCsNsNBgk2VbVIGLPEeC60JBHESXgcRimqdwuBZ V+x2R5z40iI5KH1DfRyTkN+XIfMhPPW+M/RRIqT6xuiGgAuX3T15exVIjeZgGewuu07W slUjUURmJbw+gwxHsjEEaxmD/2bHkd+k91gbKal0gvhAGB4Um9yUpxb42k6ODvio9meU POKgeNyjkNoQENwCwoJy7WFEjqbxGx3+1+2XUHoOB7fM4/SVlHNm8e5r4eGj32DeSn7Q Nwh+dpChz4t0Zri/IR831Wjzyj2bU4D4mnGGqeNaxq1OSOSZ5ADeJJ9AacdL8KbNhlPR yMxg== X-Gm-Message-State: AAQBX9fv6On3Lv8uzH7z6sImyk5bKrvW3K0sYI1D7R/aMSzhHtA2pzmV eJcWSiB9YJfdHYwYEuWxSiFzch8jnYcEB4p6tlsn4Q== X-Google-Smtp-Source: AK7set/jQK+inTVgASdOCLZ50+mwqoUO/TKWOPRPEf2bfILFrpfEfsR6oaKLBn/9BWSsW5lKBgnMFw== X-Received: by 2002:a05:6870:6129:b0:17a:f1a2:c4c7 with SMTP id s41-20020a056870612900b0017af1a2c4c7mr368347oae.42.1679507497176; Wed, 22 Mar 2023 10:51:37 -0700 (PDT) Received: from ?IPV6:2804:1b3:a7c0:c260:7930:b4e8:7389:be1f? ([2804:1b3:a7c0:c260:7930:b4e8:7389:be1f]) by smtp.gmail.com with ESMTPSA id vk10-20020a0568710e4a00b00172426ebe58sm5400908oab.27.2023.03.22.10.51.34 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 22 Mar 2023 10:51:36 -0700 (PDT) Message-ID: <45835a92-55a1-6637-183a-4ecad79d9065@linaro.org> Date: Wed, 22 Mar 2023 14:51:32 -0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH 1/2] elf: Remove glibc.rtld.dynamic_sort tunable Content-Language: en-US To: Siddhesh Poyarekar , libc-alpha@sourceware.org, Florian Weimer References: <20230313190627.2000578-1-adhemerval.zanella@linaro.org> <20230313190627.2000578-2-adhemerval.zanella@linaro.org> From: Adhemerval Zanella Netto Organization: Linaro In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-8.8 required=5.0 tests=BAYES_00,BODY_8BITS,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SCC_10_SHORT_WORD_LINES,SCC_20_SHORT_WORD_LINES,SCC_35_SHORT_WORD_LINES,SCC_5_SHORT_WORD_LINES,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 22/03/23 14:08, Siddhesh Poyarekar wrote: > On 2023-03-13 15:06, Adhemerval Zanella wrote: >> And make the DFS algorithm (added on 2.35) the de-facto implementation= =2E >=20 > Isn't this orthogonal to the proposal to remove --enable-tunables? Yes, the DFS is already the default one. I meant that now there is no wa= y to select the one algorithm. Maybe use the commit messagE: And make the old sort algorithm no longer available. >=20 > Thanks, > Sid >=20 >> --- >> =C2=A0 elf/dl-sort-maps.c=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 | 139 +--------= ------------------- >> =C2=A0 elf/dl-tunables.list=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0=C2=A0 9 -- >> =C2=A0 elf/dso-sort-tests-1.def=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 15 +-- >> =C2=A0 elf/dso-sort-tests-2.def=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 10 +- >> =C2=A0 elf/tst-rtld-list-tunables.exp=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2= =A0=C2=A0 1 - >> =C2=A0 manual/tunables.texi=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 |=C2=A0 13 --- >> =C2=A0 sysdeps/mach/hurd/dl-sysdep.c=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= |=C2=A0=C2=A0 3 - >> =C2=A0 sysdeps/unix/sysv/linux/dl-sysdep.c |=C2=A0=C2=A0 3 - >> =C2=A0 8 files changed, 8 insertions(+), 185 deletions(-) >> >> diff --git a/elf/dl-sort-maps.c b/elf/dl-sort-maps.c >> index 325e96388e..72ca5cec33 100644 >> --- a/elf/dl-sort-maps.c >> +++ b/elf/dl-sort-maps.c >> @@ -20,112 +20,6 @@ >> =C2=A0 #include >> =C2=A0 #include >> =C2=A0 -/* Note: this is the older, "original" sorting algorithm, bein= g used as >> -=C2=A0=C2=A0 default up to 2.35. >> - >> -=C2=A0=C2=A0 Sort array MAPS according to dependencies of the contain= ed objects. >> -=C2=A0=C2=A0 If FOR_FINI is true, this is called for finishing an obj= ect.=C2=A0 */ >> -static void >> -_dl_sort_maps_original (struct link_map **maps, unsigned int nmaps, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 bo= ol force_first, bool for_fini) >> -{ >> -=C2=A0 /* Allows caller to do the common optimization of skipping the= first map, >> -=C2=A0=C2=A0=C2=A0=C2=A0 usually the main binary.=C2=A0 */ >> -=C2=A0 maps +=3D force_first; >> -=C2=A0 nmaps -=3D force_first; >> - >> -=C2=A0 /* A list of one element need not be sorted.=C2=A0 */ >> -=C2=A0 if (nmaps <=3D 1) >> -=C2=A0=C2=A0=C2=A0 return; >> - >> -=C2=A0 unsigned int i =3D 0; >> -=C2=A0 uint16_t seen[nmaps]; >> -=C2=A0 memset (seen, 0, nmaps * sizeof (seen[0])); >> -=C2=A0 while (1) >> -=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Keep track of which object we looke= d at this round.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ++seen[i]; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 struct link_map *thisp =3D maps[i]; >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (__glibc_unlikely (for_fini)) >> -=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Do not handle ld.so in secondary na= mespaces and objects which >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 are not removed.=C2=A0= */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (thisp !=3D thisp->l_real || thisp-= >l_idx =3D=3D -1) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 goto skip; >> -=C2=A0=C2=A0=C2=A0 } >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Find the last object in the list fo= r which the current one is >> -=C2=A0=C2=A0=C2=A0=C2=A0 a dependency and move the current object beh= ind the object >> -=C2=A0=C2=A0=C2=A0=C2=A0 with the dependency.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 unsigned int k =3D nmaps - 1; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 while (k > i) >> -=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 struct link_map **runp =3D maps[k]->l_= initfini; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (runp !=3D NULL) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Look through the depend= encies of the object.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 while (*runp !=3D NULL) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (__glibc_un= likely (*runp++ =3D=3D thisp)) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 move: >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Move the cu= rrent object to the back past the last >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0 object with it as the dependency.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 memmove (&maps= [i], &maps[i + 1], >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 (k - i) * sizeof (maps[0])); >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 maps[k] =3D th= isp; >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (seen[i + 1= ] > nmaps - i) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 ++i; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 goto next_clear; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 uint16_t this_= seen =3D seen[i]; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 memmove (&seen= [i], &seen[i + 1], (k - i) * sizeof (seen[0])); >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 seen[k] =3D th= is_seen; >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 goto next; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (__glibc_unlikely (for_fini && maps= [k]->l_reldeps !=3D NULL)) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 unsigned int m= =3D maps[k]->l_reldeps->act; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 struct link_ma= p **relmaps =3D &maps[k]->l_reldeps->list[0]; >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Look throug= h the relocation dependencies of the object.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 while (m-- > 0= ) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (__glibc_unlikely (relm= aps[m] =3D=3D thisp)) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /*= If a cycle exists with a link time dependency, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0 preserve the latter.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 st= ruct link_map **runp =3D thisp->l_initfini; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if= (runp !=3D NULL) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 while (*runp !=3D NULL) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if= (__glibc_unlikely (*runp++ =3D=3D maps[k])) >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0 goto ignore; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 go= to move; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 ignore:; >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> - >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 --k; >> -=C2=A0=C2=A0=C2=A0 } >> - >> -=C2=A0=C2=A0=C2=A0 skip: >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 if (++i =3D=3D nmaps) >> -=C2=A0=C2=A0=C2=A0 break; >> -=C2=A0=C2=A0=C2=A0 next_clear: >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 memset (&seen[i], 0, (nmaps - i) * siz= eof (seen[0])); >> - >> -=C2=A0=C2=A0=C2=A0 next:; >> -=C2=A0=C2=A0=C2=A0 } >> -} >> - >> -#if !HAVE_TUNABLES >> -/* In this case, just default to the original algorithm.=C2=A0 */ >> -strong_alias (_dl_sort_maps_original, _dl_sort_maps); >> -#else >> - >> =C2=A0 /* We use a recursive function due to its better clarity and ea= se of >> =C2=A0=C2=A0=C2=A0=C2=A0 implementation, as well as faster execution s= peed. We already use >> =C2=A0=C2=A0=C2=A0=C2=A0 alloca() for list allocation during the bread= th-first search of >> @@ -180,9 +74,9 @@ dfs_traversal (struct link_map ***rpo, struct link_= map *map, >> =C2=A0 /* Topologically sort array MAPS according to dependencies of t= he contained >> =C2=A0=C2=A0=C2=A0=C2=A0 objects.=C2=A0 */ >> =C2=A0 -static void >> -_dl_sort_maps_dfs (struct link_map **maps, unsigned int nmaps, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 bool for= ce_first, bool for_fini) >> +void >> +_dl_sort_maps (struct link_map **maps, unsigned int nmaps, bool force= _first, >> +=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 bool for= _fini) >> =C2=A0 { >> =C2=A0=C2=A0=C2=A0 struct link_map *first_map =3D maps[0]; >> =C2=A0=C2=A0=C2=A0 for (int i =3D nmaps - 1; i >=3D 0; i--) >> @@ -289,30 +183,3 @@ _dl_sort_maps_dfs (struct link_map **maps, unsign= ed int nmaps, >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 maps[0] =3D first_map; >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> =C2=A0 } >> - >> -void >> -_dl_sort_maps_init (void) >> -{ >> -=C2=A0 int32_t algorithm =3D TUNABLE_GET (glibc, rtld, dynamic_sort, = int32_t, NULL); >> -=C2=A0 GLRO(dl_dso_sort_algo) =3D algorithm =3D=3D 1 ? dso_sort_algor= ithm_original >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2= =A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 : dso_sort_algo= rithm_dfs; >> -} >> - >> -void >> -_dl_sort_maps (struct link_map **maps, unsigned int nmaps, >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 bool for= ce_first, bool for_fini) >> -{ >> -=C2=A0 /* It can be tempting to use a static function pointer to stor= e and call >> -=C2=A0=C2=A0=C2=A0=C2=A0 the current selected sorting algorithm routi= ne, but experimentation >> -=C2=A0=C2=A0=C2=A0=C2=A0 shows that current processors still do not h= andle indirect branches >> -=C2=A0=C2=A0=C2=A0=C2=A0 that efficiently, plus a static function poi= nter will involve >> -=C2=A0=C2=A0=C2=A0=C2=A0 PTR_MANGLE/DEMANGLE, further impairing perfo= rmance of small, common >> -=C2=A0=C2=A0=C2=A0=C2=A0 input cases. A simple if-case with direct fu= nction calls appears to >> -=C2=A0=C2=A0=C2=A0=C2=A0 be the fastest.=C2=A0 */ >> -=C2=A0 if (__glibc_likely (GLRO(dl_dso_sort_algo) =3D=3D dso_sort_alg= orithm_original)) >> -=C2=A0=C2=A0=C2=A0 _dl_sort_maps_original (maps, nmaps, force_first, = for_fini); >> -=C2=A0 else >> -=C2=A0=C2=A0=C2=A0 _dl_sort_maps_dfs (maps, nmaps, force_first, for_f= ini); >> -} >> - >> -#endif /* HAVE_TUNABLES.=C2=A0 */ >> diff --git a/elf/dl-tunables.list b/elf/dl-tunables.list >> index 695ba7192e..b9fa831000 100644 >> --- a/elf/dl-tunables.list >> +++ b/elf/dl-tunables.list >> @@ -162,15 +162,6 @@ glibc { >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 } >> =C2=A0=C2=A0=C2=A0 } >> =C2=A0 -=C2=A0 rtld { >> -=C2=A0=C2=A0=C2=A0 dynamic_sort { >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 type: INT_32 >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 minval: 1 >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 maxval: 2 >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 default: 2 >> -=C2=A0=C2=A0=C2=A0 } >> -=C2=A0 } >> - >> =C2=A0=C2=A0=C2=A0 gmon { >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 minarcs { >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 type: INT_32 >> diff --git a/elf/dso-sort-tests-1.def b/elf/dso-sort-tests-1.def >> index 4bf9052db1..f5afd003d8 100644 >> --- a/elf/dso-sort-tests-1.def >> +++ b/elf/dso-sort-tests-1.def >> @@ -2,10 +2,6 @@ >> =C2=A0 # This file is to be processed by ../scripts/dso-ordering-test.= py, see usage >> =C2=A0 # in elf/Makefile for how it is executed. >> =C2=A0 -# We test both dynamic loader sorting algorithms >> -tunable_option: glibc.rtld.dynamic_sort=3D1 >> -tunable_option: glibc.rtld.dynamic_sort=3D2 >> - >> =C2=A0 # Sequence of single dependencies with no cycles. >> =C2=A0 tst-dso-ordering1: a->b->c >> =C2=A0 output: c>b>a>{}> @@ -56,18 +52,15 @@ output: b>a>{}> =C2=A0 # relocation(dynamic) dependencies. While this is technically u= nspecified, the >> =C2=A0 # presumed reasonable practical behavior is for the destructor = order to respect >> =C2=A0 # the static DT_NEEDED links (here this means the a->b->c->d or= der). >> -# The older dynamic_sort=3D1 algorithm does not achieve this, while t= he DFS-based >> -# dynamic_sort=3D2 algorithm does, although it is still arguable whet= her going >> -# beyond spec to do this is the right thing to do. >> +# The DFS-based sorting algorithm does it, although it is still argua= ble whether >> +# going beyond spec to do this is the right thing to do. >> =C2=A0 # The below expected outputs are what the two algorithms curren= tly produce >> =C2=A0 # respectively, for regression testing purposes. >> =C2=A0 tst-bz15311: {+a;+e;+f;+g;+d;%d;-d;-g;-f;-e;-a};a->b->c->d;d=3D= >[ba];c=3D>a;b=3D>e=3D>a;c=3D>f=3D>b;d=3D>g=3D>c >> -output(glibc.rtld.dynamic_sort=3D1): {+a[d>c>b>a>];+e[e>];+f[f>];+g[g= >];+d[];%d(b(e(a()))a()g(c(a()f(b(e(a()))))));-d[];-g[];-f[];-e[];-a[> -output(glibc.rtld.dynamic_sort=3D2): {+a[d>c>b>a>];+e[e>];+f[f>];+g[g= >];+d[];%d(b(e(a()))a()g(c(a()f(b(e(a()))))));-d[];-g[];-f[];-e[];-a[> +output: {+a[d>c>b>a>];+e[e>];+f[f>];+g[g>];+d[];%d(b(e(a()))a()g(c(a(= )f(b(e(a()))))));-d[];-g[];-f[];-e[];-a[> =C2=A0 =C2=A0 # Test that even in the presence of dependency loops inv= olving dlopen'ed >> =C2=A0 # object, that object is initialized last (and not unloaded pre= maturely). >> =C2=A0 # Final destructor order is indeterminate due to the cycle. >> =C2=A0 tst-bz28937: {+a;+b;-b;+c;%c};a->a1;a->a2;a2->a;b->b1;c->a1;c=3D= >a1 >> -output(glibc.rtld.dynamic_sort=3D1): {+a[a2>a1>a>];+b[b1>b>];-b[];%c(a1());}> -output(glibc.rtld.dynamic_sort=3D2): {+a[a2>a1>a>];+b[b1>b>];-b[];%c(a1());}> +output: {+a[a2>a1>a>];+b[b1>b>];-b[];%c(a1());}> diff --git a/elf/dso-sort-tests-2.def b/elf/dso-sort-tests-2.def >> index b79e79ecb7..183d311fba 100644 >> --- a/elf/dso-sort-tests-2.def >> +++ b/elf/dso-sort-tests-2.def >> @@ -1,11 +1,4 @@ >> =C2=A0 # Large DSO sorting testcase adapted from Red Hat Bugzilla 1162= 810 >> -# >> -# Note that below we specify different expected outputs between dynam= ic_sort=3D1 >> -# and dynamic_sort=3D2 algorithms, due to circular dependencies in th= e testcase >> -# causing different sorting behavior.=C2=A0 These expected outputs ar= e what the two >> -# algorithms currently produce, and are used for regression compariso= n tests. >> -# They are not "definitively" correct outputs, for circular dependenc= ies >> -# inherently have unspecified behavior. >> =C2=A0 =C2=A0 xtest(tst-redhat-1162810): >> =C2=A0 {}->A101 >> @@ -610,5 +603,4 @@ M30X22 >> =C2=A0 M30X23 >> =C2=A0 M30X24 >> =C2=A0 M30X25 >> -xfail_output(glibc.rtld.dynamic_sort=3D1): >> M30X19>M30X15>M30X16>M30X11>M30X12>M30X17>M30X13>M30X14>M29X20>M30X23>= M30X24>M30X20>M30X18>M29X15>M29X12>M30X22>M30X21>M29X22>M30X25>M29X19>M29= X23>M29X16>M29X24>M29X13>M29X17>M29X18>M28X19>M29X21>M29X25>M29X14>M28X20= >M28X15>M28X16>M28X21>M27X18>M29X11>M28X17>M28X11>M28X22>M27X14>M28X18>M2= 7X15>M28X13>M27X11>M28X23>M27X25>M28X14>M28X25>M27X23>M27X22>M28X24>M27X2= 1>M27X13>M27X19>M27X17>M26X11>M26X23>M26X21>M26X22>M26X20>M26X16>M25X21>M= 17X22>M15X15>M20X14>M20X16>M18X18>M28X12>M27X24>M25X17>M27X20>M26X18>M26X= 17>M27X16>M26X19>M25X18>M26X24>M25X20>M24X17>M23X18>M25X13>M26X13>M17X23>= M16X16>M26X12>M25X12>M26X15>M24X19>M25X23>M25X24>M25X25>M24X20>M25X19>M24= X21>M23X17>M22X21>M24X14>M23X22>M24X24>M22X20>M24X13>M25X11>M24X12>M25X15= >M23X15>M25X16>M24X22>M23X13>M24X18>M23X14>M22X22>M21X20>M24X25>M23X16>M2= 2X25>M21X19>M22X14>M23X11>M22X15>M21X18>M22X19>M21X17>M20X17>M19X17>M21X2= 4>M21X12>M20X22>M19X16>M18X25>M19X21>M19X20>M18X24>M20X12>M19X11>M23X20>M= 22X24>M22X16>M21X21>M25X14>M23X19>M23X24>M20X24>M19X12>M18X15>M17X14>M16X= 18>M14X25>M16X22>M16X20>M17X17>M22X12>M21X11>M20X15>M18X22>M19X24>M19X18>= M18X21>M17X16>M17X18>M16X21>M15X20>M19X22>M18X20>M18X11>M17X19>M16X17>M15= X21>M16X14>M16X13>M15X22>M14X20>M17X25>M16X19>M14X21>M13X24>M12X12>M16X24= >M15X23>M14X16>M16X15>M15X25>M15X11>M15X12>M14X15>M13X14>M14X22>M13X20>M1= 2X13>M11X11>M22X23>M21X15>M21X16>M20X21>M20X20>M18X17>M19X25>M18X23>M21X1= 3>M15X17>M15X18>M18X19>M17X24>M16X12>M17X13>M20X25>M19X23>M15X19>M14X13>M= 13X18>M15X13>M17X12>M16X11>M18X13>M18X12>M14X11>M14X24>M13X19>M15X14>M17X= 20>M20X11>M20X13>M21X14>M15X24>M14X12>M13X22>M14X23>M13X23>M14X19>M17X15>= M16X25>M17X11>M18X14>M19X19>M21X25>M13X12>M13X11>M14X18>M13X13>M12X11>M15= X16>M14X14>M27X12>M17X21>M20X23>M22X13>M21X22>M24X16>M24X15>M26X25>M23X25= >M26X14>M23X12>M22X18>M24X11>M16X23>M19X14>M19X13>M21X23>M22X17>M23X23>M2= 3X21>M25X22>M18X16>M19X15>M20X18>M20X19>M22X11>M24X23>C156>C118>C143>C137= >C147>C106>C168>C113>C163>C155>C105>C146>C187>A150>C139>C180>C164>C193>C1= 57>A191>C158>B188>A159>C184>C121>C154>B171>A105>C131>C104>B104>C161>C111>= B145>C160>B155>A163>C112>C142>B148>C133>B198>A198>A115>C114>B157>A156>C17= 5>B144>A120>C173>B184>A174>C126>B107>A139>C194>B194>A194>C116>B116>C166>B= 160>B110>A110>C128>B128>A128>C179>B162>A154>C186>B187>A179>C124>B181>A101= >C153>B158>A136>C135>C176>A192>B133>A133>C177>B177>A177>C185>C103>B141>A1= 41>C183>A162>C192>C129>B179>C144>B124>B183>C127>B127>A127>B108>A112>B153>= A153>C167>B167>A186>A122>C162>A144>B149>C174>B131>A185>C141>B106>A126>A16= 7>C140>B122>A170>C198>B143>C117>C123>B123>A147>A106>C200>B169>C191>B175>A= 123>B118>A182>C132>B151>A145>A104>A109>C159>C150>B119>A119>A178>B164>B114= >A164>C181>A102>C122>B134>A157>A116>C195>B191>B111>C172>B172>A118>B129>A1= 29>C149>A107>C170>B197>A197>A173>B168>A132>C107>B165>A160>A131>C188>A168>= B109>C178>A189>A148>C119>C190>C120>B166>B176>C108>B135>B139>A103>B178>A16= 9>B132>C125>C138>B163>A111>B170>C110>A165>C151>C169>C199>A138>C182>A135>B= 101>B142>C101>C148>B193>B152>A158>A199>C136>B137>A161>B120>A108>A149>A125= >B113>A184>C171>A134>A175>A124>B150>B161>B102>A146>A187>C130>B192>B200>A2= 00>A142>A183>C102>B105>B156>A176>C165>B147>A137>A196>B190>A190>B125>C134>= C189>B126>B186>A166>B136>B195>A195>B154>B138>B112>B173>A117>B159>B182>A18= 1>A140>C145>B117>A152>A193>C197>B130>A172>A113>A151>B115>A143>B140>B185>B= 103>A121>A180>A130>A171>B199>C196>B146>B180>C115>B174>B121>A188>B196>B189= >C152>C109>A155>A114>M14X17>M13X15>M13X16>M13X17>M12X17>M12X21>M12X25>M12= X14>M13X25>M12X15>M13X21>M12X16>M12X18>M12X19>M12X20>M12X22>M12X23>M12X24= >M11X25>M11X24>M11X23>M11X22>M11X21>M11X20>M11X19>M11X18>M11X17>M11X16>M1= 1X15>M11X14>M11X13>M11X12>{}> -output(glibc.rtld.dynamic_sort=3D2): >> M30X19>M30X15>M30X16>M30X11>M30X12>M30X17>M30X13>M30X14>M29X20>M30X23>= M30X24>M30X20>M30X18>M29X15>M29X12>M30X22>M30X21>M29X22>M30X25>M29X19>M29= X23>M29X16>M29X24>M29X13>M29X17>M29X18>M28X19>M29X21>M29X25>M29X14>M28X20= >M28X15>M28X16>M28X21>M27X18>M29X11>M28X17>M28X11>M28X22>M28X24>M28X23>M2= 7X21>M28X13>M27X20>M27X19>M26X14>M27X25>M28X18>M27X11>M28X25>M27X24>M26X2= 4>M27X15>M27X14>M27X13>M26X23>M27X17>M26X22>M25X13>M28X14>M27X16>M26X19>M= 26X18>M27X23>M27X22>M26X17>M25X18>M26X21>M25X17>M26X20>M26X15>M26X13>M25X= 19>M24X14>M25X23>M26X11>M26X25>M25X16>M25X15>M24X22>M25X21>M25X20>M24X21>= M25X25>M25X24>M24X20>M23X13>M22X15>M25X14>M24X19>M23X17>M24X25>M23X24>M24= X13>M23X15>M24X18>M23X14>M22X11>M24X15>M23X22>M24X11>M23X19>M22X21>M24X24= >M23X21>M22X20>M23X25>M22X19>M21X24>M20X23>M22X22>M25X11>M23X16>M22X18>M2= 3X20>M22X17>M21X21>M21X20>M20X24>M22X14>M22X13>M21X11>M21X17>M22X23>M21X1= 6>M20X25>M19X23>M18X16>M21X22>M20X20>M20X19>M21X13>M20X18>M19X13>M21X18>M= 20X21>M19X24>M18X12>M20X14>M20X13>M22X25>M20X12>M20X15>M19X14>M18X22>M19X= 18>M20X17>M19X17>M19X16>M18X21>M17X20>M19X19>M18X13>M17X11>M18X17>M19X25>= M18X15>M17X25>M18X19>M17X24>M16X19>M15X17>M17X21>M16X24>M18X23>M17X16>M16= X25>M19X15>M18X25>M17X23>M16X23>M15X23>M18X14>M17X14>M16X14>M17X18>M16X13= >M17X22>M16X12>M15X22>M14X16>M17X12>M16X22>M15X12>M16X11>M15X11>M16X15>M1= 5X25>M14X15>M13X14>M15X18>M16X21>M15X16>M14X21>M15X14>M16X20>M15X13>M14X2= 2>M15X20>M14X20>M13X20>M14X11>M15X19>M14X24>M13X19>M14X13>M13X18>M12X13>M= 15X24>M14X23>M13X12>M14X12>M13X11>M12X11>M11X11>M21X12>M20X11>M19X11>M18X= 11>M17X15>M16X18>M14X25>M14X19>M13X24>M13X23>M13X22>M12X12>M22X12>M21X15>= M19X22>M18X20>M16X17>M14X14>M24X12>M23X23>M22X16>M21X14>M20X22>M18X24>M16= X16>M26X12>M24X16>M23X11>M21X23>M19X20>M17X17>M27X12>M26X16>M25X22>M24X17= >M23X18>M21X25>M19X12>M17X19>M15X21>M14X18>M13X13>M23X12>M21X19>M19X21>M1= 7X13>M15X15>M25X12>M24X23>M22X24>M20X16>M18X18>M28X12>A150>C158>B112>A112= >C167>B146>A146>C180>B180>A180>C143>B143>A115>C126>B126>A126>C190>B190>A1= 90>C138>B138>A138>C174>B174>A102>C122>B122>A122>C162>B162>A162>C142>B142>= A142>C102>B102>A174>C176>B176>A176>C115>B115>A143>C172>B172>A172>C187>B18= 7>A187>C130>B130>A130>C118>B118>A118>C184>B184>A184>C171>B171>A171>C168>B= 182>A182>C182>B168>A168>C109>B109>A109>C159>B159>A159>C134>B134>A134>C146= >B167>A167>C140>B140>A140>C163>B163>A163>C112>B158>A158>C164>B164>A164>C1= 31>B131>A131>C188>B188>A188>C199>B199>A199>C114>B114>A114>C106>B106>A106>= C200>B200>A200>C183>B183>A183>C152>B152>A152>C147>B147>A147>C150>B150>A19= 8>C144>B144>A144>C191>B191>A191>C108>B108>A108>C139>B139>A139>C194>B194>A= 194>C166>B166>A166>C120>B120>A120>C123>B123>A123>C132>B132>A132>C107>B107= >A107>C170>B170>A170>C198>B198>A156>C125>B125>A125>C121>B121>A121>C193>B1= 93>A193>C197>B197>A197>C175>B175>A175>C196>B196>A196>C105>B105>A105>C181>= B181>A181>C113>B113>A113>C137>B137>A137>C155>B155>A155>C156>B156>A110>C12= 8>B128>A128>C179>B179>A179>C124>B124>A124>C151>B151>A151>C178>B178>A178>C= 104>B104>A104>C111>B111>A111>C148>B148>A148>C169>B169>A169>C129>B129>A129= >C149>B149>A149>C189>B189>A189>C119>B119>A119>C154>B154>A154>C136>B136>A1= 36>C135>B135>A135>C116>B116>A116>C145>B145>A145>C161>B161>A161>C173>B173>= A173>C157>B157>A157>C195>B195>A195>C186>B186>A186>C160>B160>A160>C153>B15= 3>A153>C117>B117>A117>C165>B165>A165>C101>B101>A101>C103>B103>A103>C192>B= 192>A192>C177>B177>A177>C185>B185>A185>C141>B141>A141>C133>B133>A133>C127= >B127>A127>C110>B110>M14X17>M13X15>M13X16>M13X17>M12X17>M12X21>M12X25>M12= X14>M13X25>M12X15>M13X21>M12X16>M12X18>M12X19>M12X20>M12X22>M12X23>M12X24= >M11X25>M11X24>M11X23>M11X22>M11X21>M11X20>M11X19>M11X18>M11X17>M11X16>M1= 1X15>M11X14>M11X13>M11X12>{}> +output: >> M30X19>M30X15>M30X16>M30X11>M30X12>M30X17>M30X13>M30X14>M29X20>M30X23>= M30X24>M30X20>M30X18>M29X15>M29X12>M30X22>M30X21>M29X22>M30X25>M29X19>M29= X23>M29X16>M29X24>M29X13>M29X17>M29X18>M28X19>M29X21>M29X25>M29X14>M28X20= >M28X15>M28X16>M28X21>M27X18>M29X11>M28X17>M28X11>M28X22>M28X24>M28X23>M2= 7X21>M28X13>M27X20>M27X19>M26X14>M27X25>M28X18>M27X11>M28X25>M27X24>M26X2= 4>M27X15>M27X14>M27X13>M26X23>M27X17>M26X22>M25X13>M28X14>M27X16>M26X19>M= 26X18>M27X23>M27X22>M26X17>M25X18>M26X21>M25X17>M26X20>M26X15>M26X13>M25X= 19>M24X14>M25X23>M26X11>M26X25>M25X16>M25X15>M24X22>M25X21>M25X20>M24X21>= M25X25>M25X24>M24X20>M23X13>M22X15>M25X14>M24X19>M23X17>M24X25>M23X24>M24= X13>M23X15>M24X18>M23X14>M22X11>M24X15>M23X22>M24X11>M23X19>M22X21>M24X24= >M23X21>M22X20>M23X25>M22X19>M21X24>M20X23>M22X22>M25X11>M23X16>M22X18>M2= 3X20>M22X17>M21X21>M21X20>M20X24>M22X14>M22X13>M21X11>M21X17>M22X23>M21X1= 6>M20X25>M19X23>M18X16>M21X22>M20X20>M20X19>M21X13>M20X18>M19X13>M21X18>M= 20X21>M19X24>M18X12>M20X14>M20X13>M22X25>M20X12>M20X15>M19X14>M18X22>M19X= 18>M20X17>M19X17>M19X16>M18X21>M17X20>M19X19>M18X13>M17X11>M18X17>M19X25>= M18X15>M17X25>M18X19>M17X24>M16X19>M15X17>M17X21>M16X24>M18X23>M17X16>M16= X25>M19X15>M18X25>M17X23>M16X23>M15X23>M18X14>M17X14>M16X14>M17X18>M16X13= >M17X22>M16X12>M15X22>M14X16>M17X12>M16X22>M15X12>M16X11>M15X11>M16X15>M1= 5X25>M14X15>M13X14>M15X18>M16X21>M15X16>M14X21>M15X14>M16X20>M15X13>M14X2= 2>M15X20>M14X20>M13X20>M14X11>M15X19>M14X24>M13X19>M14X13>M13X18>M12X13>M= 15X24>M14X23>M13X12>M14X12>M13X11>M12X11>M11X11>M21X12>M20X11>M19X11>M18X= 11>M17X15>M16X18>M14X25>M14X19>M13X24>M13X23>M13X22>M12X12>M22X12>M21X15>= M19X22>M18X20>M16X17>M14X14>M24X12>M23X23>M22X16>M21X14>M20X22>M18X24>M16= X16>M26X12>M24X16>M23X11>M21X23>M19X20>M17X17>M27X12>M26X16>M25X22>M24X17= >M23X18>M21X25>M19X12>M17X19>M15X21>M14X18>M13X13>M23X12>M21X19>M19X21>M1= 7X13>M15X15>M25X12>M24X23>M22X24>M20X16>M18X18>M28X12>A150>C158>B112>A112= >C167>B146>A146>C180>B180>A180>C143>B143>A115>C126>B126>A126>C190>B190>A1= 90>C138>B138>A138>C174>B174>A102>C122>B122>A122>C162>B162>A162>C142>B142>= A142>C102>B102>A174>C176>B176>A176>C115>B115>A143>C172>B172>A172>C187>B18= 7>A187>C130>B130>A130>C118>B118>A118>C184>B184>A184>C171>B171>A171>C168>B= 182>A182>C182>B168>A168>C109>B109>A109>C159>B159>A159>C134>B134>A134>C146= >B167>A167>C140>B140>A140>C163>B163>A163>C112>B158>A158>C164>B164>A164>C1= 31>B131>A131>C188>B188>A188>C199>B199>A199>C114>B114>A114>C106>B106>A106>= C200>B200>A200>C183>B183>A183>C152>B152>A152>C147>B147>A147>C150>B150>A19= 8>C144>B144>A144>C191>B191>A191>C108>B108>A108>C139>B139>A139>C194>B194>A= 194>C166>B166>A166>C120>B120>A120>C123>B123>A123>C132>B132>A132>C107>B107= >A107>C170>B170>A170>C198>B198>A156>C125>B125>A125>C121>B121>A121>C193>B1= 93>A193>C197>B197>A197>C175>B175>A175>C196>B196>A196>C105>B105>A105>C181>= B181>A181>C113>B113>A113>C137>B137>A137>C155>B155>A155>C156>B156>A110>C12= 8>B128>A128>C179>B179>A179>C124>B124>A124>C151>B151>A151>C178>B178>A178>C= 104>B104>A104>C111>B111>A111>C148>B148>A148>C169>B169>A169>C129>B129>A129= >C149>B149>A149>C189>B189>A189>C119>B119>A119>C154>B154>A154>C136>B136>A1= 36>C135>B135>A135>C116>B116>A116>C145>B145>A145>C161>B161>A161>C173>B173>= A173>C157>B157>A157>C195>B195>A195>C186>B186>A186>C160>B160>A160>C153>B15= 3>A153>C117>B117>A117>C165>B165>A165>C101>B101>A101>C103>B103>A103>C192>B= 192>A192>C177>B177>A177>C185>B185>A185>C141>B141>A141>C133>B133>A133>C127= >B127>A127>C110>B110>M14X17>M13X15>M13X16>M13X17>M12X17>M12X21>M12X25>M12= X14>M13X25>M12X15>M13X21>M12X16>M12X18>M12X19>M12X20>M12X22>M12X23>M12X24= >M11X25>M11X24>M11X23>M11X22>M11X21>M11X20>M11X19>M11X18>M11X17>M11X16>M1= 1X15>M11X14>M11X13>M11X12>{}> diff --git a/elf/tst-rtld-list-tunables.exp b/elf/tst-rtld-list-tunabl= es.exp >> index 2233ea9c7c..f70c16ecb8 100644 >> --- a/elf/tst-rtld-list-tunables.exp >> +++ b/elf/tst-rtld-list-tunables.exp >> @@ -11,6 +11,5 @@ glibc.malloc.tcache_max: 0x0 (min: 0x0, max: 0x[f]+)= >> =C2=A0 glibc.malloc.tcache_unsorted_limit: 0x0 (min: 0x0, max: 0x[f]+)= >> =C2=A0 glibc.malloc.top_pad: 0x20000 (min: 0x0, max: 0x[f]+) >> =C2=A0 glibc.malloc.trim_threshold: 0x0 (min: 0x0, max: 0x[f]+) >> -glibc.rtld.dynamic_sort: 2 (min: 1, max: 2) >> =C2=A0 glibc.rtld.nns: 0x4 (min: 0x1, max: 0x10) >> =C2=A0 glibc.rtld.optional_static_tls: 0x200 (min: 0x0, max: 0x[f]+) >> diff --git a/manual/tunables.texi b/manual/tunables.texi >> index 70dd2264c5..ae6959379b 100644 >> --- a/manual/tunables.texi >> +++ b/manual/tunables.texi >> @@ -47,7 +47,6 @@ glibc.elision.enable: 0 (min: 0, max: 1) >> =C2=A0 glibc.malloc.hugetlb: 0x0 (min: 0x0, max: 0xffffffffffffffff) >> =C2=A0 glibc.cpu.x86_rep_movsb_threshold: 0x2000 (min: 0x100, max: 0xf= fffffffffffffff) >> =C2=A0 glibc.malloc.mxfast: 0x0 (min: 0x0, max: 0xffffffffffffffff) >> -glibc.rtld.dynamic_sort: 2 (min: 1, max: 2) >> =C2=A0 glibc.elision.skip_lock_busy: 3 (min: 0, max: 2147483647) >> =C2=A0 glibc.malloc.top_pad: 0x20000 (min: 0x0, max: 0xfffffffffffffff= f) >> =C2=A0 glibc.cpu.x86_rep_stosb_threshold: 0x800 (min: 0x1, max: 0xffff= ffffffffffff) >> @@ -334,18 +333,6 @@ changed once allocated at process startup.=C2=A0 = The default allocation of >> =C2=A0 optional static TLS is 512 bytes and is allocated in every thre= ad. >> =C2=A0 @end deftp >> =C2=A0 -@deftp Tunable glibc.rtld.dynamic_sort >> -Sets the algorithm to use for DSO sorting, valid values are @samp{1} = and >> -@samp{2}.=C2=A0 For value of @samp{1}, an older O(n^3) algorithm is u= sed, which is >> -long time tested, but may have performance issues when dependencies b= etween >> -shared objects contain cycles due to circular dependencies.=C2=A0 Whe= n set to the >> -value of @samp{2}, a different algorithm is used, which implements a >> -topological sort through depth-first search, and does not exhibit the= >> -performance issues of @samp{1}. >> - >> -The default value of this tunable is @samp{2}. >> -@end deftp >> - >> =C2=A0 @node Elision Tunables >> =C2=A0 @section Elision Tunables >> =C2=A0 @cindex elision tunables >> diff --git a/sysdeps/mach/hurd/dl-sysdep.c b/sysdeps/mach/hurd/dl-sysd= ep.c >> index a2115f6edb..cc4e58043f 100644 >> --- a/sysdeps/mach/hurd/dl-sysdep.c >> +++ b/sysdeps/mach/hurd/dl-sysdep.c >> @@ -102,9 +102,6 @@ _dl_sysdep_start (void **start_argptr, >> =C2=A0 =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 __tunables_init (_en= viron); >> =C2=A0 -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 /* Initialize DSO sorting algor= ithm after tunables.=C2=A0 */ >> -=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 _dl_sort_maps_init (); >> - >> =C2=A0 #ifdef DL_SYSDEP_INIT >> =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 DL_SYSDEP_INIT; >> =C2=A0 #endif >> diff --git a/sysdeps/unix/sysv/linux/dl-sysdep.c b/sysdeps/unix/sysv/l= inux/dl-sysdep.c >> index 1b3dd869b5..4eed762754 100644 >> --- a/sysdeps/unix/sysv/linux/dl-sysdep.c >> +++ b/sysdeps/unix/sysv/linux/dl-sysdep.c >> @@ -109,9 +109,6 @@ _dl_sysdep_start (void **start_argptr, >> =C2=A0 =C2=A0=C2=A0=C2=A0 __tunables_init (_environ); >> =C2=A0 -=C2=A0 /* Initialize DSO sorting algorithm after tunables.=C2=A0= */ >> -=C2=A0 _dl_sort_maps_init (); >> - >> =C2=A0=C2=A0=C2=A0 __brk (0);=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0=C2=A0=C2=A0 /* Initialize the break.=C2=A0 */ >> =C2=A0 =C2=A0 #ifdef DL_PLATFORM_INIT