Replace hipLaunchKernel -> hipLaunchKernelGGL
Change-Id: I4d99009e1199811d417becf1e1b934ec4d4e30be
Этот коммит содержится в:
@@ -39,7 +39,7 @@ THE SOFTWARE.
|
||||
|
||||
#define TEST_DEBUG (0)
|
||||
|
||||
__global__ void kernel_trig(hipLaunchParm lp, float* In, float* sin_d, float* cos_d, float* tan_d,
|
||||
__global__ void kernel_trig(float* In, float* sin_d, float* cos_d, float* tan_d,
|
||||
float* sin_pd, float* cos_pd) {
|
||||
int tid = threadIdx.x + blockIdx.x * blockDim.x;
|
||||
sin_d[tid] = sinf(In[tid]);
|
||||
@@ -74,7 +74,7 @@ int main() {
|
||||
HIP_ASSERT(hipMalloc((void**)&cos_pd, SIZE));
|
||||
|
||||
hipMemcpy(In_d, In, SIZE, hipMemcpyHostToDevice);
|
||||
hipLaunchKernel(kernel_trig, dim3(LEN, 1, 1), dim3(1, 1, 1), 0, 0,
|
||||
hipLaunchKernelGGL(kernel_trig, dim3(LEN, 1, 1), dim3(1, 1, 1), 0, 0,
|
||||
In_d, sin_d, cos_d, tan_d,
|
||||
sin_pd, cos_pd);
|
||||
hipMemcpy(sin_h, sin_d, SIZE, hipMemcpyDeviceToHost);
|
||||
|
||||
Ссылка в новой задаче
Block a user