-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathMakefile
More file actions
56 lines (49 loc) · 1.2 KB
/
Makefile
File metadata and controls
56 lines (49 loc) · 1.2 KB
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
49
50
51
52
53
54
55
56
SHELL := /bin/bash
MAKEFLAGS := --jobs=$(shell nproc)
TARGETS := gen1brcdata \
1brc-scratch \
1brc-000-baseline \
1brc-001-baseline-read-limitmem \
1brc-002-plain-scanner \
1brc-005-baseline-scan \
1brc-010-baseline-scan-tweak \
1brc-020-fanout \
1brc-030-fanout-scanner \
1brc-040-file-partition \
1brc-050-mmap \
1brc-060-mmap-float \
1brc-060-mmap-int \
1brc-070-mmap-int-tweaks \
1brc-075-mmap-int-extra \
1brc-076-mmap-int-za-key \
1brc-080-mmap-int-static-map \
1brc-081-mmap-int-static-map-za-key \
1brc-082-mmap-faster-int-static-map-za-key \
1brc-401-baseline \
1brc-402-avoid-double-hashing \
1brc-403-avoid-parse-float \
1brc-404-temp-int32 \
1brc-405-avoid-cut \
1brc-406-no-scanner \
1brc-407-custom-hash-table \
1brc-408-parallel-baseline \
1brc-409-parallel-opt \
1brc-410-fast-semi \
.PHONY: all
all: $(TARGETS)
%: cmd/%/main.go
go build -o $@ $<
.PHONY: clean
clean:
rm -f $(TARGETS)
rm -f cpu.txt cpu.png cpu.svg cpu.pprof
measurements.txt: gen1brcdata
./gen1brcdata > measurements.txt
cities.txt: measurements.txt
cut -d ';' -f 1 measurements.txt | LC_ALL=C sort -S30% -u > cities.txt
.PHONY: test
test:
go test ./...
.PHONY: bench
bench:
go test -bench=. ./...