unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are no longer required.
@ 2020-02-14 16:12 GT
  2020-02-14 16:14 ` GT
  0 siblings, 1 reply; 3+ messages in thread
From: GT @ 2020-02-14 16:12 UTC (permalink / raw)
  To: libc-alpha\@sourceware.org, tnggil@protonmail.com

[-- Attachment #1: Type: text/plain, Size: 346 bytes --]

This patch is in response to
<https://sourceware.org/ml/libc-alpha/2020-02/msg00625.html>

With this patch, branch tuliom/libmvec has all changes needed to
enable GCC to autovectorize libmvec functions. Other than sincos.
Getting GCC to vectorize sincos is work-in-progress; presently GCC
does NOT vectorize for any architecture.

Bert.

[-- Attachment #2: 0001-PPC64-Remove-vec_finite_alias.c-as-aliases-it-create.patch --]
[-- Type: application/octet-stream, Size: 3486 bytes --]

From a6b9405b03d3e553757ae8fd0588dbe037c12240 Mon Sep 17 00:00:00 2001
From: Bert Tenjy <bert.tenjy@gmail.com>
Date: Fri, 14 Feb 2020 09:49:27 -0600
Subject: [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are
 no longer required.

File bits/math-finite.h has been removed; consequently aliases for SIMD log/f,
exp/f, and pow/f can also be eliminated.
---
 sysdeps/powerpc/powerpc64/fpu/Makefile        |  8 ---
 .../powerpc/powerpc64/fpu/vec_finite_alias.c  | 65 -------------------
 2 files changed, 73 deletions(-)
 delete mode 100644 sysdeps/powerpc/powerpc64/fpu/vec_finite_alias.c

diff --git a/sysdeps/powerpc/powerpc64/fpu/Makefile b/sysdeps/powerpc/powerpc64/fpu/Makefile
index a52a9c129a..05075c2a75 100644
--- a/sysdeps/powerpc/powerpc64/fpu/Makefile
+++ b/sysdeps/powerpc/powerpc64/fpu/Makefile
@@ -5,11 +5,3 @@ CFLAGS-s_llrint.c += -fno-builtin-lrintf -fno-builtin-llrintf
 # Same as before but for lroundf and llroundf
 CFLAGS-s_llround.c += -fno-builtin-lroundf -fno-builtin-llroundf
 endif
-
-ifeq ($(subdir),mathvec)
-libmvec-support += vec_finite_alias
-
-CFLAGS-vec_finite_alias.c += -mabi=altivec -maltivec -mvsx
-
-libmvec-static-only-routines = vec_finite_alias
-endif
diff --git a/sysdeps/powerpc/powerpc64/fpu/vec_finite_alias.c b/sysdeps/powerpc/powerpc64/fpu/vec_finite_alias.c
deleted file mode 100644
index bbf5657b3b..0000000000
--- a/sysdeps/powerpc/powerpc64/fpu/vec_finite_alias.c
+++ /dev/null
@@ -1,65 +0,0 @@
-/* These aliases added as workaround to exclude unnecessary symbol
-   aliases in libmvec.so while compiler creates the vector names
-   based on scalar asm name.  Corresponding discussion is at
-   <https://gcc.gnu.org/ml/gcc/2015-06/msg00173.html>.
-   Copyright (C) 2019 Free Software Foundation, Inc.
-   This file is part of the GNU C Library.
-
-   The GNU C Library is free software; you can redistribute it and/or
-   modify it under the terms of the GNU Lesser General Public
-   License as published by the Free Software Foundation; either
-   version 2.1 of the License, or (at your option) any later version.
-
-   The GNU C Library is distributed in the hope that it will be useful,
-   but WITHOUT ANY WARRANTY; without even the implied warranty of
-   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-   Lesser General Public License for more details.
-
-   You should have received a copy of the GNU Lesser General Public
-   License along with the GNU C Library; if not, see
-   <http://www.gnu.org/licenses/>.  */
-
-#include <altivec.h>
-
-extern vector double _ZGVbN2v_log (vector double);
-extern vector float _ZGVbN4v_logf (vector float);
-extern vector double _ZGVbN2v_exp (vector double);
-extern vector float _ZGVbN4v_expf (vector float);
-extern vector double _ZGVbN2vv_pow (vector double, vector double);
-extern vector float _ZGVbN4vv_powf (vector float, vector float);
-
-vector double
-_ZGVbN2v___log_finite (vector double x)
-{
-  return _ZGVbN2v_log (x);
-}
-
-vector float
-_ZGVbN4v___logf_finite (vector float x)
-{
-  return _ZGVbN4v_logf (x);
-}
-
-vector double
-_ZGVbN2v___exp_finite (vector double x)
-{
-  return _ZGVbN2v_exp (x);
-}
-
-vector float
-_ZGVbN4v___expf_finite (vector float x)
-{
-  return _ZGVbN4v_expf (x);
-}
-
-vector double
-_ZGVbN2vv___pow_finite (vector double x, vector double y)
-{
-  return _ZGVbN2vv_pow (x, y);
-}
-
-vector float
-_ZGVbN4vv___powf_finite (vector float x, vector float y)
-{
-  return _ZGVbN4vv_powf (x, y);
-}
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are no longer required.
  2020-02-14 16:12 [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are no longer required GT
@ 2020-02-14 16:14 ` GT
  2020-02-20 19:37   ` Tulio Magno Quites Machado Filho
  0 siblings, 1 reply; 3+ messages in thread
From: GT @ 2020-02-14 16:14 UTC (permalink / raw)
  To: libc-alpha\@sourceware.org, tnggil@protonmail.com

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Friday, February 14, 2020 11:12 AM, GT <tnggil@protonmail.com> wrote:

> This patch is in response to
> https://sourceware.org/ml/libc-alpha/2020-02/msg00625.html
>
> With this patch, branch tuliom/libmvec has all changes needed to
> enable GCC to autovectorize libmvec functions. Other than sincos.
> Getting GCC to vectorize sincos is work-in-progress; presently GCC
> does NOT vectorize for any architecture.
>
Last line above should be:
[P]resently GCC does NOT vectorize SINCOS for any architecture.

Bert.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are no longer required.
  2020-02-14 16:14 ` GT
@ 2020-02-20 19:37   ` Tulio Magno Quites Machado Filho
  0 siblings, 0 replies; 3+ messages in thread
From: Tulio Magno Quites Machado Filho @ 2020-02-20 19:37 UTC (permalink / raw)
  To: GT, libc-alpha

GT <tnggil@protonmail.com> writes:

> On Friday, February 14, 2020 11:12 AM, GT <tnggil@protonmail.com> wrote:
>
>> This patch is in response to
>> https://sourceware.org/ml/libc-alpha/2020-02/msg00625.html
>>
>> With this patch, branch tuliom/libmvec has all changes needed to
>> enable GCC to autovectorize libmvec functions. Other than sincos.
>> Getting GCC to vectorize sincos is work-in-progress; presently GCC
>> does NOT vectorize for any architecture.
>>
> Last line above should be:
> [P]resently GCC does NOT vectorize SINCOS for any architecture.

There was a conflict between this patch and my previous merge.

This patch has been merged into tuliom/libmvec.

Thanks!

-- 
Tulio Magno

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-02-20 19:38 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-14 16:12 [PATCH v0] PPC64: Remove vec_finite_alias.c as aliases it creates are no longer required GT
2020-02-14 16:14 ` GT
2020-02-20 19:37   ` Tulio Magno Quites Machado Filho

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).