From 0c47a902f5c8bda66ffcc909a817bf50a9c3be1d Mon Sep 17 00:00:00 2001 From: Evghenii Date: Fri, 31 Jan 2014 20:20:46 +0100 Subject: [PATCH] added llvm compilation --- examples_ptx/mergeSort/Makefile_gpu | 2 +- examples_ptx/nbody/nbody.ispc | 2 +- examples_ptx/radixSort/Makefile_gpu | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples_ptx/mergeSort/Makefile_gpu b/examples_ptx/mergeSort/Makefile_gpu index 9ed753a4..1532838a 100644 --- a/examples_ptx/mergeSort/Makefile_gpu +++ b/examples_ptx/mergeSort/Makefile_gpu @@ -6,7 +6,7 @@ PTXCC_REGMAX=64 #PTXCC_FLAGS= -Xptxas=-O3 #NVCC_FLAGS=-Xptxas=-O0 -# LLVM_GPU=1 +LLVM_GPU=1 NVVM_GPU=1 include ../common_gpu.mk diff --git a/examples_ptx/nbody/nbody.ispc b/examples_ptx/nbody/nbody.ispc index 3b988a6a..3dda9f51 100644 --- a/examples_ptx/nbody/nbody.ispc +++ b/examples_ptx/nbody/nbody.ispc @@ -184,7 +184,7 @@ void nbodyIntegrate( { uniform int nTasks = num_cores()*4; #ifdef __NVPTX__ - nTasks = (nbodies + 4*programCount - 1)/(4*programCount); + nTasks = (nbodies + programCount - 1)/(programCount); #endif assert((nbodies % nTasks) == 0); diff --git a/examples_ptx/radixSort/Makefile_gpu b/examples_ptx/radixSort/Makefile_gpu index 2e08ab98..03e2490f 100644 --- a/examples_ptx/radixSort/Makefile_gpu +++ b/examples_ptx/radixSort/Makefile_gpu @@ -6,7 +6,7 @@ CU_SRC=radixSort.cu CXX_SRC=radixSort.cpp radixSort.cpp PTXCC_REGMAX=64 -# LLVM_GPU=1 +LLVM_GPU=1 NVVM_GPU=1 include ../common_gpu.mk