From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web11.4717.1682052343581550185 for ; Thu, 20 Apr 2023 21:45:43 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=R2cnvai5; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1682052342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=i7TcH7ND7OBiSOw4x3OkThcT1zhmNjhbT5F+SqoNEFc=; b=R2cnvai5o3/DpYKv3qxL65MQPFJCxNJFrkP3PXB8cHfts21IocNIQF6lDoy/de+tSjr/GZ dpWXBghUM8XA8XoBeLrR6GS3YbafbifGSS94rkGJRRHpplkmWbzVU97eYND00ThXq6q5gC nQXdsnX0gOpkzQxr6SXpU1YIY1PQE8g= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-465-k2YKUdFyPLqaI1B9qeYkCQ-1; Fri, 21 Apr 2023 00:45:39 -0400 X-MC-Unique: k2YKUdFyPLqaI1B9qeYkCQ-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B844F3C0E44D; Fri, 21 Apr 2023 04:45:38 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.192.59]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7B3672026D16; Fri, 21 Apr 2023 04:45:38 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 636F818000B3; Fri, 21 Apr 2023 06:45:35 +0200 (CEST) From: "Gerd Hoffmann" To: devel@edk2.groups.io Cc: Yuwei Chen , Oliver Steffen , Bob Feng , =?UTF-8?q?Marvin=20H=C3=A4user?= , Daniel Schaefer , Chao Li , Dongyan Qian , Michael D Kinney , Pawel Polawski , Baoqi Zhang , Leif Lindholm , Rebecca Cran , Zhiguang Liu , Sunil V L , Ard Biesheuvel , Liming Gao , Gerd Hoffmann Subject: [PATCH v5 02/10] MdePkg: don't set visibility to hidden Date: Fri, 21 Apr 2023 06:45:27 +0200 Message-Id: <20230421044535.4030762-3-kraxel@redhat.com> In-Reply-To: <20230421044535.4030762-1-kraxel@redhat.com> References: <20230421044535.4030762-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true Not needed any more on modern toolchains, they are better in not creating a GOT without this trick. Signed-off-by: Gerd Hoffmann --- MdePkg/Include/X64/ProcessorBind.h | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/MdePkg/Include/X64/ProcessorBind.h b/MdePkg/Include/X64/ProcessorBind.h index f0a4d00142b9..afbb4b6273fb 100644 --- a/MdePkg/Include/X64/ProcessorBind.h +++ b/MdePkg/Include/X64/ProcessorBind.h @@ -21,20 +21,6 @@ #pragma pack() #endif -#if defined (__GNUC__) && defined (__pic__) && !defined (USING_LTO) && !defined (__APPLE__) -// -// Mark all symbol declarations and references as hidden, meaning they will -// not be subject to symbol preemption. This allows the compiler to refer to -// symbols directly using relative references rather than via the GOT, which -// contains absolute symbol addresses that are subject to runtime relocation. -// -// The LTO linker will not emit GOT based relocations when all symbol -// references can be resolved locally, and so there is no need to set the -// pragma in that case (and doing so will cause other issues). -// - #pragma GCC visibility push (hidden) -#endif - #if defined (__INTEL_COMPILER) // // Disable ICC's remark #869: "Parameter" was never referenced warning. -- 2.40.0