-
Notifications
You must be signed in to change notification settings - Fork 7
Expand file tree
/
Copy pathMakefile
More file actions
16 lines (12 loc) · 861 Bytes
/
Makefile
File metadata and controls
16 lines (12 loc) · 861 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
all: lib.exe
clean:
rm -f *.o *.ll *.exe
%.o: %.c
../dockerscript.sh clang-12 -c -fuse-ld=lld -flto /host/$^ -O2 -ffast-math -o /host/$@
lib.exe: myblas.o multisource.o
../dockerscript.sh clang-12 -fuse-ld=lld -flto /host/myblas.o /host/multisource.o -O2 -ffast-math -o /host/$@ -Wl,-mllvm=-load=/Enzyme/enzyme/build/Enzyme/LLDEnzyme-12.so
# for more recent LLVM versions (tested with v16.0.2) you have to do something like the following (using my tested, non-docker based install, extension to Docker is obvious but
# I am not posting it since I cannot test it)
# clang -fuse-ld=lld -flto ./myblas.o ./multisource.o -O2 -ffast-math -o ./$@ -Wl,--load-pass-plugin=../../Enzyme/enzyme/build/Enzyme/LLDEnzyme-16.so
run-%: %.exe
../dockerscript.sh /host/$^ 3