diff --git a/conformance_tests/tools/debug/src/test_debug.cpp b/conformance_tests/tools/debug/src/test_debug.cpp index 47335878c..6b6cc9375 100644 --- a/conformance_tests/tools/debug/src/test_debug.cpp +++ b/conformance_tests/tools/debug/src/test_debug.cpp @@ -1234,15 +1234,17 @@ TEST( } void zetDebugReadWriteRegistersTest::run_read_write_registers_test( - std::vector &devices, bool use_sub_devices) { + std::vector &devices, bool use_sub_devices, + bool test_slm) { for (auto &device : devices) { print_device(device); if (!is_debug_supported(device)) continue; synchro->clear_debugger_signal(); - debugHelper = launch_process(LONG_RUNNING_KERNEL_INTERRUPTED, device, - use_sub_devices); + debug_test_type_t test_type = test_slm ? LONG_RUNNING_KERNEL_INTERRUPTED_SLM + : LONG_RUNNING_KERNEL_INTERRUPTED; + debugHelper = launch_process(test_type, device, use_sub_devices); zet_debug_event_t module_event; attach_and_get_module_event(debugHelper.id(), synchro, device, debugSession, @@ -1381,14 +1383,14 @@ TEST_F( GivenActiveDebugSessionWhenReadingAndWritingRegistersThenValidDataReadAndDataWrittenSuccessfully) { auto driver = lzt::get_default_driver(); auto devices = lzt::get_devices(driver); - run_read_write_registers_test(devices, false); + run_read_write_registers_test(devices, false, true); } TEST_F( zetDebugReadWriteRegistersTest, GivenActiveDebugSessionWhenReadingAndWritingSubDeviceRegistersThenValidDataReadAndDataWrittenSuccessfully) { auto all_sub_devices = lzt::get_all_sub_devices(); - run_read_write_registers_test(all_sub_devices, true); + run_read_write_registers_test(all_sub_devices, true, false); } void zetDebugThreadControlTest::SetUpThreadControl(ze_device_handle_t &device, diff --git a/conformance_tests/tools/debug/src/test_debug.hpp b/conformance_tests/tools/debug/src/test_debug.hpp index c3ad19ec4..93d20125e 100644 --- a/conformance_tests/tools/debug/src/test_debug.hpp +++ b/conformance_tests/tools/debug/src/test_debug.hpp @@ -16,8 +16,8 @@ namespace fs = boost::filesystem; namespace bp = boost::process; namespace bi = boost::interprocess; -const uint16_t eventsTimeoutMS = 30000; -const uint16_t eventsTimeoutS = 30; +const uint16_t eventsTimeoutMS = 3000000; +const uint16_t eventsTimeoutS = 3600; namespace lzt = level_zero_tests; @@ -254,7 +254,7 @@ class zetDebugReadWriteRegistersTest : public zetDebugMemAccessTest { void SetUp() override { zetDebugMemAccessTest::SetUp(); } void TearDown() override { zetDebugMemAccessTest::TearDown(); } void run_read_write_registers_test(std::vector &devices, - bool use_sub_devices); + bool use_sub_devices, bool test_slm); }; class zetDebugThreadControlTest : public zetDebugBaseSetup { diff --git a/conformance_tests/tools/debug/src/test_debug_helper.cpp b/conformance_tests/tools/debug/src/test_debug_helper.cpp index c1dbc1174..01d706ec3 100644 --- a/conformance_tests/tools/debug/src/test_debug_helper.cpp +++ b/conformance_tests/tools/debug/src/test_debug_helper.cpp @@ -404,7 +404,8 @@ void multiple_modules_created_test(ze_context_handle_t context, } void run_long_kernel(ze_context_handle_t context, ze_device_handle_t device, - process_synchro &synchro, debug_options &options) { + process_synchro &synchro, debug_options &options, + bool test_slm) { auto command_list = lzt::create_command_list(device); auto command_queue = lzt::create_command_queue(device); @@ -426,9 +427,11 @@ void run_long_kernel(ze_context_handle_t context, ze_device_handle_t device, } synchro.wait_for_debugger_signal(); + const char *build_flags = + test_slm ? "-g" : "-g -igc_opts 'VISAOptions=-forcespills'"; auto module = lzt::create_module(device, module_name, ZE_MODULE_FORMAT_IL_SPIRV, - "-g" /* include debug symbols*/, nullptr); + build_flags /* include debug symbols*/, nullptr); auto kernel = lzt::create_function(module, kernel_name); @@ -1219,13 +1222,13 @@ int main(int argc, char **argv) { attach_after_module_destroyed_test(context, device, synchro, options); break; case LONG_RUNNING_KERNEL_INTERRUPTED: - run_long_kernel(context, device, synchro, options); + run_long_kernel(context, device, synchro, options, false); break; case LONG_RUNNING_KERNEL_INTERRUPTED_SLM: options.use_custom_module = true; options.module_name_in = "debug_loop_slm.spv"; options.kernel_name_in = "long_kernel_slm"; - run_long_kernel(context, device, synchro, options); + run_long_kernel(context, device, synchro, options, true); break; case MULTIPLE_THREADS: run_multiple_threads(context, device, synchro, options);