Skip to content

Conversation

@PietroGhg
Copy link
Contributor


std::vector<bool> res;
res.push_back(test<int>(q));
res.push_back(test<unsigned>(q));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Performance. Using a vector here likely causes allocations and there's the overhead of iterating over the vector.
It's probably faster to instead check the test values and return straight away if there's an error.

const T test{42};

myQueue.submit([&](handler &cgh) {
auto A = a.template get_access<access::mode::write>(cgh);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be worth replicating this test also for access::mode::read_write to see if timing/events handling is correct for different access modes.

@PietroGhg
Copy link
Contributor Author

@intel/llvm-gatekeepers this looks ready to merge, thank you

@sommerlukas sommerlukas merged commit 51d92a3 into intel:sycl Nov 13, 2024
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants