Skip to content

Commit

Permalink
fix makefiles to use new rustflags
Browse files Browse the repository at this point in the history
  • Loading branch information
ZuseZ4 committed Oct 1, 2024
1 parent fdb0d09 commit 747e4f9
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion enzyme/benchmarks/ReverseMode/ba/Makefile.make
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ clean:
rm -f *.ll *.o results.txt results.json

$(dir)/benchmarks/ReverseMode/ba/target/release/libbars.a: src/lib.rs Cargo.toml
ENZYME_LOOSE_TYPES=1 cargo +enzyme rustc --release --lib --crate-type=staticlib --features=libm
RUSTFLAGS="-Z autodiff=LooseTypes" cargo +enzyme rustc --release --lib --crate-type=staticlib --features=libm

ba.o: ba.cpp $(dir)/benchmarks/ReverseMode/ba/target/release/libbars.a
clang++ $(LOAD) $(BENCH) ba.cpp -I /usr/include/c++/11 -I/usr/include/x86_64-linux-gnu/c++/11 -O2 -o ba.o -lpthread $(BENCHLINK) -lm $(dir)/benchmarks/ReverseMode/ba/target/release/libbars.a -L /usr/lib/gcc/x86_64-linux-gnu/11
Expand Down
4 changes: 2 additions & 2 deletions enzyme/benchmarks/ReverseMode/gmm/Makefile.make
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# RUN: if [ %llvmver -ge 12 ] || [ %llvmver -le 9 ]; then cd %S && LD_LIBRARY_PATH="%bldpath:$LD_LIBRARY_PATH" BENCH="%bench" BENCHLINK="%blink" LOAD="%newLoadClangEnzyme" make -B gmm.o results.json -f %s; fi
# RUN: cd %S && LD_LIBRARY_PATH="%bldpath:$LD_LIBRARY_PATH" BENCH="%bench" BENCHLINK="%blink" LOAD="%newLoadClangEnzyme" make -B gmm.o results.json VERBOSE=1 -f %s

.PHONY: clean

Expand All @@ -8,7 +8,7 @@ clean:
rm -f *.ll *.o results.txt results.json

$(dir)/benchmarks/ReverseMode/gmm/target/release/libgmmrs.a: src/lib.rs Cargo.toml
ENZYME_LOOSE_TYPES=1 cargo +enzyme rustc --release --lib --crate-type=staticlib --features=libm
RUSTFLAGS="-Z autodiff=LooseTypes" cargo +enzyme rustc --release --lib --crate-type=staticlib --features=libm

gmm.o: gmm.cpp $(dir)/benchmarks/ReverseMode/gmm/target/release/libgmmrs.a
clang++ $(LOAD) $(BENCH) gmm.cpp -I /usr/include/c++/11 -I/usr/include/x86_64-linux-gnu/c++/11 -O2 -o gmm.o -lpthread $(BENCHLINK) -lm $(dir)/benchmarks/ReverseMode/gmm/target/release/libgmmrs.a -L /usr/lib/gcc/x86_64-linux-gnu/11
Expand Down
2 changes: 1 addition & 1 deletion enzyme/benchmarks/ReverseMode/lstm/Makefile.make
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ clean:
rm -f *.ll *.o results.json

$(dir)/benchmarks/ReverseMode/lstm/target/release/liblstm.a: src/lib.rs Cargo.toml
ENZYME_LOOSE_TYPES=1 cargo +enzyme rustc --release --lib --crate-type=staticlib
RUSTFLAGS="-Z autodiff=LooseTypes" cargo +enzyme rustc --release --lib --crate-type=staticlib

%-unopt.ll: %.cpp
clang++ $(BENCH) $^ -pthread -O2 -fno-vectorize -fno-slp-vectorize -ffast-math -fno-unroll-loops -o $@ -S -emit-llvm
Expand Down

0 comments on commit 747e4f9

Please sign in to comment.