diff --git a/Makefile b/Makefile index 10fc9f3e..a46c691a 100644 --- a/Makefile +++ b/Makefile @@ -133,21 +133,24 @@ TESTSSRCS := $(addprefix $(TESTSDIR)/,bootstrap_test.cc allgather_test.cu) TESTSOBJS := $(patsubst %.cc,%.o,$(TESTSSRCS)) $(patsubst %.cu,%.o,$(TESTSSRCS)) TESTSOBJTARGETS := $(TESTSOBJS:%=$(BUILDDIR)/$(OBJDIR)/%) TESTSBINS := $(patsubst %.o,$(BUILDDIR)/$(BINDIR)/%,$(TESTSOBJS)) -TESTSPERFBIN := $(BUILDDIR)/$(BINDIR)/allgather_test3 + +MSCLLPPTESTSOBJSDIR:= $(BUILDDIR)/$(OBJDIR)/$(TESTSDIR) +MSCLLPPTESTBINFILESLIST := allgather_test3 +MSCLLPPTESTBINS := $(MSCLLPPTESTBINFILESLIST:%=$(BUILDDIR)/$(BINDIR)/$(TESTSDIR)/%_perf) INCLUDE := -Isrc -Isrc/include -.PHONY: all build lib tests clean +.PHONY: all build lib tests mscclpp_test clean all: build -build: lib tests +build: lib tests mscclpp_test lib: $(LIBOBJTARGETS) $(INCTARGETS) $(LIBTARGET) tests: $(TESTSBINS) -allgather_perf: $(TESTSPERFBIN) +mscclpp_test: $(LIBTARGET) $(MSCLLPPTESTBINS) cpplint: clang-format-12 -style=file --verbose --Werror --dry-run $(CPPSOURCES) @@ -175,9 +178,6 @@ $(LIBTARGET): $(LIBOBJTARGETS) ln -sf $(LIBTARGET) $(BUILDDIR)/$(LIBDIR)/$(LIBSONAME) # Compile .cc tests -$(TESTSPERFBIN): $(BUILDDIR)/$(OBJDIR)/$(TESTSDIR)/allgather_test3.o $(BUILDDIR)/$(OBJDIR)/$(TESTSDIR)/common.o $(BUILDDIR)/$(OBJDIR)/$(TESTSDIR)/timer.o - $(NVCC) -o $@ $^ $(MPI_LDFLAGS) -L$(BUILDDIR)/$(LIBDIR) -lmscclpp - $(BUILDDIR)/$(OBJDIR)/$(TESTSDIR)/%.o: $(TESTSDIR)/%.cc $(INCTARGETS) @mkdir -p $(@D) $(CXX) -o $@ -I$(BUILDDIR)/$(INCDIR) $(MPI_INC) $(CXXFLAGS) -c $< $(MPI_MACRO) @@ -192,5 +192,10 @@ $(BUILDDIR)/$(BINDIR)/%: $(BUILDDIR)/$(OBJDIR)/%.o $(LIBTARGET) @mkdir -p $(@D) $(NVCC) -o $@ $< $(MPI_LDFLAGS) -L$(BUILDDIR)/$(LIBDIR) -lmscclpp +# Comile mscclpp_test +$(BUILDDIR)/$(BINDIR)/$(TESTSDIR)/%_perf: $(MSCLLPPTESTSOBJSDIR)/%.o $(MSCLLPPTESTSOBJSDIR)/common.o $(MSCLLPPTESTSOBJSDIR)/timer.o + @mkdir -p $(@D) + $(NVCC) -o $@ $^ $(MPI_LDFLAGS) -L$(BUILDDIR)/$(LIBDIR) -lmscclpp + clean: rm -rf $(BUILDDIR) diff --git a/tests/common.cu b/tests/common.cu index 4343c181..4c819c98 100644 --- a/tests/common.cu +++ b/tests/common.cu @@ -30,13 +30,13 @@ static size_t stepBytes = 1*1024*1024; static size_t stepFactor = 1; static int datacheck = 1; static int warmup_iters = 10; -static int iters = 20; +static int iters = 100; static int timeout = 0; static int report_cputime = 0; // Report average iteration time: (0=RANK0,1=AVG,2=MIN,3=MAX) static int average = 1; static std::string ip_port; -static int cudaGraphLaunches = 10; +static int cudaGraphLaunches = 15; #define NUM_BLOCKS 32