summaryrefslogtreecommitdiff
path: root/expt_0501.cu
diff options
context:
space:
mode:
Diffstat (limited to 'expt_0501.cu')
-rw-r--r--expt_0501.cu17
1 files changed, 8 insertions, 9 deletions
diff --git a/expt_0501.cu b/expt_0501.cu
index 7e63ae6..cbcd376 100644
--- a/expt_0501.cu
+++ b/expt_0501.cu
@@ -59,10 +59,10 @@ __global__ void kernel(unsigned long step, const double slice_size,
auto tid = step * (blockIdx.x * blockDim.x + threadIdx.x) + i;
// printf("%d\n", tid);
- auto index = (int)(custom_sort.sample_cdf_custom_version(
- cudaSampleItem, cudaPopulationItem[tid]) /
- slice_size) -
- 1;
+ auto index =
+ (int)(custom_sort.cdf(cudaSampleItem, cudaPopulationItem[tid]) /
+ slice_size) -
+ 1;
// printf("%llu %d\n", cudaPopulationItem[tid], index);
/*if (cdf_result[index]) {
while (cdf_result[++index]) {
@@ -80,11 +80,10 @@ __global__ void kernel2(unsigned long step, const double slice_size) {
for (int i = 0; i < step; i++) {
auto tid = step * (blockIdx.x * blockDim.x + threadIdx.x) + i;
- auto index =
- (int)(FactorySort::sample_cdf(cudaNormalSampleItem, SAMPLE_LENGTH,
- cudaPopulationItem[tid]) /
- slice_size) -
- 1;
+ auto index = (int)(FactorySort::cdf(cudaNormalSampleItem, SAMPLE_LENGTH,
+ cudaPopulationItem[tid]) /
+ slice_size) -
+ 1;
cdf_normal_result[index] = true;
}
}