aboutsummaryrefslogtreecommitdiffstats
path: root/config.mk
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2022-01-21 18:29:26 +0100
committerMattias Andrée <maandree@kth.se>2022-01-21 18:29:26 +0100
commit839a3d17d257e73be9bc99dfa90e56c0824050ba (patch)
tree6bb010351447edbb0ae8d910948b01837d2de9e5 /config.mk
parentFix memory corruption bug in test.c and simplify message byte-length calculation (diff)
downloadlibblake-839a3d17d257e73be9bc99dfa90e56c0824050ba.tar.gz
libblake-839a3d17d257e73be9bc99dfa90e56c0824050ba.tar.bz2
libblake-839a3d17d257e73be9bc99dfa90e56c0824050ba.tar.xz
Initial work on optimising compression function; mm128 version is slower, mm256 version is barely faster
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--config.mk9
1 files changed, 8 insertions, 1 deletions
diff --git a/config.mk b/config.mk
index bfe4895..36843a0 100644
--- a/config.mk
+++ b/config.mk
@@ -1,8 +1,15 @@
PREFIX = /usr
MANPREFIX = $(PREFIX)/share/man
-CC = c99
+CC = cc -std=c11
CPPFLAGS = -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700 -D_GNU_SOURCE
CFLAGS = -Wall -O3
LDFLAGS = -s
+
+# These optimisations may not only break compatibility with
+# processors that the software was not compiled on, but they
+# will infact also degrade performance. Therefore they are
+# only only used for specific translation units.
+CFLAGS_MM128 = -msse4.1 -mavx2
+CFLAGS_MM256 = -msse4.1 -mavx2