diff options
| author | Tor Aamodt <[email protected]> | 2010-07-15 18:09:46 -0800 |
|---|---|---|
| committer | Tor Aamodt <[email protected]> | 2010-07-15 18:09:46 -0800 |
| commit | 69f2911e04ffb1b19eef1fafb8c040af271f656e (patch) | |
| tree | 231d3b6bdc3a202f7c255bfcf7bf2c36e32cee9e /benchmarks/CUDA/CP/common/mk/cuda_rules.mk | |
creating branch for adding support for CUDA 3.x and Fermi
[git-p4: depot-paths = "//depot/gpgpu_sim_research/fermi/distribution/": change = 6829]
Diffstat (limited to 'benchmarks/CUDA/CP/common/mk/cuda_rules.mk')
| -rw-r--r-- | benchmarks/CUDA/CP/common/mk/cuda_rules.mk | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/benchmarks/CUDA/CP/common/mk/cuda_rules.mk b/benchmarks/CUDA/CP/common/mk/cuda_rules.mk new file mode 100644 index 0000000..ce2f5da --- /dev/null +++ b/benchmarks/CUDA/CP/common/mk/cuda_rules.mk @@ -0,0 +1,30 @@ +# (c) 2007 The Board of Trustees of the University of Illinois. + +# Cuda-related rules common to all benchmarks + +######################################## +# Derived variables +######################################## + +CUDAOBJS = $(call INBUILDDIR,$(SRCDIR_CUDAOBJS)) + +######################################## +# Rules +######################################## + +ifeq ("$(LINK_MODE)", "CUDA") +$(BIN) : $(OBJS) $(CUDAOBJS) + $(CUDACC) $(CUDALDFLAGS) $^ -o $@ $(CUDALIBS) +endif + +$(BUILDDIR)/%.o : $(SRCDIR)/%.cu + mkdir -p $(BUILDDIR) + $(CUDACC) $(CUDACFLAGS) -c $< -o $@ + +$(BUILDDIR)/%.ptx : $(SRCDIR)/%.cu + mkdir -p $(BUILDDIR) + $(CUDACC) $(CUDACFLAGS) -ptx $< -o $@ + +$(BUILDDIR)/%.cubin : $(SRCDIR)/%.cu + mkdir -p $(BUILDDIR) + $(CUDACC) $(CUDACFLAGS) -cubin $< -o $@ |
