xref: /petsc/src/benchmarks/makefile (revision d4bb536f0e426e9a0292bbfd5743770a9b03f0d5)
1# $Id: makefile,v 1.179 1997/08/15 16:24:04 bsmith Exp bsmith $
2
3ALL:
4
5CFLAGS	      =	 $(CPPFLAGS) -D__SDIR__='"$(LOCDIR)"' $(CONF)
6FFLAGS	      =
7SOURCEC	      =
8SOURCEF	      =
9SOURCEH	      =
10OBJSC	      =
11OBJSF	      =
12LIBBASE	      = libpetscsys
13LOCDIR        = src/benchmarks/
14EXAMPLES_1    =
15RUNEXAMPLES_1 =
16EXAMPLES_2    =
17RUNEXAMPLES_2 =
18EXAMPLES_3    =
19RUNEXAMPLES_3 =
20EXAMPLES_4    =
21RUNEXAMPLES_4 =
22EXAMPLESC     = PetscTime.c PetscGetTime.c MPI_Wtime.c PLogEvent.c PetscMalloc.c \
23		PetscMemcpy.c PetscMemzero.c PetscMemcmp.c Index.c PetscVecNorm.c \
24		PetscGetCPUTime.c
25EXAMPLESF     =
26TESTS         = PetscTime PetscGetTime MPI_Wtime PLogEvent PetscMalloc \
27		PetscMemcpy PetscMemzero PetscMemcmp Index PetscVecNorm \
28		PetscGetCPUTime
29
30PetscTime: PetscTime.o  chkopts
31	-$(CLINKER) -o PetscTime PetscTime.o $(PETSC_LIB)
32	$(RM) -f PetscTime.o
33
34PetscGetTime: PetscGetTime.o  chkopts
35	-$(CLINKER) -o PetscGetTime PetscGetTime.o $(PETSC_LIB)
36	$(RM) -f PetscGetTime.o
37
38PetscGetCPUTime: PetscGetCPUTime.o  chkopts
39	-$(CLINKER) -o PetscGetCPUTime PetscGetCPUTime.o $(PETSC_LIB)
40	$(RM) -f PetscGetCPUTime.o
41
42MPI_Wtime: MPI_Wtime.o  chkopts
43	-$(CLINKER) -o MPI_Wtime MPI_Wtime.o $(PETSC_LIB)
44	$(RM) -f MPI_Wtime.o
45
46PLogEvent: PLogEvent.o  chkopts
47	-$(CLINKER) -o PLogEvent PLogEvent.o $(PETSC_LIB)
48	$(RM) -f PLogEvent.o
49
50PetscMalloc: PetscMalloc.o  chkopts
51	-$(CLINKER) -o PetscMalloc PetscMalloc.o $(PETSC_LIB)
52	$(RM) -f PetscMalloc.o
53
54PetscMemcpy: PetscMemcpy.o  chkopts
55	-$(CLINKER) -o PetscMemcpy PetscMemcpy.o $(PETSC_LIB)
56	$(RM) -f PetscMemcpy.o
57
58PetscMemzero: PetscMemzero.o  chkopts
59	-$(CLINKER) -o PetscMemzero PetscMemzero.o $(PETSC_LIB)
60	$(RM) -f PetscMemzero.o
61
62PetscMemcmp: PetscMemcmp.o  chkopts
63	-$(CLINKER) -o PetscMemcmp PetscMemcmp.o $(PETSC_LIB)
64	$(RM) -f PetscMemcmp.o
65
66Index: Index.o  chkopts
67	-$(CLINKER) -o Index Index.o $(PETSC_LIB)
68	$(RM) -f Index.o
69
70PetscVecNorm: PetscVecNorm.o  chkopts
71	-$(CLINKER) -o PetscVecNorm PetscVecNorm.o $(PETSC_LIB)
72	$(RM) -f PetscVecNorm.o
73
74test: $(TESTS)
75
76runtest:
77	-@echo "Time Taken by some PETSc routines are as follows:"
78	-@echo "------------------------------------------------"
79	-@$(MPIRUN) -np 1 PetscTime       > /dev/null
80	-@$(MPIRUN) -np 1 PetscGetTime    > /dev/null
81	-@$(MPIRUN) -np 1 PetscGetCPUTime > /dev/null
82	-@$(MPIRUN) -np 1 MPI_Wtime       > /dev/null
83	-@echo " "
84	-@echo "PLogEventBegin and PLogEventEnd together with options"
85	-@echo "------------------------------------------------"
86	-@$(MPIRUN) -np 1 PLogEvent                    > /dev/null
87	-@$(MPIRUN) -np 1 PLogEvent -log               > /dev/null
88	-@$(MPIRUN) -np 1 PLogEvent -log_summary       > /dev/null
89	-@$(MPIRUN) -np 1 PLogEvent -log_all           > /dev/null
90	-@$(MPIRUN) -np 1 PLogEvent -log_mpe           > /dev/null
91	-@$(MPIRUN) -np 1 PLogEvent -log_mpe -log      > /dev/null
92	-@echo " "
93	-@echo "PetscMalloc and PetscFree together  with options"
94	-@echo "------------------------------------------------"
95	-@$(MPIRUN) -np 1 PetscMalloc            > /dev/null
96	-@$(MPIRUN) -np 1 PetscMalloc -trmalloc  > /dev/null
97	-@echo " "
98	-@echo "Memory Operations "
99	-@echo "------------------------------------------------"
100	-@$(MPIRUN) -np 1 PetscMemcpy  > /dev/null
101	-@$(MPIRUN) -np 1 PetscMemzero > /dev/null
102	-@$(MPIRUN) -np 1 PetscMemcmp  > /dev/null
103	-@echo " "
104	-@echo "Memory Operations "
105	-@echo "------------------------------------------------"
106	-@$(MPIRUN) -np 1 Index  > /dev/null
107
108include $(PETSC_DIR)/bmake/$(PETSC_ARCH)/base
109
110