xref: /petsc/src/benchmarks/makefile (revision d71ae5a4db6382e7f06317b8d368875286fe9008)
1-include ../../petscdir.mk
2
3ALL:
4
5LOCDIR    = src/benchmarks/
6MANSEC    = Sys
7
8include ${PETSC_DIR}/lib/petsc/conf/variables
9include ${PETSC_DIR}/lib/petsc/conf/rules
10include ${PETSC_DIR}/lib/petsc/conf/test
11
12PetscTime: PetscTime.o
13	-${CLINKER} -o PetscTime PetscTime.o ${PETSC_LIB}
14	${RM} -f PetscTime.o
15
16PetscGetTime: PetscGetTime.o
17	-${CLINKER} -o PetscGetTime PetscGetTime.o ${PETSC_LIB}
18	${RM} -f PetscGetTime.o
19
20PetscGetCPUTime: PetscGetCPUTime.o
21	-${CLINKER} -o PetscGetCPUTime PetscGetCPUTime.o ${PETSC_LIB}
22	${RM} -f PetscGetCPUTime.o
23
24MPI_Wtime: MPI_Wtime.o
25	-${CLINKER} -o MPI_Wtime MPI_Wtime.o ${PETSC_LIB}
26	${RM} -f MPI_Wtime.o
27
28PLogEvent: PLogEvent.o
29	-${CLINKER} -o PLogEvent PLogEvent.o ${PETSC_LIB}
30	${RM} -f PLogEvent.o
31
32PetscMalloc: PetscMalloc.o
33	-${CLINKER} -o PetscMalloc PetscMalloc.o ${PETSC_LIB}
34	${RM} -f PetscMalloc.o
35
36PetscMemcpy: PetscMemcpy.o
37	-${CLINKER} -o PetscMemcpy PetscMemcpy.o ${PETSC_LIB}
38	${RM} -f PetscMemcpy.o
39
40PetscMemzero: PetscMemzero.o
41	-${CLINKER} -o PetscMemzero PetscMemzero.o ${PETSC_LIB}
42	${RM} -f PetscMemzero.o
43
44PetscMemcmp: PetscMemcmp.o
45	-${CLINKER} -o PetscMemcmp PetscMemcmp.o ${PETSC_LIB}
46	${RM} -f PetscMemcmp.o
47
48Index: Index.o
49	-${CLINKER} -o Index Index.o ${PETSC_LIB}
50	${RM} -f Index.o
51
52PetscVecNorm: PetscVecNorm.o
53	-${CLINKER} -o PetscVecNorm PetscVecNorm.o ${PETSC_LIB}
54	${RM} -f PetscVecNorm.o
55
56sizeof: sizeof.o
57	-${CLINKER} -o sizeof sizeof.o ${PETSC_LIB}
58	${RM} -f sizeof.o
59
60test: ${TESTS}
61
62runtest:
63	-@echo "Time Taken by some PETSc routines are as follows:"
64	-@echo "------------------------------------------------"
65	-@${MPIEXEC} -n 1 ./PetscTime
66	-@${MPIEXEC} -n 1 ./PetscGetTime
67	-@${MPIEXEC} -n 1 ./PetscGetCPUTime
68	-@${MPIEXEC} -n 1 ./MPI_Wtime
69	-@echo " "
70	-@echo "PLogEventBegin and PLogEventEnd together with options"
71	-@echo "------------------------------------------------"
72	-@${MPIEXEC} -n 1 ./PLogEvent              > /dev/null
73	-@${MPIEXEC} -n 1 ./PLogEvent -log_view > /dev/null
74	-@${MPIEXEC} -n 1 ./PLogEvent -log_mpe     > /dev/null
75	-@echo " "
76	-@echo "PetscMalloc and PetscFree together  with options"
77	-@echo "------------------------------------------------"
78	-@${MPIEXEC} -n 1 ./PetscMalloc
79	-@${MPIEXEC} -n 1 ./PetscMalloc -malloc
80	-@echo " "
81	-@echo "Memory Operations "
82	-@echo "------------------------------------------------"
83	-@${MPIEXEC} -n 1 ./PetscMemcpy
84	-@${MPIEXEC} -n 1 ./PetscMemzero
85	-@${MPIEXEC} -n 1 ./PetscMemcmp
86	-@echo " "
87	-@echo "Memory Operations "
88	-@echo "------------------------------------------------"
89	-@${MPIEXEC} -n 1 ./Index
90	-@echo " "
91	-@echo "Datatype Sizes "
92	-@echo "------------------------------------------------"
93	-@${MPIEXEC} -n 1 ./sizeof
94	-@echo "------------------------------------------------"
95