From patchwork Mon Oct 12 15:21:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 40705 Return-Path: X-Original-To: patchwork@sourceware.org Delivered-To: patchwork@sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id C2EAF388A41A; Mon, 12 Oct 2020 15:21:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C2EAF388A41A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1602516085; bh=vfbzAckj+yDVXKy/IQfWdXePeAcexAn71Y1zkXQuDgo=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=JB1Wa92SamBIkADH2M19shykXZvMjtTKGe+g/KD6/1UTM9yvf85xjuDMmh3ejxg3S bgNA7d826GietXYLVTAfQctmhiyn2hdsx3Rvynr+nHe2uFZGyKjnraOqlqCx90l8oV b7c2qyfo2EhK6QqC+8jSOLr9Eo2hnbVQrGW0BZaY= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [63.128.21.124]) by sourceware.org (Postfix) with ESMTP id 51583386F407 for ; Mon, 12 Oct 2020 15:21:23 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 51583386F407 Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-2-oWz-53yUO0SSX5Lki5TFoA-1; Mon, 12 Oct 2020 11:21:20 -0400 X-MC-Unique: oWz-53yUO0SSX5Lki5TFoA-1 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 0E5AC57050; Mon, 12 Oct 2020 15:21:19 +0000 (UTC) Received: from oldenburg2.str.redhat.com (ovpn-112-137.ams2.redhat.com [10.36.112.137]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 5B35C6EF54; Mon, 12 Oct 2020 15:21:18 +0000 (UTC) To: libc-alpha@sourceware.org Subject: [PATCH v2 0/3] glibc-hwcaps support for LD_LIBRARY_PATH X-From-Line: e1b80826a62d3f03e1a70bd191f82ee31548b4e9 Mon Sep 17 00:00:00 2001 Message-Id: Date: Mon, 12 Oct 2020 17:21:16 +0200 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1 (gnu/linux) MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Spam-Status: No, score=-6.4 required=5.0 tests=BAYES_00, DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H5, RCVD_IN_MSPIKE_WL, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Florian Weimer via Libc-alpha From: Florian Weimer Reply-To: Florian Weimer Cc: "Paul A. Clarke" Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" This sub-series implements glibc-hwcaps for LD_LIBRARY_PATH, with auto-detected paths for x86-64 and POWER ("power10" being untested). Paul, I hope I have addressed your comments regarding magic bits with the new helper function, _dl_hwcaps_subdirs_build_bitmask. Thanks, Florian Florian Weimer (3): elf: Add glibc-hwcaps support for LD_LIBRARY_PATH x86_64: Add glibc-hwcaps support powerpc64le: Add glibc-hwcaps support elf/Makefile | 66 ++++++++- elf/dl-hwcaps-subdirs.c | 29 ++++ elf/dl-hwcaps.c | 138 ++++++++++++++--- elf/dl-hwcaps.h | 103 +++++++++++++ elf/dl-hwcaps_split.c | 77 ++++++++++ elf/dl-load.c | 7 +- elf/dl-main.h | 11 +- elf/dl-support.c | 5 +- elf/dl-usage.c | 68 ++++++++- elf/markermodMARKER-VALUE.c | 29 ++++ elf/rtld.c | 18 +++ elf/tst-dl-hwcaps_split.c | 139 ++++++++++++++++++ elf/tst-glibc-hwcaps-mask.c | 31 ++++ elf/tst-glibc-hwcaps-prepend.c | 32 ++++ elf/tst-glibc-hwcaps.c | 28 ++++ sysdeps/generic/ldsodefs.h | 20 ++- sysdeps/powerpc/powerpc64/le/Makefile | 22 +++ .../powerpc/powerpc64/le/dl-hwcaps-subdirs.c | 39 +++++ .../powerpc/powerpc64/le/tst-glibc-hwcaps.c | 54 +++++++ sysdeps/x86_64/Makefile | 36 ++++- sysdeps/x86_64/dl-hwcaps-subdirs.c | 66 +++++++++ sysdeps/x86_64/tst-glibc-hwcaps.c | 65 ++++++++ 22 files changed, 1049 insertions(+), 34 deletions(-) create mode 100644 elf/dl-hwcaps-subdirs.c create mode 100644 elf/dl-hwcaps_split.c create mode 100644 elf/markermodMARKER-VALUE.c create mode 100644 elf/tst-dl-hwcaps_split.c create mode 100644 elf/tst-glibc-hwcaps-mask.c create mode 100644 elf/tst-glibc-hwcaps-prepend.c create mode 100644 elf/tst-glibc-hwcaps.c create mode 100644 sysdeps/powerpc/powerpc64/le/dl-hwcaps-subdirs.c create mode 100644 sysdeps/powerpc/powerpc64/le/tst-glibc-hwcaps.c create mode 100644 sysdeps/x86_64/dl-hwcaps-subdirs.c create mode 100644 sysdeps/x86_64/tst-glibc-hwcaps.c