Skip to content

[SYCL][Graph] Add new 'are_graphs_supported' helper function #11877

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
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
5 changes: 4 additions & 1 deletion sycl/test-e2e/Graph/Explicit/add_node_while_recording.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand All @@ -14,6 +13,10 @@
int main() {
queue Queue{{sycl::ext::intel::property::queue::no_immediate_command_list{}}};

if (!are_graphs_supported(Queue)) {
return 0;
}

bool Success = false;

exp_ext::command_graph Graph{Queue.get_context(), Queue.get_device()};
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_buffer.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_usm.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_usm_host.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_usm_mixed.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_usm_shared.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/basic_usm_system.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_copy.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_copy_2d.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_copy_host2target.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_copy_offsets.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_copy_target2host.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/buffer_ordering.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
5 changes: 4 additions & 1 deletion sycl/test-e2e/Graph/Explicit/cycle_error.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out

Expand All @@ -17,6 +16,10 @@ void CreateGraphWithCyclesTest(bool DisableCycleChecks) {

queue Queue;

if (!are_graphs_supported(Queue)) {
return;
}

property_list Props;

if (DisableCycleChecks) {
Expand Down
6 changes: 2 additions & 4 deletions sycl/test-e2e/Graph/Explicit/debug_print_graph.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
// REQUIRES: level_zero || cuda, gpu
// RUN: %{build} -o %t.out
// RUN: %if linux %{ %{run} %t.out ; FileCheck %s --input-file graph.dot %}
// RUN: %if windows %{ %{run} %t.out %}
// RUN: %if linux && (ext_oneapi_level_zero || ext_oneapi_cuda) %{ %{run} %t.out ; FileCheck %s --input-file graph.dot %} %else %{ %{run} %t.out %}
// Windows output format differs from linux format.
// The filecheck-based output checking is suited to linux standards.
// On Windows, we only test that printing takes place correctly and does not
// trigger errors or throw execeptions.
// trigger errors or throw exceptions.
//
// CHECK: digraph dot {
// CHECK-NEXT: "0x[[#%x,NODE1:]]"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
// REQUIRES: level_zero || cuda, gpu
// RUN: %{build} -o %t.out
// RUN: %if linux %{ %{run} %t.out ; FileCheck %s --input-file graph_verbose.dot %}
// RUN: %if windows %{ %{run} %t.out %}
// RUN: %if linux && (ext_oneapi_level_zero || ext_oneapi_cuda) %{ %{run} %t.out ; FileCheck %s --input-file graph_verbose.dot %} %else %{ %{run} %t.out %}
// Windows output format differs from linux format.
// The filecheck-based output checking is suited to linux standards.
// On Windows, we only test that printing takes place correctly and does not
Expand Down
6 changes: 4 additions & 2 deletions sycl/test-e2e/Graph/Explicit/depends_on.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand All @@ -13,9 +12,12 @@
#include "../graph_common.hpp"

int main() {

queue Queue{{sycl::ext::intel::property::queue::no_immediate_command_list{}}};

if (!are_graphs_supported(Queue)) {
return 0;
}

exp_ext::command_graph Graph{Queue.get_context(), Queue.get_device()};

const size_t N = 10;
Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/dotp_buffer_reduction.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as reduction support is not complete.
// XFAIL: *
// Skip as reduction support is not complete.
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/dotp_usm_reduction.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as reduction support is not complete.
// XFAIL: *
// Skip as reduction support is not complete.
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/double_buffer.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as executable graph update isn't implemented yet
// XFAIL: *
// Skip as executable graph update isn't implemented yet
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/empty_node.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
6 changes: 4 additions & 2 deletions sycl/test-e2e/Graph/Explicit/enqueue_ordering.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand All @@ -12,9 +11,12 @@

#include "../graph_common.hpp"
int main() {

queue Queue{{sycl::ext::intel::property::queue::no_immediate_command_list{}}};

if (!are_graphs_supported(Queue)) {
return 0;
}

exp_ext::command_graph Graph{Queue.get_context(), Queue.get_device()};

const size_t N = 10;
Expand Down
3 changes: 1 addition & 2 deletions sycl/test-e2e/Graph/Explicit/event_status_querying.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
// REQUIRES: level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out 2>&1 | FileCheck %s
// RUN: %if ext_oneapi_level_zero || ext_oneapi_cuda %{ %{run} %t.out 2>&1 | FileCheck %s %} %else %{ %{run} %t.out %}
//
// CHECK: complete
//
Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/executable_graph_update.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as executable graph update not implemented yet
// XFAIL: *
// Skip as executable graph update not implemented yet
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as executable graph update and host tasks both aren't
// Skip as executable graph update and host tasks both aren't
// implemented.
// XFAIL: *
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/host_task.cpp
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as host tasks aren't implemented yet.
// XFAIL: *
// Skip as host tasks aren't implemented yet.
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/kernel_bundle.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %if ext_oneapi_cuda %{ %{run} %t.out %}
// RUN: %if ext_oneapi_level_zero %{env SYCL_PI_TRACE=2 %{run} %t.out | FileCheck %s %}
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/multiple_exec_graphs.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/multiple_kernel_bundles.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
6 changes: 4 additions & 2 deletions sycl/test-e2e/Graph/Explicit/node_ordering.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand All @@ -12,9 +11,12 @@
#include "../graph_common.hpp"

int main() {

queue Queue{{sycl::ext::intel::property::queue::no_immediate_command_list{}}};

if (!are_graphs_supported(Queue)) {
return 0;
}

exp_ext::command_graph Graph{Queue.get_context(), Queue.get_device()};

const size_t N = 10;
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/queue_shortcuts.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/repeated_exec.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
6 changes: 4 additions & 2 deletions sycl/test-e2e/Graph/Explicit/single_node.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand All @@ -11,9 +10,12 @@
#include "../graph_common.hpp"

int main() {

queue Queue{{sycl::ext::intel::property::queue::no_immediate_command_list{}}};

if (!are_graphs_supported(Queue)) {
return 0;
}

exp_ext::command_graph Graph{Queue.get_context(), Queue.get_device()};

const size_t N = 10;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
5 changes: 2 additions & 3 deletions sycl/test-e2e/Graph/Explicit/stream.cpp
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out %GPU_CHECK_PLACEHOLDER
// RUN: %if ext_oneapi_level_zero %{env ZE_DEBUG=4 %{run} %t.out %GPU_CHECK_PLACEHOLDER 2>&1 | FileCheck %s %}
//
// CHECK-NOT: LEAK

// Expected fail as sycl streams aren't implemented yet
// XFAIL: *
// Skip as sycl streams aren't implemented yet
// REQUIRES: NOT_YET_IMPLEMENTED

#define GRAPH_E2E_EXPLICIT

Expand Down
1 change: 0 additions & 1 deletion sycl/test-e2e/Graph/Explicit/sub_graph.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
// REQUIRES: cuda || level_zero, gpu
// RUN: %{build} -o %t.out
// RUN: %{run} %t.out
// Extra run to check for leaks in Level Zero using ZE_DEBUG
Expand Down
Loading