File reproducible.patch of Package fftw3
Index: fftw-3.3.5/kernel/planner.c
===================================================================
--- fftw-3.3.5.orig/kernel/planner.c
+++ fftw-3.3.5/kernel/planner.c
@@ -785,6 +785,24 @@ static void forget(planner *ego, amnesia
/* FIXME: what sort of version information should we write? */
#define WISDOM_PREAMBLE PACKAGE "-" VERSION " " STRINGIZE(X(wisdom))
static const char stimeout[] = "TIMEOUT";
+static const char snotlive[] = "NOTLIVE";
+
+const char *solution2string(const solution *l, planner *ego)
+{
+ if(!LIVEP(l))
+ return snotlive;
+ if(SLVNDX(l) == INFEASIBLE_SLVNDX)
+ return stimeout;
+ slvdesc *sp = ego->slvdescs + SLVNDX(l);
+ return sp->reg_nam;
+}
+
+int solutioncmp(const void *a, const void *b, void *ego)
+{
+ const char *stra = solution2string((const solution *)a, (planner *)ego);
+ const char *strb = solution2string((const solution *)b, (planner *)ego);
+ return strcmp(stra, strb);
+}
/* tantus labor non sit cassus */
static void exprt(planner *ego, printer *p)
@@ -799,6 +817,7 @@ static void exprt(planner *ego, printer
"(" WISDOM_PREAMBLE " #x%M #x%M #x%M #x%M\n",
m.s[0], m.s[1], m.s[2], m.s[3]);
+ qsort_r(ht->solutions, ht->hashsiz, sizeof(solution *), solutioncmp, ego);
for (h = 0; h < ht->hashsiz; ++h) {
solution *l = ht->solutions + h;
if (LIVEP(l)) {