From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS31976 209.132.180.0/23 X-Spam-Status: No, score=-4.0 required=3.0 tests=AWL,BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dcvr.yhbt.net (Postfix) with ESMTPS id A89BE1F45E for ; Sat, 15 Feb 2020 20:18:08 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:message-id:date:mime-version :content-type:content-transfer-encoding; q=dns; s=default; b=FkQ MD/6MpiUyjMIoTwhE/lfgzv867/cE2xmytmZaGKMgNUGbplDoUeiUVw6EDg+5z1p zD1XH7To8TEPAxCLXUa+ulEdrhPB8690zn5npJlM1oXLDuGZGHgBQZu/33W98xhT 7GpFw323qKsq/rnW5h1Ifxlow4p9WDUSgP/CKZdI= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:subject:message-id:date:mime-version :content-type:content-transfer-encoding; s=default; bh=ITq6K2H/7 i81LydDYoDbwfA2/t0=; b=ra/DrtRv1y66doWkqud568PzE1Jdtz2qoypVL7wgT UNxvfzG3txB/Imr/sty13xpkEFeSvBr3cFcGqR8NcDZWxIC1PDl4SqaC3rJm0+hF pyOw2+T7Za4PmGAlCGNi0jjtTOOFsaJb89ZPJill8WsuLo66Kcdp85d78snUxAJ0 8g= Received: (qmail 130817 invoked by alias); 15 Feb 2020 20:18:05 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Received: (qmail 130806 invoked by uid 89); 15 Feb 2020 20:18:05 -0000 Authentication-Results: sourceware.org; auth=none X-HELO: us-smtp-1.mimecast.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581797882; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Nte2BPuNcKHpPz8kb9zR+6AeuabOjjhqQ4NeqbNfNkE=; b=DZCD//ENVciy89eqxPQO9atHIyAXYS2h4TItnmSzSlAIpf7X5e/CYTE8AlYhR/4TunNyqr YGaao7SanFcYhUJiV4hN2ucYmBWZuTnVlPVfIJox7wvylTj2hea3tIESfUdvSMwjqZMa18 YFq8NPnIjo/56qTb+gNjhkmhU6D7QHo= From: Florian Weimer To: libc-alpha@sourceware.org Subject: [PATCH 0/3] Full removal of libc.so/ld.so interposition (bug 25486) X-From-Line: 0552fff2977cffb5884a08b5e628fd6b08e81709 Mon Sep 17 00:00:00 2001 Message-Id: Date: Sat, 15 Feb 2020 21:17:51 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Apart from malloc, the other use of symbol interposition is the ld.so exception handling mechanism. We can (carefully) use some form of thread-local storage in the loader now that Hurd has THREAD_GETMEM/THREAD_SETMEM. This leads to a nice simplification of this code. Tested on x86_64-linux-gnu and i686-linux-gnu. Full build-many-glibcs.py with the scripts/localplt.awk change is still running. A previous build was fine except on C-SKY, hence the second commit in this series. Thanks, Florian Florian Weimer (3): ld.so: Export tls_init_tp_called as __rtld_tls_init_tp_called scripts/localplt.awk: Handle DT_JMPREL with empty PLT (for C-SKY) elf: Rework exception handling in the dynamic loader [BZ #25486] elf/Makefile | 6 +- elf/Versions | 6 - elf/{dl-error-skeleton.c =3D> dl-catch.c} | 139 +++++++++--------- elf/dl-error-minimal.c | 23 --- elf/dl-error.c | 27 ---- elf/rtld.c | 12 +- nptl/descr.h | 3 + scripts/localplt.awk | 18 ++- sysdeps/generic/ldsodefs.h | 11 +- sysdeps/generic/localplt.data | 5 - sysdeps/mach/hurd/i386/localplt.data | 9 +- sysdeps/mach/hurd/i386/tls.h | 3 + sysdeps/unix/sysv/linux/aarch64/localplt.data | 5 - sysdeps/unix/sysv/linux/alpha/localplt.data | 5 - sysdeps/unix/sysv/linux/arm/localplt.data | 5 - sysdeps/unix/sysv/linux/csky/localplt.data | 5 - sysdeps/unix/sysv/linux/hppa/localplt.data | 5 - sysdeps/unix/sysv/linux/i386/localplt.data | 5 - sysdeps/unix/sysv/linux/ia64/localplt.data | 5 - .../sysv/linux/m68k/coldfire/localplt.data | 5 - .../unix/sysv/linux/m68k/m680x0/localplt.data | 5 - .../unix/sysv/linux/microblaze/localplt.data | 5 - sysdeps/unix/sysv/linux/nios2/localplt.data | 5 - .../linux/powerpc/powerpc32/fpu/localplt.data | 5 - .../powerpc/powerpc32/nofpu/localplt.data | 5 - .../linux/powerpc/powerpc64/localplt.data | 5 - sysdeps/unix/sysv/linux/riscv/localplt.data | 5 - sysdeps/unix/sysv/linux/s390/localplt.data | 5 - sysdeps/unix/sysv/linux/sh/localplt.data | 5 - .../sysv/linux/sparc/sparc32/localplt.data | 5 - .../sysv/linux/sparc/sparc64/localplt.data | 5 - sysdeps/x86_64/localplt.data | 5 - 32 files changed, 114 insertions(+), 248 deletions(-) rename elf/{dl-error-skeleton.c =3D> dl-catch.c} (80%) delete mode 100644 elf/dl-error-minimal.c delete mode 100644 elf/dl-error.c --=20 2.24.1