Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Rename AsyncSafeThreadMap to SignalSafeThreadMap - #122794

#122794
Merged
janvorli merged 2 commits into
maindotnet/runtime:mainfrom
copilot/rename-async-to-signal-safedotnet/runtime:copilot/rename-async-to-signal-safeCopy head branch name to clipboard
Jan 2, 2026
Merged

Rename AsyncSafeThreadMap to SignalSafeThreadMap#122794
janvorli merged 2 commits into
maindotnet/runtime:mainfrom
copilot/rename-async-to-signal-safedotnet/runtime:copilot/rename-async-to-signal-safeCopy head branch name to clipboard

Conversation

Copilot AI commented Dec 31, 2025

Copy link
Copy Markdown
Contributor

Renamed AsyncSafeThreadMap to SignalSafeThreadMap throughout the codebase. The term "async" has specific established meaning in .NET (async/await patterns), while this data structure is designed for safe use in signal handlers.

Co-authored-by: jkotas <6668460+jkotas@users.noreply.github.com>
Copilot AI changed the title [WIP] Rename AsyncSafeThreadMap to SignalSafeThreadMap in codebase Rename AsyncSafeThreadMap to SignalSafeThreadMap Dec 31, 2025
Copilot AI requested a review from jkotas December 31, 2025 05:24
@jkotas
jkotas marked this pull request as ready for review December 31, 2025 06:20
@jkotas
jkotas requested review from Copilot and janvorli December 31, 2025 06:20

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR renames AsyncSafeThreadMap to SignalSafeThreadMap throughout the CoreCLR and NativeAOT codebases to avoid confusion with .NET's async/await terminology. The data structure is specifically designed for safe use within signal handlers on Unix platforms.

Key changes:

  • Renamed files from asyncsafethreadmap.{cpp,h} to SignalSafeThreadMap.{cpp,h} following PascalCase convention
  • Renamed all three public functions: InsertThreadIntoSignalSafeMap, RemoveThreadFromSignalSafeMap, FindThreadInSignalSafeMap
  • Updated internal static variable s_pSignalSafeThreadMapHead and all comments/error messages to use "signal-safe" terminology

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/coreclr/vm/threads.cpp Updated header include and function calls in GetThreadAsyncSafe() and SetThread() to use renamed signal-safe map functions
src/coreclr/vm/CMakeLists.txt Updated build configuration to reference renamed SignalSafeThreadMap.{cpp,h} files
src/coreclr/runtime/SignalSafeThreadMap.h Renamed header guards, function declarations, and comments from "async-safe" to "signal-safe" terminology
src/coreclr/runtime/SignalSafeThreadMap.cpp Renamed static variable, function implementations, and internal comments to use "signal-safe" terminology
src/coreclr/nativeaot/Runtime/threadstore.cpp Updated header include and function calls in AttachCurrentThread(), DetachCurrentThread(), and GetCurrentThreadIfAvailableAsyncSafe()
src/coreclr/nativeaot/Runtime/CMakeLists.txt Updated build configuration to reference renamed SignalSafeThreadMap.cpp file

@dotnet-policy-service

Copy link
Copy Markdown
Contributor

Tagging subscribers to this area: @mangod9
See info in area-owners.md if you want to be subscribed.

@janvorli
janvorli merged commit f6d1c33 into main Jan 2, 2026
108 of 110 checks passed
@jkotas
jkotas deleted the copilot/rename-async-to-signal-safe branch January 2, 2026 15:48
@github-actions github-actions Bot locked and limited conversation to collaborators Feb 2, 2026
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.

4 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.