annotate test/Makefile.template @ 15:e05c257c6a23

*: huge refactor, add many new x86 intrinsics and the like ALSO!! now intrinsics are enabled at runtime, depending on what is detected. altivec *should* still work but I only tested compiling it. the major version has been updated to 2.0 for this...
author Paper <paper@tflc.us>
date Wed, 20 Nov 2024 04:10:37 -0500
parents
children 41dd962abdd1
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
15
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
1 CFLAGS += -g -O2 -std=c99 -I../include
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
2
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
3 HEADERS = ../include/vec/vec.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
4 ../include/vec/impl/ppc/altivec.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
5 ../include/vec/impl/x86/avx2.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
6 ../include/vec/impl/x86/avx512f.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
7 ../include/vec/impl/x86/mmx.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
8 ../include/vec/impl/x86/sse2.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
9 ../include/vec/impl/x86/sse41.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
10 ../include/vec/impl/cpu.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
11 ../include/vec/impl/fallback.h \
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
12 ../include/vec/impl/generic.h
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
13 BINS = test-generic test-host
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
14 OBJS = vec-generic.o vec-host.o test.o
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
15
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
16 .PHONY: all clean test
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
17
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
18 all: $(BINS)
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
19
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
20 vec-generic.o: ../src/vec.c
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
21 $(CC) $(CFLAGS) -DVEC_SUPPRESS_HW=1 -c -o $@ $<
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
22
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
23 vec-host.o: ../src/vec.c
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
24 $(CC) $(CFLAGS) -c -o $@ $<
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
25
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
26 test.o: test.c
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
27 $(CC) $(CFLAGS) -c -o $@ $<
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
28
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
29 test-generic: vec-generic.o test.o
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
30 $(CC) $(LDFLAGS) -o $@ $^
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
31
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
32 test-host: vec-host.o test.o
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
33 $(CC) $(LDFLAGS) -o $@ $^
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
34
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
35 clean:
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
36 $(RM) $(BINS) $(OBJS)
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
37
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
38 test: clean $(BINS)
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
39 ./test-generic
e05c257c6a23 *: huge refactor, add many new x86 intrinsics and the like
Paper <paper@tflc.us>
parents:
diff changeset
40 ./test-host