Closed
Description
The following code causes graph node recording to fail with an in-order queue because the runtime calls handler::depends_on()
for the host-task event which is outside the graph, resulting in an exception being thrown. For device command groups this does not happen as the in-order dependencies are handled by the backend transparently.
// Submit a host-task to an in-order queue
Queue.submit([&](handler &CGH) {
CGH.host_task([=]() {
// Do something in the host task
});
});
// Start recording from that same queue
Graph.begin_recording(Queue);
// Throws here
Queue.submit([&](handler &CGH) {
CGH.single_task<class TestKernel2>([=]() {
});
});