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

[NativeAOT] WindowsUse RtlDllShutdownInProgress to detect process shutdown #104318

Merged
merged 1 commit into from
Jul 2, 2024

Conversation

jkotas
Copy link
Member

@jkotas jkotas commented Jul 2, 2024

Port #103877 to Native AOT. This is fixing intermittent shutdown hangs that can observed by running the tests attached to #103877.

shutdown

Port dotnet#103877 to Native AOT. This is fixing intermittent shutdown hangs
that can observed by running the tests attached to dotnet#103877.
@jkotas jkotas requested a review from MichalStrehovsky as a code owner July 2, 2024 18:25
@jkotas jkotas changed the title [NativeAOT] WindowsUse RtlDllShutdownInProgress to detect process [NativeAOT] WindowsUse RtlDllShutdownInProgress to detect process shutdown Jul 2, 2024
Copy link
Contributor

Tagging subscribers to this area: @agocke, @MichalStrehovsky, @jkotas
See info in area-owners.md if you want to be subscribed.

@@ -1,6 +1,9 @@
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
#include "common.h"
#ifdef HOST_WINDOWS
#include <windows.h>
Copy link
Member Author

Choose a reason for hiding this comment

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

The PAL just gets into way in the complicated interactions that this requires, putting the code under ifdef is a lot simpler.

@jkotas
Copy link
Member Author

jkotas commented Jul 2, 2024

cc @agocke I think that the intermittent shutdown deadlocks that this is fixing are more likely to be hit by naot libraries mode that is used by some of the high-scale workloads. If we get reports of shutdown hangs from production, this fix can be backported.

@jkotas jkotas requested a review from davidwrighton July 2, 2024 18:34
@jkotas jkotas merged commit 752558f into dotnet:main Jul 2, 2024
87 of 89 checks passed
@jkotas jkotas deleted the nativeaot-shutdown branch July 2, 2024 21:50
@github-actions github-actions bot locked and limited conversation to collaborators Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants