-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
48 lines (38 loc) · 1.34 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
TIME = time --format " %Uuser %Ssystem %Eelapsed %PCPU %Mk"
TMP ?= /tmp
build doc:
cargo $@ --all-features
examples:
cargo run --features="rug" --example basic
bench:
@echo "Dune build"
-@$(TIME) dune build examples/speed.exe
-@$(TIME) _build/default/examples/speed.exe
@$(TIME) cargo build --profile release \
--example speed --example speed_toms748 --example speed_f64 \
--example speed_roots
@$(TIME) target/release/examples/speed_f64
@$(TIME) target/release/examples/speed_roots
@$(TIME) target/release/examples/speed
@$(TIME) target/release/examples/speed_toms748
@echo "no_std"
@cargo build --profile release --no-default-features --quiet \
--example speed --example speed_toms748
@$(TIME) target/release/examples/speed
@$(TIME) target/release/examples/speed_toms748
bench_mut:
@$(TIME) cargo build --profile release --features rug \
--example speed_rug_bisect --example speed_rug_toms748
@$(TIME) target/release/examples/speed_rug_bisect
@$(TIME) target/release/examples/speed_rug_toms748
criterion:
cargo criterion --plotting-backend plotters
neval:
cargo bench neval --all-features
flamegraph:
cargo build --profile release --example speed
flamegraph -o $(TMP)/speed.svg -- target/release/examples/speed
clean:
cargo clean
-dune clean
.PHONY: build doc examples bench bench_mut criterion neval flamegraph clean