From patchwork Fri Dec 13 22:24:25 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Gabriel F. T. Gomes" X-Patchwork-Id: 36866 Received: (qmail 96124 invoked by alias); 13 Dec 2019 22:25:18 -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 Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 96069 invoked by uid 89); 13 Dec 2019 22:25:17 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.2 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, KAM_NUMSUBJECT, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy=H*F:D*br X-HELO: smtpout1.mo803.mail-out.ovh.net From: "Gabriel F. T. Gomes" To: Subject: [PATCH v4 7/9] ldbl-128ibm-compat: Do not mix -mabi=*longdouble and -mlong-double-128 Date: Fri, 13 Dec 2019 19:24:25 -0300 Message-ID: <20191213222427.14278-8-gabriel@inconstante.net.br> In-Reply-To: <20191213222427.14278-1-gabriel@inconstante.net.br> References: <20191213222427.14278-1-gabriel@inconstante.net.br> MIME-Version: 1.0 X-Ovh-Tracer-Id: 1137440382290939587 X-VR-SPAMSTATE: OK X-VR-SPAMSCORE: 0 X-VR-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedufedrudelledgudeiudcutefuodetggdotefrodftvfcurfhrohhfihhlvgemucfqggfjpdevjffgvefmvefgnecuuegrihhlohhuthemucehtddtnecunecujfgurhephffvufffkffojghfgggtgfhisehtkeertdertdejnecuhfhrohhmpedfifgrsghrihgvlhcuhfdrucfvrdcuifhomhgvshdfuceoghgrsghrihgvlhesihhntghonhhsthgrnhhtvgdrnhgvthdrsghrqeenucfkpheptddrtddrtddrtddpudejledrudekvddrudehuddrkeeknecurfgrrhgrmhepmhhouggvpehsmhhtphdqohhuthdphhgvlhhopefgigegrdgvmhhprdhlohgtrghlpdhinhgvtheptddrtddrtddrtddpmhgrihhlfhhrohhmpehgrggsrhhivghlsehinhgtohhnshhtrghnthgvrdgvthhirdgsrhdprhgtphhtthhopehlihgstgdqrghlphhhrgesshhouhhrtggvfigrrhgvrdhorhhgnecuvehluhhsthgvrhfuihiivgeptd From: "Gabriel F. T. Gomes" No changes since v3. No changes since v2. Changes since v1: - Do not try to remove -mabi=ieeelongdouble, since it hasn't been added. The removal is a residue from our initial development. -- 8< -- Some compiler versions, e.g. GCC 7, complain when -mlong-double-128 is used together with -mabi=ibmlongdouble or -mabi=ieeelongdouble, producing the following error message: cc1: error: ‘-mabi=ibmlongdouble’ requires ‘-mlong-double-128’ This patch removes -mlong-double-128 from the compilation lines that explicitly request -mabi=*longdouble. Tested for powerpc64le. Reviewed-by: Tulio Magno Quites Machado Filho --- sysdeps/ieee754/ldbl-128ibm-compat/Makefile | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/sysdeps/ieee754/ldbl-128ibm-compat/Makefile b/sysdeps/ieee754/ldbl-128ibm-compat/Makefile index 8f6a09091a..7efbd00089 100644 --- a/sysdeps/ieee754/ldbl-128ibm-compat/Makefile +++ b/sysdeps/ieee754/ldbl-128ibm-compat/Makefile @@ -258,6 +258,13 @@ ldbl-extra-routines += err \ CFLAGS-ieee128-qefgcvt.c += -mabi=ieeelongdouble -Wno-psabi -mno-gnu-attribute CFLAGS-ieee128-qefgcvt_r.c += -mabi=ieeelongdouble -Wno-psabi -mno-gnu-attribute +# Remove -mlong-double-128 because it does not work correctly with +# -mabi=ibmlongdoule in some GCC versions, e.g. GCC 7. +$(foreach o,$(all-object-suffixes),$(objpfx)ieee128-qefgcvt$(o)): \ + sysdep-CFLAGS := $(filter-out -mlong-double-128, $(sysdep-CFLAGS)) +$(foreach o,$(all-object-suffixes),$(objpfx)ieee128-qefgcvt_r$(o)): \ + sysdep-CFLAGS := $(filter-out -mlong-double-128, $(sysdep-CFLAGS)) + tests-internal += tst-ibm128-warn tst-ieee128-warn tests-internal += tst-ibm128-error tst-ieee128-error tests-internal += tst-ibm128-efgcvt tst-ieee128-efgcvt @@ -334,5 +341,12 @@ ldbl-ibm128-files := $(objpfx)test-%-ibm128^ \ $(foreach r,$(ldbl-extra-routines),$(objpfx)$(r)^) \ $(foreach r,$(ldbl-extra-routines),$(objpfx)$(r)-internal^) obj-suf-foreach = $(foreach suf,$(all-object-suffixes),$(subst ^,$(suf),$(1))) + +# Remove -mlong-double-128 because it does not work correctly with +# -mabi=ibmlongdoule in some GCC versions, e.g. GCC 7. +$(call obj-suf-foreach,$(ldbl-ibm128-files)): \ + sysdep-CFLAGS := $(filter-out -mlong-double-128, $(sysdep-CFLAGS)) + +# Explicitly add -mabi=ibm-long-double to required files. $(call obj-suf-foreach,$(ldbl-ibm128-files)): \ sysdep-CFLAGS += -mabi=ibmlongdouble