public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
From: Sunil K Pandey <skpgkp2@gmail.com>
To: libc-alpha@sourceware.org
Subject: [PATCH 12/12] benchtests: Add tanhf function to bench-math
Date: Fri, 29 Oct 2021 10:19:41 -0700	[thread overview]
Message-ID: <20211029171941.4161172-13-skpgkp2@gmail.com> (raw)
In-Reply-To: <20211029171941.4161172-1-skpgkp2@gmail.com>

Add tanhf function to bench-math and copy tanhf-inputs to benchtests.
Motivation for this patch is to prepare for upcoming libmvec new
functions.  Float and double version of libmvec functions stays
together.

tanhf-inputs file generated from tanh-inputs file using following
scaling formula:

f = d * (FLT_MAX/DBL_MAX)

Where d is input(double) and f is output(float).  If scaled float value
is duplicate in new input file, nextafterf() function used to find next
float value, ensuring no duplicates.
---
 benchtests/Makefile     |   1 +
 benchtests/tanhf-inputs | 203 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 204 insertions(+)
 create mode 100644 benchtests/tanhf-inputs

diff --git a/benchtests/Makefile b/benchtests/Makefile
index 8d050d270d..9e81eb8842 100644
--- a/benchtests/Makefile
+++ b/benchtests/Makefile
@@ -90,6 +90,7 @@ bench-math := \
   sqrt \
   tan \
   tanh \
+  tanhf \
   tgamma \
   trunc \
   truncf \
diff --git a/benchtests/tanhf-inputs b/benchtests/tanhf-inputs
new file mode 100644
index 0000000000..e9a641f34e
--- /dev/null
+++ b/benchtests/tanhf-inputs
@@ -0,0 +1,203 @@
+## args: float
+## ret: float
+## includes: math.h
+-0x1.79ea72p-9
+-0x1.94d4ep+3
+-0x1.b63e92p+0
+-0x1.299708p-5
+-0x1.35ec26p-19
+-0x1.d139c6p-49
+-0x1.ba38b6p-6
+-0x1.83f902p+3
+-0x1.dc3722p-51
+-0x1.922cb4p-3
+0x1.357956p+1
+0x1.3d52b2p+3
+-0x1.f7e794p-7
+-0x1.3f96b4p+0
+-0x1.a82266p+1
+-0x1.ced122p+0
+0x1.e4e264p-4
+0x1.8c5fdp-40
+0x1.c1b892p+0
+-0x1.223b8p-33
+0x1.718468p-41
+-0x1.8a4422p-1
+-0x1.67e982p-41
+-0x1.368b8p+1
+-0x1.663534p-39
+0x1.1aa844p-18
+-0x1.d70654p-43
+0x1.c84f96p+2
+-0x1.f327d6p-9
+0x1.212b32p-49
+0x1.62533p+3
+0x1.ca2524p-32
+0x1.d502b8p+2
+-0x1.5c6892p-29
+-0x1.c05afp+0
+-0x1.3f35f8p+4
+0x1.f71314p+1
+0x1.ffb1ep+2
+0x1.cad8c2p-32
+-0x1.ff34f2p-3
+0x1.6156d8p-53
+-0x1.4b5a84p+0
+0x1.c22fd4p+3
+0x1.3fa1e6p+2
+-0x1.90f3f6p-52
+0x1.0d16c6p+1
+0x1.421a76p+1
+-0x1.4b251p+3
+0x1.ac89b6p+0
+-0x1.f5a006p+1
+0x1.263f96p-25
+-0x1.81c16p+2
+-0x1.4c0a56p+4
+-0x1.2c2e34p-47
+-0x1.b57eb4p-21
+-0x1.53a808p-39
+0x1.535964p-43
+-0x1.d049e6p-23
+-0x1.ad3f88p+1
+-0x1.b95594p-35
+0x1.480e54p-33
+0x1.9f8f62p-54
+-0x1.80ed54p+2
+0x1.0a15bp-42
+-0x1.2700a6p+3
+0x1.825744p-42
+-0x1.a96978p+1
+0x1.0fbf54p-16
+-0x1.68dc34p+0
+-0x1.08c496p+1
+0x1.7112c2p+1
+0x1.45aa62p-13
+0x1.243186p+1
+0x1.2712f6p-52
+0x1.cd7698p-32
+0x1.9ab284p-15
+0x1.9cf328p-21
+0x1.dccc32p-48
+-0x1.b2a4e6p+0
+-0x1.9802a6p+0
+0x1.3da496p-27
+-0x1.d46704p-50
+0x1.12d69p-25
+0x1.347632p-39
+-0x1.2f5428p+1
+-0x1.44a7fp-18
+0x1.c95486p-45
+0x1.c9922p+3
+0x1.a067b2p+2
+-0x1.4cfdd4p-10
+0x1.509082p-43
+0x1.bbbc04p-34
+-0x1.d7973p+1
+0x1.4aeba2p-11
+0x1.721152p+2
+-0x1.3a4016p+3
+0x1.555714p-37
+0x1.a877a8p-46
+0x1.ba8ad2p-6
+0x1.e500b2p+0
+-0x1.7c7802p+1
+-0x1.89c342p-21
+-0x1.9653b8p+1
+0x1.cbc546p+1
+0x1.80dd34p-29
+0x1.a8861p-35
+0x1.3bf708p+1
+-0x1.58fc26p-51
+0x1.99f184p-37
+0x1.a5c078p+3
+0x1.1676a2p-31
+-0x1.151f62p+0
+-0x1.82b124p-21
+-0x1.9c78a8p+2
+0x1.81db56p+0
+-0x1.403546p+3
+-0x1.884176p-5
+-0x1.8cd808p+2
+0x1.28b7d4p-16
+-0x1.dbdfc6p+3
+-0x1.93ca44p+2
+-0x1.863014p-40
+0x1.6f0606p-48
+0x1.e4bbp+0
+0x1.4e7cd6p-22
+0x1.d82514p+0
+0x1.08ea66p-4
+-0x1.4eb052p+3
+-0x1.94754p-38
+-0x1.9d4c18p-18
+0x1.ffdc34p+3
+-0x1.f01e86p-45
+-0x1.040acp-37
+0x1.deca68p+3
+0x1.7ea616p-31
+-0x1.5ad552p+1
+-0x1.184778p+2
+-0x1.da6836p+1
+0x1.d47856p-32
+-0x1.8dff62p+2
+0x1.512c92p-42
+0x1.0d46e6p-38
+-0x1.f2cba4p+3
+-0x1.1bd606p+1
+-0x1.314a92p+1
+0x1.78e992p+3
+0x1.547ba4p+1
+-0x1.10b636p+1
+0x1.2bc994p-3
+-0x1.8edd86p+3
+-0x1.0f5bf4p-54
+0x1.e38d84p-43
+-0x1.9c3138p-25
+-0x1.01ea82p+3
+0x1.b68126p-9
+-0x1.49f406p+0
+-0x1.72a778p-8
+0x1.198eap+1
+-0x1.ecc604p-21
+-0x1.e649cp+3
+0x1.06f164p+0
+-0x1.693d86p-10
+-0x1.008746p+1
+-0x1.05519p-51
+-0x1.df8af6p+2
+-0x1.fa5552p-13
+0x1.5d5fap-9
+0x1.726ff6p+2
+-0x1.17fe02p+2
+0x1.261da4p-35
+-0x1.55b502p+1
+-0x1.5b3682p+2
+-0x1.2e7716p-16
+0x1.5be034p+0
+-0x1.b530c4p+2
+0x1.b3c984p-50
+0x1.9286b6p+3
+0x1.106138p+2
+0x1.df2ad2p-26
+-0x1.1ae766p+4
+0x1.1cecd8p+4
+0x1.e1619p-48
+-0x1.43ad34p+3
+0x1.f978d6p+2
+0x1.340976p+2
+0x1.2ca3d4p+3
+-0x1.75fb14p+0
+0x1.1c6be4p+4
+0x1.1b5488p+0
+-0x1.73c328p-33
+0x1.0e0354p-54
+-0x1.168b02p+1
+-0x1.816c54p-45
+-0x1.ee867p+2
+-0x1.137d5p+1
+0x1.094c26p-22
+0x1.87a6a4p-37
+0x1.9c4674p-9
+0x1.2ba8d8p-43
+0x1.35e724p+4
-- 
2.31.1


  parent reply	other threads:[~2021-10-29 18:08 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-22 19:04 [PATCH] Add missing math functions to benchtests Sunil K Pandey
2021-10-22 20:24 ` Noah Goldstein
2021-10-22 20:38 ` Adhemerval Zanella
2021-10-22 23:12   ` Sunil Pandey
2021-10-25 17:05   ` Joseph Myers
2021-10-27 23:04     ` [PATCH v2] benchtests: Add acosf to bench-math Sunil K Pandey
2021-10-29 13:38       ` Sunil Pandey
2021-10-29 13:51         ` H.J. Lu
2021-10-29 17:19           ` [PATCH 00/12] benchtests: Add float version of math functions " Sunil K Pandey
2021-10-29 17:19             ` [PATCH 01/12] benchtests: Add acoshf function " Sunil K Pandey
2021-11-03 17:00               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 02/12] benchtests: Add asinf " Sunil K Pandey
2021-11-04  7:48               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 03/12] benchtests: Add asinhf " Sunil K Pandey
2021-11-04  8:16               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 04/12] benchtests: Add atanf " Sunil K Pandey
2021-11-04  8:03               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 05/12] benchtests: Add atanhf " Sunil K Pandey
2021-11-04  8:14               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 06/12] benchtests: Add cbrtf " Sunil K Pandey
2021-11-04  7:58               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 07/12] benchtests: Add coshf " Sunil K Pandey
2021-11-03 16:43               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 08/12] benchtests: Add erfcf " Sunil K Pandey
2021-11-04  8:11               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 09/12] benchtests: Add erff " Sunil K Pandey
2021-11-03 17:07               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 10/12] benchtests: Add log10f " Sunil K Pandey
2021-11-04  8:00               ` Paul Zimmermann
2021-10-29 17:19             ` [PATCH 11/12] benchtests: Add sinhf " Sunil K Pandey
2021-11-04  7:53               ` Paul Zimmermann
2021-10-29 17:19             ` Sunil K Pandey [this message]
2021-11-03 16:53               ` [PATCH 12/12] benchtests: Add tanhf " Paul Zimmermann
2021-11-01 13:31             ` [PATCH 00/12] benchtests: Add float version of math functions " Sunil Pandey
2021-11-01 13:55               ` H.J. Lu
2021-10-29 20:44           ` [PATCH 0/4] benchtests: Add atan2f, expm1f, log1pf and tanf " Sunil K Pandey
2021-10-29 20:44             ` [PATCH 1/4] benchtests: Add atan2f function " Sunil K Pandey
2021-11-03 16:22               ` Paul Zimmermann
2021-10-29 20:44             ` [PATCH 2/4] benchtests: Add expm1f " Sunil K Pandey
2021-11-03 16:33               ` Paul Zimmermann
2021-10-29 20:44             ` [PATCH 3/4] benchtests: Add log1pf " Sunil K Pandey
2021-11-03 16:17               ` Paul Zimmermann
2021-10-29 20:44             ` [PATCH 4/4] benchtests: Add tanf " Sunil K Pandey
2021-11-01 13:33             ` [PATCH 0/4] benchtests: Add atan2f, expm1f, log1pf and tanf " Sunil Pandey
2021-11-01 20:33               ` Joseph Myers
2021-11-04  8:57       ` [PATCH v2] benchtests: Add acosf " Paul Zimmermann
2021-11-05 22:20         ` Sunil Pandey

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

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

  git send-email \
    --in-reply-to=20211029171941.4161172-13-skpgkp2@gmail.com \
    --to=skpgkp2@gmail.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).