unofficial mirror of libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: "Martin Liška" <mliska@suse.cz>
To: libc-alpha@sourceware.org
Cc: Joseph Myers <joseph@codesourcery.com>
Subject: [PATCH] Add new Fortran vector math header file.
Date: Mon, 18 Feb 2019 15:31:44 +0100	[thread overview]
Message-ID: <863ffa3b-af66-7d82-21a8-e809fd6c1b62@suse.cz> (raw)

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

Hi.

The patch adds support for Fortran vector math routines as added
into GCC 9.  The header files will be installed to the same
folder as math-vector.h.

Thanks,
Martin

ChangeLog:

2019-02-18  Martin Liska  <mliska@suse.cz>

	* math/Makefile: Install math-vector-fortran.h.
	* sysdeps/x86/fpu/bits/math-vector-fortran.h: New file.
---
 math/Makefile                              |  1 +
 sysdeps/x86/fpu/bits/math-vector-fortran.h | 43 ++++++++++++++++++++++
 2 files changed, 44 insertions(+)
 create mode 100644 sysdeps/x86/fpu/bits/math-vector-fortran.h



[-- Attachment #2: 0001-Add-new-Fortran-vector-math-header-file.patch --]
[-- Type: text/x-patch, Size: 3210 bytes --]

diff --git a/math/Makefile b/math/Makefile
index 76e8edac19..fcaa2dbe9c 100644
--- a/math/Makefile
+++ b/math/Makefile
@@ -26,6 +26,7 @@ headers		:= math.h bits/mathcalls.h bits/mathinline.h \
 		   fpu_control.h complex.h bits/cmathcalls.h fenv.h \
 		   bits/fenv.h bits/fenvinline.h bits/mathdef.h tgmath.h \
 		   bits/math-finite.h bits/math-vector.h \
+			 bits/math-vector-fortran.h \
 		   bits/libm-simd-decl-stubs.h bits/iscanonical.h \
 		   bits/flt-eval-method.h bits/fp-fast.h bits/fp-logb.h \
 		   bits/long-double.h bits/mathcalls-helper-functions.h \
diff --git a/sysdeps/x86/fpu/bits/math-vector-fortran.h b/sysdeps/x86/fpu/bits/math-vector-fortran.h
new file mode 100644
index 0000000000..f2d5e57085
--- /dev/null
+++ b/sysdeps/x86/fpu/bits/math-vector-fortran.h
@@ -0,0 +1,43 @@
+! Platform-specific Fortran SIMD declarations of math functions.
+!   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/>.  */
+
+!GCC$ builtin (cos) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (cosf) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (sin) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (sinf) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (sincos) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (sincosf) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (log) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (logf) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (exp) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (expf) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (pow) attributes simd (notinbranch) if('x86_64')
+!GCC$ builtin (powf) attributes simd (notinbranch) if('x86_64')
+
+!GCC$ builtin (cos) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (cosf) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (sin) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (sinf) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (sincos) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (sincosf) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (log) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (logf) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (exp) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (expf) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (pow) attributes simd (notinbranch) if('x32')
+!GCC$ builtin (powf) attributes simd (notinbranch) if('x32')


             reply	other threads:[~2019-02-18 14:31 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-18 14:31 Martin Liška [this message]
2019-02-18 17:55 ` [PATCH] Add new Fortran vector math header file Joseph Myers
2019-02-19  9:18   ` Martin Liška
2019-02-19 17:59     ` Joseph Myers
2019-02-19 19:14       ` Zack Weinberg
2019-02-20  9:43         ` Martin Liška
2019-02-20 13:05           ` Zack Weinberg
2019-02-20 13:52             ` Martin Liška
2019-02-26 17:56               ` [PATCH] Fix location where math-vector-fortran.h is installed Martin Liška
2019-02-26 18:05                 ` Joseph Myers
2019-02-26 18:30                   ` Martin Liška
2019-02-26 21:16                     ` Florian Weimer
2019-02-26 21:41                       ` Zack Weinberg
2019-02-27  8:09                         ` Martin Liška
2019-02-27 10:12                           ` Florian Weimer
2019-02-27 10:36                             ` Martin Liška
2019-02-27 11:30                           ` Andreas Schwab
2019-02-27 11:53                             ` Martin Liška
2019-02-27 15:00                           ` Zack Weinberg
2019-02-28 13:18                             ` Martin Liška
2019-02-28 13:30                               ` Zack Weinberg
2019-02-28 13:32                                 ` Florian Weimer
2019-03-01  9:31                                   ` Martin Liška
2019-03-01 22:30                                     ` Steve Ellcey
2019-03-05 12:03                                     ` Martin Liška
2019-03-06 21:13                                       ` Joseph Myers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/libc/involved.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=863ffa3b-af66-7d82-21a8-e809fd6c1b62@suse.cz \
    --to=mliska@suse.cz \
    --cc=joseph@codesourcery.com \
    --cc=libc-alpha@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).