From patchwork Sat Dec 16 04:01:26 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sam James X-Patchwork-Id: 179797 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:24d3:b0:fb:cd0c:d3e with SMTP id r19csp24452dyi; Fri, 15 Dec 2023 20:03:54 -0800 (PST) X-Google-Smtp-Source: AGHT+IFxhbrBmvXGyHFz8lu7rEec+yysNgGxxPGI7/pATN0tCr+Nuzg4ltsuYCN2HsFVGZI+b7q9 X-Received: by 2002:a05:620a:4953:b0:77e:fdcb:780f with SMTP id vz19-20020a05620a495300b0077efdcb780fmr13895489qkn.68.1702699434183; Fri, 15 Dec 2023 20:03:54 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1702699434; cv=pass; d=google.com; s=arc-20160816; b=uF0GX1md5JADhgYERt5gWQXgTHDaEMZE+CQsbZjmoTt7x95Ri3iW3m4272ucO5h0mj UORDfzQpwkJL7+HaMJl0xW4nnT94a+Vg4ZJVdfbOOmmWWTIlnEJw1thTgjGbzOhQPnzt FENXoMuSI83vkSkpj06lXfsN6NpmXQOGHlsmApm74mZ5D3v/bHcDA9HRl9e0REwBcvfl x/3a3ZFPhzwJOdRPb2zr69CXK+E9WpW2d4aHDL80ygT8x0Q3auGf53mpntgxKgWrmq0z X+378EfwtPqtPiV+x0xxe4FwkEBiIW9LzqKhiBysWqqP5rKY6b6oN5fYcJyyt18Wb3jO BDMQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:arc-filter:dmarc-filter:delivered-to; bh=jxv732UoXD4CxnRhV88S2bIsN/3+Vl6d5rWIhVNO1dI=; fh=K6PyHuw3ZXsdAJsiwR1V00MJz/XCQlRStXtMmfw3mzI=; b=iRzhJDrlSF2KnxbsYQ2GYqvNvznC0iL8KSWttkIJ9EkC/HFQTUBT8/VRwacZgtPvnB 5SjdduAvDA6eLL9pjoMPq2HMg2x+52NPQe3KMITMUHpcrEbpVStPMpZiDLyffsifL1Sg IuJ6MvW/SAYXkxR0pXmbMgJrsGRLyq/H0xVBmw4r103NWXCqnEsF4WbQmtvp1kaMIfS3 TMB9/GFQEPRnEnWIslx5Fii6nl8zKzffN4Cczf+0iMVLil7a9PRSoXkuxbzVlQ5TWk7X TgGcv04CR3cNpJCscQoEyWNhI44wULHBGAtGCnb7fR2Bl4j009gdqS09PvZ+LOxkGRmf 8mYA== ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gentoo.org Received: from server2.sourceware.org (server2.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id bp8-20020a05620a458800b007770c0ebe08si20953759qkb.14.2023.12.15.20.03.54 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 15 Dec 2023 20:03:54 -0800 (PST) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gentoo.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id ACAA63830B42 for ; Sat, 16 Dec 2023 04:03:32 +0000 (GMT) X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) by sourceware.org (Postfix) with ESMTP id B06323857C5B for ; Sat, 16 Dec 2023 04:02:53 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org B06323857C5B Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gentoo.org Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gentoo.org ARC-Filter: OpenARC Filter v1.0.0 sourceware.org B06323857C5B Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=140.211.166.183 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1702699375; cv=none; b=WgZDWzSO9ZP2PaedO5gcNZywI/ebJldaFZNYYPDqc2EmX0g7LwmQ3IRIbO+ue2YWfdtOqmOP8OI6EiefPz8Yf78kwaYw7aqfxuxzXzQLiYIAoW9V+IOZNin7wqbd95D3QI4f6Dns0AZxW51vt2EVvZDT5pqvQKQewP9ndgdCVM0= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1702699375; c=relaxed/simple; bh=mzPS82dSUB/AGKyvJ5OL95RdxS87it+SsClrrTyxG7E=; h=From:To:Subject:Date:Message-ID:MIME-Version; b=bBD/jCKo9jXIBOraj/tnZtl8qFeqn8jrHN/B9/AMqMkedDWRuxmqZg5Y/MZXvQ1cJPwHPOObzBlWIOE4CItlbfguLNw7i1jfljGqxjgETJubosqzo6whBMROiqxO9tIe56VDHrPHIfDDGfrbQkeJwuEJmVEVd10qc4y9oO780pg= ARC-Authentication-Results: i=1; server2.sourceware.org From: Sam James To: binutils@sourceware.org Cc: nickc@redhat.com, "H.J. Lu" Subject: [2.41 PATCH 03/10] ld: Build libpr23169a.so with -z lazy Date: Sat, 16 Dec 2023 04:01:26 +0000 Message-ID: <20231216040239.1981071-4-sam@gentoo.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231216040239.1981071-1-sam@gentoo.org> References: <20231216040239.1981071-1-sam@gentoo.org> MIME-Version: 1.0 X-Spam-Status: No, score=-10.0 required=5.0 tests=BAYES_00, GIT_PATCH_0, JMQ_SPF_NEUTRAL, KAM_DMARC_STATUS, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1785409762062669958 X-GMAIL-MSGID: 1785409762062669958 From: "H.J. Lu" pr23169b test only works with lazy binding. To work with linker which disables lazy binding by default, build pr23169b binaries with -z lazy. PR ld/30698 * ld-ifunc/ifunc.exp: Build pr23169b binaries with -z lazy. (cherry picked from commit 51dd9e7c4cab13748f31f6575aed0672f03d6710) --- ld/testsuite/ld-ifunc/ifunc.exp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ld/testsuite/ld-ifunc/ifunc.exp b/ld/testsuite/ld-ifunc/ifunc.exp index edabcc3f744..2bf656e73b2 100644 --- a/ld/testsuite/ld-ifunc/ifunc.exp +++ b/ld/testsuite/ld-ifunc/ifunc.exp @@ -604,7 +604,7 @@ run_cc_link_tests [list \ ] \ [list \ "Build libpr23169a.so" \ - "-shared" \ + "-shared -Wl,-z,lazy" \ "-fPIC -O2 -g" \ { pr23169a.c } \ {} \ @@ -751,7 +751,7 @@ run_ld_link_exec_tests [list \ ] \ [list \ "Run pr23169b" \ - "-pie -Wl,--no-as-needed tmpdir/libpr23169a.so" \ + "-pie -Wl,--no-as-needed,-z,lazy tmpdir/libpr23169a.so" \ "" \ { pr23169b.c pr23169c.c } \ "pr23169b" \