Skip to content

Commit

Permalink
skip SSE code on aarch64
Browse files Browse the repository at this point in the history
for now.
  • Loading branch information
rurban committed Feb 28, 2024
1 parent 167a096 commit b407ff3
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ ALGOS=$(wildcard source/algos/*.c)
BINS=$(patsubst source/algos/%,source/bin/%,$(patsubst %.c,%,$(ALGOS)))
HELPERS=smart show select test textgen compilesm
TESTS=bm mp kmp tbm bom so
uname_p := $(shell uname -p)
ifneq ($(uname_p),x86_64)
NON_SSE=epsm ssecp ssef
BINS=$(filter-out $(NON_SSE),$(patsubst source/algos/%,source/bin/%,$(patsubst %.c,%,$(ALGOS))))
endif

all: $(BINS) $(HELPERS)

Expand Down
8 changes: 8 additions & 0 deletions source/compilesm.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,14 @@ int main(int argc, char **argv) {
if (filename[len - 1] == 'c' && filename[len - 2] == '.') {
filename[len - 2] = '\0';
current++;
#ifndef __x86_64__
if (!strcmp(filename, "epsm") ||
!strcmp(filename, "ssecp") ||
!strcmp(filename, "ssef")) {
printf("\tSkipped %s.c", filename);
continue;
}
#endif
// compile
sprintf(command, "%s%s.c%s%s", gcc, filename, options, filename);
if (doTest)
Expand Down

0 comments on commit b407ff3

Please sign in to comment.