~mdw
/
catacomb
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
base/regdump.c: Print matching condition codes along with CPU flags.
[catacomb]
/
symm
/
gcm.c
diff --git
a/symm/gcm.c
b/symm/gcm.c
index
73b2851
..
b438415
100644
(file)
--- a/
symm/gcm.c
+++ b/
symm/gcm.c
@@
-778,9
+778,14
@@
void gcm_concat(const gcm_params *p, uint32 *z, const uint32 *x,
#ifdef TEST_RIG
#ifdef TEST_RIG
+#include <mLib/macros.h>
#include <mLib/quis.h>
#include <mLib/testrig.h>
#include <mLib/quis.h>
#include <mLib/testrig.h>
+#ifdef ENABLE_ASM_DEBUG
+# include "regdump.h"
+#endif
+
static void report_failure(const char *test, unsigned nbits,
const char *ref, dstr v[], dstr *d)
{
static void report_failure(const char *test, unsigned nbits,
const char *ref, dstr v[], dstr *d)
{
@@
-820,7
+825,7
@@
static int test_mul(uint32 poly, dstr v[])
#define CHECK(E, what, ref) do { \
for (i = 0; i < nbits/32; i++) STORE32_##E(d.buf + 4*i, z[i]); \
#define CHECK(E, what, ref) do { \
for (i = 0; i < nbits/32; i++) STORE32_##E(d.buf + 4*i, z[i]); \
- if (
memcmp(d.buf, v[I_##ref].buf, nbits/8) != 0)
\
+ if (
MEMCMP(d.buf, !=, v[I_##ref].buf, nbits/8))
\
{ ok = 0; report_failure(what, nbits, #ref, v, &d); } \
} while (0)
{ ok = 0; report_failure(what, nbits, #ref, v, &d); } \
} while (0)
@@
-873,6
+878,9
@@
GCM_WIDTHS(TEST)
int main(int argc, char *argv[])
{
ego(argv[0]);
int main(int argc, char *argv[])
{
ego(argv[0]);
+#ifdef ENABLE_ASM_DEBUG
+ regdump_init();
+#endif
test_run(argc, argv, defs, SRCDIR"/t/gcm");
return (0);
}
test_run(argc, argv, defs, SRCDIR"/t/gcm");
return (0);
}