From 3c1104d65e4d196fba60b90e410251065401d69d Mon Sep 17 00:00:00 2001 From: denghuilu Date: Tue, 12 Apr 2022 23:15:17 +0800 Subject: [PATCH 1/2] fix compilation error while in a ROCm environment --- source/lib/src/rocm/tabulate.hip.cu | 9 --------- 1 file changed, 9 deletions(-) diff --git a/source/lib/src/rocm/tabulate.hip.cu b/source/lib/src/rocm/tabulate.hip.cu index 4152668dfc..0354bc68b3 100644 --- a/source/lib/src/rocm/tabulate.hip.cu +++ b/source/lib/src/rocm/tabulate.hip.cu @@ -524,15 +524,6 @@ __global__ void tabulate_fusion_se_r_grad_fifth_order_polynomial( int warp_idx = __shfl(threadIdx.x / 64, 0); int lane_idx = threadIdx.x % 64; - bool unloop = false; - FPTYPE * iteratorA = (FPTYPE *)&_data[0]; // dy - for (int ii = 0; ii < MTILE; ii++) { - for (int jj = thread_idx; jj < last_layer_size; jj += blockDim.x) { - iteratorA[ii * last_layer_size + jj] = ; - } - } - __syncthreads(); - for (int ii = 0; ii < nnei; ii += KTILE) { FPTYPE xx = em[block_idx * nnei + ii + warp_idx]; From 97c99e62d9f19285b68a834ee57dc7a0a084db03 Mon Sep 17 00:00:00 2001 From: denghuilu Date: Wed, 13 Apr 2022 23:30:15 +0800 Subject: [PATCH 2/2] fix error of variable declaration --- source/lib/tests/test_tabulate_se_r.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/lib/tests/test_tabulate_se_r.cc b/source/lib/tests/test_tabulate_se_r.cc index 6cc59b02d1..b7173b0123 100644 --- a/source/lib/tests/test_tabulate_se_r.cc +++ b/source/lib/tests/test_tabulate_se_r.cc @@ -170,7 +170,7 @@ TEST_F(TestTabulateSeR, tabulate_fusion_se_r_grad_gpu_rocm) std::vector dy_dem(em.size(), 0.0); std::vector dy(nloc * nnei * last_layer_size, 1.0); - * dy_dem_dev = NULL, * table_dev = NULL, * em_dev = NULL, * dy_dev = NULL; + double * dy_dem_dev = NULL, * table_dev = NULL, * em_dev = NULL, * dy_dev = NULL; deepmd::malloc_device_memory_sync(dy_dem_dev, dy_dem); deepmd::malloc_device_memory_sync(table_dev, table); deepmd::malloc_device_memory_sync(em_dev, em);