Skip to content
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

layers: Remove workaround for handling missing signals #8546

Conversation

artem-lunarg
Copy link
Contributor

@artem-lunarg artem-lunarg commented Sep 16, 2024

Closes #8461

Discussed with @jeremy-lunarg @jeremyg-lunarg reverted commit. PreRecord guarantees that any dependent PostRecord will see registered signals/waits in semaphore state object. There is a code that relies on this (when retiring non-external semaphore wait, there should be a signal).

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257255.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17476 running.

// In the correct program the resolving signal is the next signal on the timeline,
// otherwise this violates the rule of strictly increasing signal values.
const TimePoint *timepoint = nullptr;
for (auto it = timeline_.find(payload); it != timeline_.end(); ++it) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Just realized this loop is basically what we had before, just with a placeholder to add error reporting later (probably not for the ongoing SDK). The main difference is removed workaround.

@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from 21cc26a to 49069a5 Compare September 16, 2024 17:54
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257334.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17477 running.

@artem-lunarg
Copy link
Contributor Author

Investigating crashes on CI machines.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17477 aborted.

@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from 49069a5 to f70780a Compare September 16, 2024 20:38
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257540.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17479 running.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17479 aborted.

@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from f70780a to b52427d Compare September 16, 2024 23:04
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257596.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17480 running.

@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from b52427d to 289bd9c Compare September 16, 2024 23:42
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257618.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17481 running.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17481 passed.

@artem-lunarg
Copy link
Contributor Author

artem-lunarg commented Sep 17, 2024

The problem with CI crashes was that last change that should just cleanup things...

@artem-lunarg artem-lunarg marked this pull request as ready for review September 17, 2024 00:11
@artem-lunarg artem-lunarg requested a review from a team as a code owner September 17, 2024 00:11
@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from 289bd9c to 0677251 Compare September 17, 2024 07:42
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 257851.

@artem-lunarg artem-lunarg changed the title layers: Fix timeline resolving signal selection layers: Remove workaround for handling missing signals Sep 17, 2024
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17487 running.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17487 passed.

Copy link
Contributor

@jeremyg-lunarg jeremyg-lunarg left a comment

Choose a reason for hiding this comment

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

LGTM.

@@ -1313,6 +1313,10 @@ TEST_F(PositiveSyncObject, FenceSemThreadRace) {
AddRequiredFeature(vkt::Feature::timelineSemaphore);
RETURN_IF_SKIP(Init());

if (IsPlatformMockICD()) {
GTEST_SKIP() << "Test not supported by MockICD (WaitSemaphores)";
Copy link
Contributor

Choose a reason for hiding this comment

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

note: I have code in the CDL test framework that implements semaphores for the mock ICD. Could be a reason for us to re-converge them.

Copy link
Contributor Author

@artem-lunarg artem-lunarg Sep 17, 2024

Choose a reason for hiding this comment

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

Okay. Are you implementing mock synchronization for mock ICD? I was thinking about that, it would be really nice to remove this skips.

Signals registered in PreRecord are always available for non-external
semaphores after waiting dependency is resolved.

Also add placeholder and documentation for detecting non-increasing
signal order.
@artem-lunarg artem-lunarg force-pushed the artem-fix-semaphore-original-pre-record branch from 0677251 to eb00bcb Compare September 17, 2024 13:41
@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build queued with queue ID 258035.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17492 running.

@ci-tester-lunarg
Copy link
Collaborator

CI Vulkan-ValidationLayers build # 17492 passed.

@artem-lunarg artem-lunarg merged commit 66fe8d9 into KhronosGroup:main Sep 17, 2024
21 checks passed
@artem-lunarg artem-lunarg deleted the artem-fix-semaphore-original-pre-record branch September 17, 2024 14:30
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.

Bugs with CTS synchronization tests
3 participants