Mercurial > vec
annotate test/Makefile.template @ 40:55cadb1fac4b
*: add mod operation, add GCC vector backend
need to test it with old gcc though. :)
author | Paper <paper@tflc.us> |
---|---|
date | Sun, 27 Apr 2025 02:49:53 -0400 |
parents | f9ca85d2f14c |
children | c6e0df09b86f |
rev | line source |
---|---|
40
55cadb1fac4b
*: add mod operation, add GCC vector backend
Paper <paper@tflc.us>
parents:
39
diff
changeset
|
1 CPPFLAGS += -g -O2 -I../include -Wall -Wpedantic -Werror=strict-aliasing |
36 | 2 CFLAGS += $(CPPFLAGS) -std=c99 |
3 CXXFLAGS += $(CPPFLAGS) -std=c++11 | |
4 | |
5 HEADERS = ../include/vec/vec.h \ | |
39
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
6 ../include/vec/cpu.h \ |
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
7 ../include/vec/mem.h \ |
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
8 ../include/vec/defs.h \ |
36 | 9 ../include/vec/impl/ppc/altivec.h \ |
10 ../include/vec/impl/x86/avx2.h \ | |
11 ../include/vec/impl/x86/avx512f.h \ | |
39
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
12 ../include/vec/impl/x86/avx512bw.h \ |
36 | 13 ../include/vec/impl/x86/mmx.h \ |
14 ../include/vec/impl/x86/sse2.h \ | |
39
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
15 ../include/vec/impl/x86/sse3.h \ |
36 | 16 ../include/vec/impl/x86/sse41.h \ |
39
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
17 ../include/vec/impl/x86/sse42.h \ |
36 | 18 ../include/vec/impl/generic.h \ |
40
55cadb1fac4b
*: add mod operation, add GCC vector backend
Paper <paper@tflc.us>
parents:
39
diff
changeset
|
19 ../include/vec/impl/gcc.h \ |
36 | 20 test_align.h \ |
21 test_arith.h \ | |
22 test_compare.h \ | |
37
4b5a557aa64f
*: turns out extern is a practical joke. rewrite to be always inline again
Paper <paper@tflc.us>
parents:
36
diff
changeset
|
23 test_shift.h \ |
39
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
24 test_benchmark.h \ |
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
25 test_benchmark_vec.c \ |
f9ca85d2f14c
*: rearrange some things; add avx512bw support
Paper <paper@tflc.us>
parents:
37
diff
changeset
|
26 test_benchmark_simple.c |
36 | 27 BINS = test-generic test-host test-cxx |
37
4b5a557aa64f
*: turns out extern is a practical joke. rewrite to be always inline again
Paper <paper@tflc.us>
parents:
36
diff
changeset
|
28 OBJS = test.o test-cxx.o test_benchmark_simple.o test_benchmark_vec.o |
36 | 29 |
30 .PHONY: all clean test | |
31 | |
32 all: $(BINS) | |
33 | |
37
4b5a557aa64f
*: turns out extern is a practical joke. rewrite to be always inline again
Paper <paper@tflc.us>
parents:
36
diff
changeset
|
34 test.o: test.c test_benchmark_simple.o test_benchmark_vec.o $(HEADERS) |
36 | 35 $(CC) $(CFLAGS) -c -o $@ $< |
36 | |
37 test-cxx.o: test.cc | |
38 $(CXX) $(CXXFLAGS) -c -o $@ $< | |
39 | |
37
4b5a557aa64f
*: turns out extern is a practical joke. rewrite to be always inline again
Paper <paper@tflc.us>
parents:
36
diff
changeset
|
40 test-generic: test.o test_benchmark_simple.o test_benchmark_vec.o |
36 | 41 $(CC) $(LDFLAGS) -o $@ $^ |
42 | |
37
4b5a557aa64f
*: turns out extern is a practical joke. rewrite to be always inline again
Paper <paper@tflc.us>
parents:
36
diff
changeset
|
43 test-host: test.o test_benchmark_simple.o test_benchmark_vec.o |
36 | 44 $(CC) $(LDFLAGS) -o $@ $^ |
45 | |
46 test-cxx: test-cxx.o $(HEADERS) | |
47 $(CXX) $(LDFLAGS) -o $@ $< | |
48 | |
49 clean: | |
50 $(RM) $(BINS) $(OBJS) | |
51 | |
52 test: clean $(BINS) | |
53 ./test-generic | |
54 ./test-host | |
55 ./test-cxx |