Replace hipLaunchKernel -> hipLaunchKernelGGL
Change-Id: I4d99009e1199811d417becf1e1b934ec4d4e30be
Este cometimento está contido em:
@@ -434,7 +434,7 @@ class KernelCommand : public Command {
|
||||
|
||||
switch (_kind) {
|
||||
case Null:
|
||||
hipLaunchKernel(NullKernel, dim3(gridX / groupX), dim3(gridX), 0, _stream, nullptr);
|
||||
hipLaunchKernelGGL(NullKernel, dim3(gridX / groupX), dim3(gridX), 0, _stream, nullptr);
|
||||
break;
|
||||
case VectorAdd:
|
||||
assert(0); // TODO
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#include "hip/hip_runtime.h"
|
||||
|
||||
extern "C" __global__ void NullKernel(hipLaunchParm lp, float* Ad) {
|
||||
extern "C" __global__ void NullKernel(float* Ad) {
|
||||
if (Ad) {
|
||||
Ad[0] = 42;
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
static const int BLOCKSIZEX = 32;
|
||||
static const int BLOCKSIZEY = 16;
|
||||
|
||||
__global__ void fails(hipLaunchParm lp, float* pErrorI) {
|
||||
__global__ void fails(float* pErrorI) {
|
||||
if (pErrorI != 0) {
|
||||
pErrorI[0] = 1;
|
||||
}
|
||||
@@ -14,5 +14,5 @@ int main() {
|
||||
dim3 threads(BLOCKSIZEX, BLOCKSIZEY);
|
||||
float error;
|
||||
|
||||
hipLaunchKernel(HIP_KERNEL_NAME(fails), blocks, threads, 0, 0, &error);
|
||||
hipLaunchKernelGGL(HIP_KERNEL_NAME(fails), blocks, threads, 0, 0, &error);
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ const unsigned p_tests = 0xfffffff;
|
||||
|
||||
|
||||
// HCC optimizes away fully NULL kernel calls, so run one that is nearly null:
|
||||
__global__ void NearlyNull(hipLaunchParm lp, float* Ad) {
|
||||
__global__ void NearlyNull(float* Ad) {
|
||||
if (Ad) {
|
||||
Ad[0] = 42;
|
||||
}
|
||||
@@ -94,14 +94,14 @@ int main() {
|
||||
|
||||
if (p_tests & 0x1) {
|
||||
hipEventRecord(start);
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
stopTest(start, stop, "FirstKernelLaunch", 1);
|
||||
}
|
||||
|
||||
|
||||
if (p_tests & 0x2) {
|
||||
hipEventRecord(start);
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
stopTest(start, stop, "SecondKernelLaunch", 1);
|
||||
}
|
||||
|
||||
@@ -110,7 +110,7 @@ int main() {
|
||||
for (int t = 0; t < TEST_ITERS; t++) {
|
||||
hipEventRecord(start);
|
||||
for (int i = 0; i < DISPATCHES_PER_TEST; i++) {
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
hipEventRecord(sync);
|
||||
hipEventSynchronize(sync);
|
||||
}
|
||||
@@ -123,7 +123,7 @@ int main() {
|
||||
for (int t = 0; t < TEST_ITERS; t++) {
|
||||
hipEventRecord(start);
|
||||
for (int i = 0; i < DISPATCHES_PER_TEST; i++) {
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream, Ad);
|
||||
hipEventRecord(sync);
|
||||
hipEventSynchronize(sync);
|
||||
}
|
||||
@@ -137,7 +137,7 @@ int main() {
|
||||
for (int t = 0; t < TEST_ITERS; t++) {
|
||||
hipEventRecord(start);
|
||||
for (int i = 0; i < DISPATCHES_PER_TEST; i++) {
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream0, Ad);
|
||||
}
|
||||
stopTest(start, stop, "NullStreamASyncDispatchNoWait", DISPATCHES_PER_TEST);
|
||||
}
|
||||
@@ -147,7 +147,7 @@ int main() {
|
||||
for (int t = 0; t < TEST_ITERS; t++) {
|
||||
hipEventRecord(start);
|
||||
for (int i = 0; i < DISPATCHES_PER_TEST; i++) {
|
||||
hipLaunchKernel(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream, Ad);
|
||||
hipLaunchKernelGGL(NearlyNull, dim3(NUM_GROUPS), dim3(GROUP_SIZE), 0, stream, Ad);
|
||||
}
|
||||
stopTest(start, stop, "StreamASyncDispatchNoWait", DISPATCHES_PER_TEST);
|
||||
}
|
||||
|
||||
Criar uma nova questão referindo esta
Bloquear um utilizador