From patchwork Sun Sep 19 18:46:38 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Iain Sandoe X-Patchwork-Id: 45164 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 13227385800D for ; Sun, 19 Sep 2021 18:46:57 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from smtp001-out.apm-internet.net (smtp001-out.apm-internet.net [85.119.248.222]) by sourceware.org (Postfix) with ESMTPS id A1DB13858409 for ; Sun, 19 Sep 2021 18:46:40 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org A1DB13858409 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=sandoe.co.uk Authentication-Results: sourceware.org; spf=none smtp.mailfrom=sandoe.co.uk Received: (qmail 98073 invoked from network); 19 Sep 2021 18:46:39 -0000 X-APM-Out-ID: 16320771999807 X-APM-Authkey: 257869/1(257869/1) 4 Received: from unknown (HELO ?192.168.1.214?) (81.138.1.83) by smtp001.apm-internet.net with SMTP; 19 Sep 2021 18:46:39 -0000 From: Iain Sandoe Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.21\)) Subject: [pushed] libgcc, X86, Darwin: Handle symbols for HF cases. Message-Id: Date: Sun, 19 Sep 2021 19:46:38 +0100 To: GCC Patches X-Mailer: Apple Mail (2.3445.104.21) X-Spam-Status: No, score=-15.3 required=5.0 tests=BAYES_00, GIT_PATCH_0, KAM_COUK, KAM_DMARC_STATUS, KAM_LAZY_DOMAIN_SECURITY, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2, SPF_HELO_NONE, SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces+patchwork=sourceware.org@gcc.gnu.org Sender: "Gcc-patches" Hi This reorganises the Darwin symbol vers files to include the generic ones at the top level; allowing for arch ports to override (via either exclusion or inclusion as needed). We add an X86-specific vers file containing the new HF symbols. Note that although Darwin does not use ELF-style symbol versioning - the parser that produces the map can consume it. Using the ELF-style description will help us know at which rev the symbols were introduced. tested on x86_64, i686 darwin and x86_64 linux (, m32). pushed to master, thanks Iain Signed-off-by: Iain Sandoe libgcc/ChangeLog: * config/i386/t-darwin: Add in a vers file for X86-specific symbols. * config/t-darwin: Add the generic symbol maps here... * config/t-slibgcc-darwin: ... removing from here. * config/i386/libgcc-darwin.ver: New file. --- libgcc/config/i386/libgcc-darwin.ver | 21 +++++++++++++++++++++ libgcc/config/i386/t-darwin | 3 +++ libgcc/config/t-darwin | 3 +++ libgcc/config/t-slibgcc-darwin | 1 - 4 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 libgcc/config/i386/libgcc-darwin.ver -- diff --git a/libgcc/config/i386/libgcc-darwin.ver b/libgcc/config/i386/libgcc-darwin.ver new file mode 100644 index 00000000000..5224cdc982e --- /dev/null +++ b/libgcc/config/i386/libgcc-darwin.ver @@ -0,0 +1,21 @@ + + +%inherit GCC_12.0.0 GCC_7.0.0 +GCC_12.0.0 { + __divhc3 + __mulhc3 + __eqhf2 + __nehf2 + __extendhfdf2 + __extendhfsf2 + __extendhftf2 + __extendhfxf2 + __fixhfti + __fixunshfti + __floattihf + __floatuntihf + __truncdfhf2 + __truncsfhf2 + __trunctfhf2 + __truncxfhf2 +} diff --git a/libgcc/config/i386/t-darwin b/libgcc/config/i386/t-darwin index 5f2c69725d0..c6b3acaaca2 100644 --- a/libgcc/config/i386/t-darwin +++ b/libgcc/config/i386/t-darwin @@ -1,3 +1,6 @@ LIB2_SIDITI_CONV_FUNCS = yes LIB2ADD = $(srcdir)/config/darwin-64.c LIB2FUNCS_EXCLUDE = _fixtfdi _fixunstfdi _floatditf _floatunditf + +# Extra symbols for this port. +SHLIB_MAPFILES += $(srcdir)/config/i386/libgcc-darwin.ver diff --git a/libgcc/config/t-darwin b/libgcc/config/t-darwin index 4b6317b5d85..14ae6b35a4e 100644 --- a/libgcc/config/t-darwin +++ b/libgcc/config/t-darwin @@ -24,3 +24,6 @@ d10-uwfef.o: $(srcdir)/config/darwin10-unwind-find-enc-func.c libd10-uwfef.a: d10-uwfef.o $(AR_CREATE_FOR_TARGET) $@ d10-uwfef.o $(RANLIB_FOR_TARGET) $@ + +# Symbols for all the sub-ports. +SHLIB_MAPFILES = libgcc-std.ver $(srcdir)/config/libgcc-libsystem.ver diff --git a/libgcc/config/t-slibgcc-darwin b/libgcc/config/t-slibgcc-darwin index a6ada456e40..60d6d176013 100644 --- a/libgcc/config/t-slibgcc-darwin +++ b/libgcc/config/t-slibgcc-darwin @@ -24,7 +24,6 @@ SHLIB_LINK = $(CC) $(LIBGCC2_CFLAGS) $(LDFLAGS) -dynamiclib -nodefaultlibs \ SHLIB_MKMAP = $(srcdir)/mkmap-flat.awk SHLIB_MKMAP_OPTS = -v leading_underscore=1 -SHLIB_MAPFILES = libgcc-std.ver $(srcdir)/config/libgcc-libsystem.ver SHLIB_VERPFX = $(srcdir)/config/$(cpu_type)/libgcc-darwin # we're only going to build the stubs if the target slib is /usr/lib