[Gmp-commit] /var/hg/gmp: Rename some speed macros, to match name of benchmar...
mercurial at gmplib.org
mercurial at gmplib.org
Wed Nov 22 14:54:48 CET 2023
details: /var/hg/gmp/rev/869c08440fbd
changeset: 18462:869c08440fbd
user: Niels Möller <nisse at lysator.liu.se>
date: Wed Nov 22 14:53:47 2023 +0100
description:
Rename some speed macros, to match name of benchmarked function.
diffstat:
ChangeLog | 8 ++++++++
tune/common.c | 10 +++++-----
tune/speed.h | 46 +++++++++++++++++++++++-----------------------
3 files changed, 36 insertions(+), 28 deletions(-)
diffs (186 lines):
diff -r 78ae53e3531e -r 869c08440fbd ChangeLog
--- a/ChangeLog Mon Nov 20 19:37:26 2023 +0100
+++ b/ChangeLog Wed Nov 22 14:53:47 2023 +0100
@@ -1,3 +1,11 @@
+2023-11-22 Niels Möller <nisse at lysator.liu.se>
+
+ * tune/speed.h (SPEED_ROUTINE_MPN_MUL_TSPACE): Rename macro, was
+ SPEED_ROUTINE_MPN_MUL_N_TSPACE. Update all users.
+ (SPEED_ROUTINE_MPN_TOOM22_MUL, SPEED_ROUTINE_MPN_TOOM33_MUL)
+ (SPEED_ROUTINE_MPN_TOOM44_MUL, SPEED_ROUTINE_MPN_TOOM6H_MUL)
+ (SPEED_ROUTINE_MPN_TOOM8H_MUL): Analogous renames, were _MUL_N.
+
2023-11-20 Niels Möller <nisse at lysator.liu.se>
* tune/speed.h (struct speed_params): Add size_ratio field.
diff -r 78ae53e3531e -r 869c08440fbd tune/common.c
--- a/tune/common.c Mon Nov 20 19:37:26 2023 +0100
+++ b/tune/common.c Wed Nov 22 14:53:47 2023 +0100
@@ -1347,27 +1347,27 @@
double
speed_mpn_toom22_mul (struct speed_params *s)
{
- SPEED_ROUTINE_MPN_TOOM22_MUL_N (mpn_toom22_mul);
+ SPEED_ROUTINE_MPN_TOOM22_MUL (mpn_toom22_mul);
}
double
speed_mpn_toom33_mul (struct speed_params *s)
{
- SPEED_ROUTINE_MPN_TOOM33_MUL_N (mpn_toom33_mul);
+ SPEED_ROUTINE_MPN_TOOM33_MUL (mpn_toom33_mul);
}
double
speed_mpn_toom44_mul (struct speed_params *s)
{
- SPEED_ROUTINE_MPN_TOOM44_MUL_N (mpn_toom44_mul);
+ SPEED_ROUTINE_MPN_TOOM44_MUL (mpn_toom44_mul);
}
double
speed_mpn_toom6h_mul (struct speed_params *s)
{
- SPEED_ROUTINE_MPN_TOOM6H_MUL_N (mpn_toom6h_mul);
+ SPEED_ROUTINE_MPN_TOOM6H_MUL (mpn_toom6h_mul);
}
double
speed_mpn_toom8h_mul (struct speed_params *s)
{
- SPEED_ROUTINE_MPN_TOOM8H_MUL_N (mpn_toom8h_mul);
+ SPEED_ROUTINE_MPN_TOOM8H_MUL (mpn_toom8h_mul);
}
double
diff -r 78ae53e3531e -r 869c08440fbd tune/speed.h
--- a/tune/speed.h Mon Nov 20 19:37:26 2023 +0100
+++ b/tune/speed.h Wed Nov 22 14:53:47 2023 +0100
@@ -1474,7 +1474,7 @@
return t; \
}
-#define SPEED_ROUTINE_MPN_MUL_N_TSPACE(call, tsize, minsize) \
+#define SPEED_ROUTINE_MPN_MUL_TSPACE(call, tsize, minsize) \
{ \
mp_ptr wp, tspace; \
unsigned i; \
@@ -1504,100 +1504,100 @@
return t; \
}
-#define SPEED_ROUTINE_MPN_TOOM22_MUL_N(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+#define SPEED_ROUTINE_MPN_TOOM22_MUL(function) \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size, tspace), \
mpn_toom22_mul_itch (s->size, s->size), \
MPN_TOOM22_MUL_MINSIZE)
-#define SPEED_ROUTINE_MPN_TOOM33_MUL_N(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+#define SPEED_ROUTINE_MPN_TOOM33_MUL(function) \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size, tspace), \
mpn_toom33_mul_itch (s->size, s->size), \
MPN_TOOM33_MUL_MINSIZE)
-#define SPEED_ROUTINE_MPN_TOOM44_MUL_N(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+#define SPEED_ROUTINE_MPN_TOOM44_MUL(function) \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size, tspace), \
mpn_toom44_mul_itch (s->size, s->size), \
MPN_TOOM44_MUL_MINSIZE)
-#define SPEED_ROUTINE_MPN_TOOM6H_MUL_N(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+#define SPEED_ROUTINE_MPN_TOOM6H_MUL(function) \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size, tspace), \
mpn_toom6h_mul_itch (s->size, s->size), \
MPN_TOOM6H_MUL_MINSIZE)
-#define SPEED_ROUTINE_MPN_TOOM8H_MUL_N(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+#define SPEED_ROUTINE_MPN_TOOM8H_MUL(function) \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size, tspace), \
mpn_toom8h_mul_itch (s->size, s->size), \
MPN_TOOM8H_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM32_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 2*s->size/3, tspace), \
mpn_toom32_mul_itch (s->size, 2*s->size/3), \
MPN_TOOM32_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM42_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size/2, tspace), \
mpn_toom42_mul_itch (s->size, s->size/2), \
MPN_TOOM42_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM43_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size*3/4, tspace), \
mpn_toom43_mul_itch (s->size, s->size*3/4), \
MPN_TOOM43_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM63_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, s->size/2, tspace), \
mpn_toom63_mul_itch (s->size, s->size/2), \
MPN_TOOM63_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM32_FOR_TOOM43_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 17*s->size/24, tspace), \
mpn_toom32_mul_itch (s->size, 17*s->size/24), \
MPN_TOOM32_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM43_FOR_TOOM32_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 17*s->size/24, tspace), \
mpn_toom43_mul_itch (s->size, 17*s->size/24), \
MPN_TOOM43_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM32_FOR_TOOM53_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 19*s->size/30, tspace), \
mpn_toom32_mul_itch (s->size, 19*s->size/30), \
MPN_TOOM32_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM53_FOR_TOOM32_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 19*s->size/30, tspace), \
mpn_toom53_mul_itch (s->size, 19*s->size/30), \
MPN_TOOM53_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM42_FOR_TOOM53_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 11*s->size/20, tspace), \
mpn_toom42_mul_itch (s->size, 11*s->size/20), \
MPN_TOOM42_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM53_FOR_TOOM42_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 11*s->size/20, tspace), \
mpn_toom53_mul_itch (s->size, 11*s->size/20), \
MPN_TOOM53_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM43_FOR_TOOM54_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 5*s->size/6, tspace), \
mpn_toom42_mul_itch (s->size, 5*s->size/6), \
MPN_TOOM54_MUL_MINSIZE)
#define SPEED_ROUTINE_MPN_TOOM54_FOR_TOOM43_MUL(function) \
- SPEED_ROUTINE_MPN_MUL_N_TSPACE \
+ SPEED_ROUTINE_MPN_MUL_TSPACE \
(function (wp, s->xp, s->size, s->yp, 5*s->size/6, tspace), \
mpn_toom54_mul_itch (s->size, 5*s->size/6), \
MPN_TOOM54_MUL_MINSIZE)
More information about the gmp-commit
mailing list