Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ struct BasicMutableCommandBufferTest : BasicCommandBufferTest
clUpdateMutableCommandsKHR_fn clUpdateMutableCommandsKHR = nullptr;

const char* kernelString = "__kernel void empty() {}";
const size_t global_work_size = 4 * 16;
const size_t global_work_size = 256 * 1024;
};

struct InfoMutableCommandBufferTest : BasicMutableCommandBufferTest
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,9 +153,9 @@ struct MutableDispatchGlobalSize : public InfoMutableCommandBufferTest
}

size_t info_global_size = 0;
const size_t update_global_size = 3;
const size_t sizeToAllocate = global_work_size;
const size_t num_elements = sizeToAllocate / sizeof(cl_int);
const size_t update_global_size = 16 * 1024;
const size_t sizeToAllocate = global_work_size * sizeof(cl_int);
const size_t num_elements = global_work_size;
cl_mutable_command_khr command = nullptr;
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,10 @@ struct PropertiesArray : public InfoMutableCommandBufferTest
virtual bool Skip() override
{
Version device_version = get_device_cl_version(device);
if (InfoMutableCommandBufferTest::Skip()) return true;
if ((device_version >= Version(3, 0))
|| is_extension_available(device, "cl_khr_extended_versioning"))
{

cl_version extension_version = get_extension_version(
device, "cl_khr_command_buffer_mutable_dispatch");

Expand All @@ -132,7 +132,17 @@ struct PropertiesArray : public InfoMutableCommandBufferTest
return true;
}
}
return InfoMutableCommandBufferTest::Skip();

cl_mutable_dispatch_fields_khr mutable_capabilities;
cl_int error = clGetDeviceInfo(
device, CL_DEVICE_MUTABLE_DISPATCH_CAPABILITIES_KHR,
sizeof(mutable_capabilities), &mutable_capabilities, nullptr);
test_error(error, "clGetDeviceInfo failed");

if ((mutable_capabilities & CL_MUTABLE_DISPATCH_ARGUMENTS_KHR) == 0)
return true;

return false;
}

cl_int Run() override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -278,10 +278,9 @@ struct MutableDispatchWorkGroups : public BasicMutableCommandBufferTest
Configuration config;

size_t info_global_size = 0;
static constexpr size_t test_global_work_size = 64;
static constexpr size_t update_global_size = 16;
static constexpr size_t update_global_size = 16 * 1024;
const size_t local_work_size = 8;
const size_t sizeToAllocate = 64 * sizeof(cl_int);
const size_t sizeToAllocate = global_work_size * sizeof(cl_int);
};

int test_command_buffer_with_no_additional_work_groups(cl_device_id device,
Expand Down