refactor ihipPreLaunchKernel phase#1
- Fix calls to HIP_INIT_API to pass all function arguments.
- Change ihipFunction to follow coding convention:
- leading underscore for member fields,
- camelCase for member fields.
- move kernel print function inside ihipPreLaunchKernel.
- add HIP_TRACE_API_COLOR, control color of messages.
- add ihipLogStatus wrapper to hipDeviceSynchronize()
Change-Id: I20bbb644da213f821404648945197254e3648fc9
Tento commit je obsažen v:
@@ -38,7 +38,7 @@ __global__ void vAdd(hipLaunchParm lp, float *a){}
|
||||
cmd;\
|
||||
hipDeviceSynchronize();\
|
||||
gettimeofday(&stop, NULL);\
|
||||
} while(0);
|
||||
} while(0);
|
||||
|
||||
|
||||
|
||||
@@ -61,7 +61,9 @@ int main()
|
||||
{
|
||||
float *Ad;
|
||||
hipMalloc((void**)&Ad, 1024);
|
||||
hipLaunchKernel(vAdd, 1024, 1, 0, 0, Ad);
|
||||
|
||||
// Test the different hipLaunchParm options:
|
||||
hipLaunchKernel(vAdd, size_t(1024), 1, 0, 0, Ad);
|
||||
hipLaunchKernel(vAdd, 1024, dim3(1), 0, 0, Ad);
|
||||
hipLaunchKernel(vAdd, dim3(1024), 1, 0, 0, Ad);
|
||||
hipLaunchKernel(vAdd, dim3(1024), dim3(1), 0, 0, Ad);
|
||||
|
||||
Odkázat v novém úkolu
Zablokovat Uživatele