Changeset 278516c for doc/generic_types/evaluation/Makefile
- Timestamp:
- Apr 25, 2017, 11:59:02 AM (8 years ago)
- Branches:
- ADT, aaron-thesis, arm-eh, ast-experimental, cleanup-dtors, deferred_resn, demangler, enum, forall-pointer-decay, jacob/cs343-translation, jenkins-sandbox, master, new-ast, new-ast-unique-expr, new-env, no_list, persistent-indexer, pthread-emulation, qualifiedEnum, resolv-new, with_gc
- Children:
- 592b9fa, cf67057
- Parents:
- 026a0f5 (diff), 89a9be2 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified doc/generic_types/evaluation/Makefile ¶
r026a0f5 r278516c 1 CC = gcc 1 2 CFA = cfa 2 3 DEPFLAGS = -MMD -MP … … 6 7 endif 7 8 CXXFLAGS = $(CFLAGS) --std=c++14 9 MAKEFILE_NAME = ${firstword ${MAKEFILE_LIST}} 8 10 9 .PHONY : all clean distclean run-c run-cpp run-cfa run11 .PHONY : all clean run-c run-cpp run-cfa run 10 12 11 all : c-bench cpp-bench cfa-bench cpp-vbench13 all : c-bench cpp-bench cpp-vbench cfa-bench 12 14 13 15 # rewrite object generation to auto-determine deps … … 17 19 18 20 c-%.o : c-%.c 19 c-%.o : c-%.c c-%.d20 21 $(COMPILE.c) $(OUTPUT_OPTION) -c $< 21 22 22 23 cpp-%.o : cpp-%.cpp 23 cpp-%.o : cpp-%.cpp cpp-%.d24 24 $(COMPILE.cpp) $(OUTPUT_OPTION) -c $< 25 25 26 26 cfa-%.o : cfa-%.c 27 cfa-%.o : cfa-%.c cfa-%.d28 27 $(COMPILE.cfa) $(OUTPUT_OPTION) -c $< 29 28 30 COBJS = c-stack.o c-pair.o c-print.o 31 CPPOBJS = 32 CPPVOBJS = cpp-vstack.o 33 CFAOBJS = cfa-stack.o cfa-pair.o cfa-print.o 29 COBJS = c-stack.o c-pair.o c-print.o c-bench.o 30 CPPOBJS = cpp-bench.o 31 CPPVOBJS = cpp-vstack.o cpp-vbench.o 32 CFAOBJS = cfa-stack.o cfa-pair.o cfa-print.o cfa-bench.o 34 33 35 CFILES = c-bench.c bench.h $(COBJS:.o=.h) $(COBJS:.o=.c) 36 CPPFILES = cpp-bench.cpp bench.hpp cpp-stack.hpp cpp-pair.hpp cpp-print.hpp 37 CPPVFILES = cpp-vbench.cpp bench.hpp object.hpp $(CPPVOBJS:.o=.hpp) $(CPPVOBJS:.o=.cpp) cpp-vprint.hpp 38 CFAFILES = cfa-bench.c bench.h $(CFAOBJS:.o=.h) $(CFAOBJS:.o=.c) 34 ${COBJS} ${CPPOBJS} ${CPPVOBJS} ${CFAOBJS} : ${MAKEFILE_NAME} 39 35 40 c-bench: c-bench.c c-bench.d $(COBJS) 41 $(COMPILE.c) -o $@ $< $(COBJS) $(LDFLAGS) 36 CFILES = bench.h $(patsubst c-bench.h,,$(COBJS:.o=.h)) $(COBJS:.o=.c) 37 CPPFILES = bench.hpp cpp-stack.hpp cpp-pair.hpp cpp-print.hpp $(CPPOBJS:.o=.cpp) 38 CPPVFILES = bench.hpp object.hpp cpp-vprint.hpp $(patsubst cpp-vbench.hpp,,$(CPPVOBJS:.o=.hpp)) $(CPPVOBJS:.o=.cpp) 39 CFAFILES = bench.h $(patsubst cfa-bench.h,,$(CFAOBJS:.o=.h)) $(CFAOBJS:.o=.c) 42 40 43 c pp-bench: cpp-bench.cpp cpp-bench.d $(CPPOBJS)44 $(COMPILE.c pp) -o $@ $< $(CPPOBJS) $(LDFLAGS)41 c-bench : $(COBJS) c-bench.o 42 $(COMPILE.c) $(LDFLAGS) $^ -o $@ 45 43 46 cpp- vbench: cpp-vbench.cpp cpp-vbench.d $(CPPVOBJS)47 $(COMPILE.cpp) -o $@ $< $(CPPVOBJS) $(LDFLAGS)44 cpp-bench : $(CPPOBJS) cpp-bench.o 45 $(COMPILE.cpp) $(LDFLAGS) $^ -o $@ 48 46 49 c fa-bench: cfa-bench.c cfa-bench.d $(CFAOBJS)50 $(COMPILE.c fa) -o $@ $< $(CFAOBJS) $(LDFLAGS)47 cpp-vbench : $(CPPVOBJS) cpp-vbench.o 48 $(COMPILE.cpp) $(LDFLAGS) $^ -o $@ 51 49 52 clean: 53 -rm $(COBJS) c-bench 54 -rm $(CPPOBJS) cpp-bench 55 -rm $(CPPVOBJS) cpp-vbench 56 -rm $(CFAOBJS) cfa-bench 50 cfa-bench : $(CFAOBJS) cfa-bench.o 51 $(COMPILE.cfa) $(LDFLAGS) $^ -o $@ 57 52 58 distclean: clean 59 -rm $(COBJS:.o=.d) c-bench.d 60 -rm $(CPPOBJS:.o=.d) cpp-bench.d 61 -rm $(CPPVOBJS:.o=.d) cpp-vbench.d 62 -rm $(CFAOBJS:.o=.d) cfa-bench.d 53 # include dependency files 54 -include $(COBJS:.o=.d) 55 -include $(CPPOBJS:.o=.d) 56 -include $(CPPVOBJS:.o=.d) 57 -include $(CFAOBJS:.o=.d) 63 58 64 run-c: c-bench 59 clean : 60 rm -f $(COBJS) $(COBJS:.o=.d) c-bench 61 rm -f $(CPPOBJS) $(CPPOBJS:.o=.d) cpp-bench 62 rm -f $(CPPVOBJS) $(CPPVOBJS:.o=.d) cpp-vbench 63 rm -f $(CFAOBJS) $(CFAOBJS:.o=.d) cfa-bench 64 65 run-c : c-bench 65 66 @echo 66 67 @echo '## C ##' 67 @/usr/bin/time -f 'max_memory:\t%M kilobytes' ./ c-bench68 @/usr/bin/time -f 'max_memory:\t%M kilobytes' ./$< 68 69 @printf 'source_size:\t%8d lines\n' `cat $(CFILES) | wc -l` 69 70 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CFILES) | fgrep '/***/' -c` 70 @printf 'binary_size:\t%8d bytes\n' `stat -c %s c-bench`71 @printf 'binary_size:\t%8d bytes\n' `stat -c %s $<` 71 72 72 run-cfa: cfa-bench 73 run-cpp : cpp-bench 74 @echo 75 @echo '## C++ ##' 76 @/usr/bin/time -f 'max_memory:\t %M kilobytes' ./$< 77 @printf 'source_size:\t%8d lines\n' `cat $(CPPFILES) | wc -l` 78 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CPPFILES) | fgrep '/***/' -c` 79 @printf 'binary_size:\t%8d bytes\n' `stat -c %s $<` 80 81 run-cppv : cpp-vbench 82 @echo 83 @echo '## C++obj ##' 84 @/usr/bin/time -f 'max_memory:\t%M kilobytes' ./$< 85 @printf 'source_size:\t%8d lines\n' `cat $(CPPVFILES) | wc -l` 86 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CPPVFILES) | fgrep '/***/' -c` 87 @printf 'binary_size:\t%8d bytes\n' `stat -c %s $<` 88 89 run-cfa : cfa-bench 73 90 @echo 74 91 @echo '## Cforall ##' 75 @/usr/bin/time -f 'max_memory:\t %M kilobytes' ./ cfa-bench92 @/usr/bin/time -f 'max_memory:\t %M kilobytes' ./$< 76 93 @printf 'source_size:\t%8d lines\n' `cat $(CFAFILES) | wc -l` 77 94 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CFAFILES) | fgrep '/***/' -c` 78 @printf 'binary_size:\t%8d bytes\n' `stat -c %s cfa-bench`95 @printf 'binary_size:\t%8d bytes\n' `stat -c %s $<` 79 96 80 run-cpp: cpp-bench 81 @echo 82 @echo '## C++ ##' 83 @/usr/bin/time -f 'max_memory:\t %M kilobytes' ./cpp-bench 84 @printf 'source_size:\t%8d lines\n' `cat $(CPPFILES) | wc -l` 85 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CPPFILES) | fgrep '/***/' -c` 86 @printf 'binary_size:\t%8d bytes\n' `stat -c %s cpp-bench` 87 88 run-cppv: cpp-vbench 89 @echo 90 @echo '## C++obj ##' 91 @/usr/bin/time -f 'max_memory:\t%M kilobytes' ./cpp-vbench 92 @printf 'source_size:\t%8d lines\n' `cat $(CPPVFILES) | wc -l` 93 @printf 'redundant_type_annotations:%8d lines\n' `cat $(CPPVFILES) | fgrep '/***/' -c` 94 @printf 'binary_size:\t%8d bytes\n' `stat -c %s cpp-vbench` 95 96 run: run-c run-cfa run-cpp run-cppv 97 98 # so make doesn't fail without dependency files 99 %.d: ; 100 101 # so make won't delete dependency files 102 .PRECIOUS: %.d 103 104 # include dependency files 105 -include: $(COBJS:.o=.d) 106 -include: $(CPPOBJS:.o=.d) 107 -include: $(CFAOBJS:.o=.d) 108 -include: c-bench.d 109 -include: cpp-bench.d 110 -include: cfa-bench.d 97 run : run-c run-cfa run-cpp run-cppv
Note: See TracChangeset
for help on using the changeset viewer.