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