aboutsummaryrefslogtreecommitdiff
path: root/include/weights_5.h
diff options
context:
space:
mode:
authortslil <tslil@posteo.de>2026-09-19 20:24:08 +0100
committertslil <tslil@posteo.de>2026-09-19 20:32:46 +0100
commit9f5f953a95c8617cd2fdd24f7402af632c1b07c2 (patch)
treed78abd447065baf3d100935a2cfbb181d50b0fb6 /include/weights_5.h
parentfe7268110d93e2abe4d4b51ac64e83521a8d6382 (diff)
transposing the weights gives ~2.5x speedup
Diffstat (limited to 'include/weights_5.h')
-rw-r--r--include/weights_5.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/weights_5.h b/include/weights_5.h
index d48a05a..74a4366 100644
--- a/include/weights_5.h
+++ b/include/weights_5.h
@@ -22,10 +22,10 @@
#define FIVE_DENSE_NUM 64
// this does some kind of magic vectorisation
-#define NN_ALIGNED __attribute__((aligned(16)))
+#define NN_ALIGNED __attribute__((aligned(32)))
extern const float FIVE_embedding[7];
-extern const float FIVE_dense_weights[FIVE_DENSE_NUM][FIVE_INP_NUM] NN_ALIGNED;
+extern const float FIVE_dense_weights[FIVE_INP_NUM][FIVE_DENSE_NUM] NN_ALIGNED;
extern const float FIVE_dense_biases[FIVE_DENSE_NUM];
extern const float FIVE_logit_weights[FIVE_DENSE_NUM] NN_ALIGNED;
extern const float FIVE_logit_bias;