[PATCH v2] New generic cosf
H.J. Lu
hjl.tools@gmail.com
Wed Dec 6 19:14:00 GMT 2017
On Wed, Dec 6, 2017 at 10:47 AM, Paul Clarke <pc@us.ibm.com> wrote:
> The same logic used in s_cosf.S version for x86 and powerpc
> is used to create a generic s_cosf.c, so there is no performance
> improvement in x86_64 and powerpc64.
>
> -- 8< --
> For s390, this is the improvement noted.
>
> Before patch:
> "cosf": {
> "": {
> "duration": 1.00388e+10,
> "iterations": 1.34624e+08,
> "max": 1655.32,
> "min": 4.243,
> "mean": 74.5692
> }
> }
> After patch:
> "cosf": {
> "": {
> "duration": 9.89888e+09,
> "iterations": 4.63972e+08,
> "max": 1089.59,
> "min": 6.789,
> "mean": 21.3351
> }
> }
>
> Tested on s390x, x86_64 and powerpc64le and powerpc32.
>
> I'll reply to this post with a diff with the latest generic s_sinf.c,
> since including it here could easily be confused with the patch body.
Please provide a diff against the latest generic s_sinf.c.
I assume both s_sinf.c and s_cosf.c use the same set of constant
tables. We should share them instead of duplication.
--
H.J.
More information about the Libc-alpha
mailing list