oneapi-src / level-zero-tests

oneAPI Level Zero Conformance & Performance test content
https://spec.oneapi.com/versions/latest/elements/l0/source/index.html
MIT License
47 stars 40 forks source link

Incorrect initial value for invalid_event in negative tests #68

Open JablonskiMateusz opened 2 months ago

JablonskiMateusz commented 2 months ago

Initial value for invalid event in negative test is not specified and can be set to nullptr which is correct value from L0 spec PoV Test: HandleTests.GivenCompleteApplicationWhenHandleTrackingEnabledThenHandleTrackingCatchesCoreErrors

https://github.com/oneapi-src/level-zero-tests/blame/master/negative_tests/core/test_handle_tracking/src/test_handle_tracking_errors.cpp#L130

That causes random test behavior

Thread 1 "test_handle_tra" hit Breakpoint 1, zeCommandListAppendMemoryCopy (hCommandList=0x1dc1b38, dstptr=0xff00fffffffe0000, srcptr=0xfffffff7c00000, size=8192, hSignalEvent=0x0, numWaitEvents=0, phWaitEvents=0x0) at ../level-zero/source/lib/ze_libapi.cpp:2332
2332    ../level-zero/source/lib/ze_libapi.cpp: No such file or directory.
(gdb) c
Continuing.

Thread 1 "test_handle_tra" hit Breakpoint 1, validation_layer::zeCommandListAppendMemoryCopy (hCommandList=0x1dc1b38, dstptr=0xff00fffffffe0000, srcptr=0xfffffff7c00000, size=8192, hSignalEvent=0x0, numWaitEvents=0, phWaitEvents=0x0) at ../level-zero/source/layers/validation/ze_valddi.cpp:2172
2172    ../level-zero/source/layers/validation/ze_valddi.cpp: No such file or directory.
(gdb) c
Continuing.
../negative_tests/core/test_handle_tracking/src/test_handle_tracking_errors.cpp:269: Failure
Expected equality of these values:
  ZE_RESULT_ERROR_INVALID_NULL_HANDLE
  zeCommandListAppendMemoryCopy(command_list, buffer_b, buffer_a, size, invalid_event, 0, nullptr)
    Which is: ZE_RESULT_SUCCESS
[  FAILED  ] HandleTests.GivenCompleteApplicationWhenHandleTrackingEnabledThenHandleTrackingCatchesCoreErrors (424732 ms)