Skip to content

Enlighten more tasks that require no change#13045

Merged
baronfel merged 1 commit intodotnet:mainfrom
AR-May:enlighten-tasks-that-does-not-require-change
Jan 16, 2026
Merged

Enlighten more tasks that require no change#13045
baronfel merged 1 commit intodotnet:mainfrom
AR-May:enlighten-tasks-that-does-not-require-change

Conversation

@AR-May
Copy link
Member

@AR-May AR-May commented Jan 16, 2026

Context

This PR marks several simple tasks as multithreadable.

Changes Made

Marks several simple tasks as multithreadable by adding the MSBuildMultiThreadableTask attribute.

These tasks are safe for concurrent execution because they:
CombineTargetFrameworkInfoProperties, CombineXmlElements - Pure XML/string manipulation
ErrorFromResources - only logs messages
FindAppConfigFile, FindInvalidProjectReferences, GetCompatiblePlatform - Only reads metadata from ITaskItem objects; no file I/O

Testing

manual

@AR-May AR-May self-assigned this Jan 16, 2026
@AR-May AR-May marked this pull request as ready for review January 16, 2026 16:16
Copilot AI review requested due to automatic review settings January 16, 2026 16:16
Copy link
Contributor

Copilot AI left a comment

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 marks six simple MSBuild tasks as multithreadable to improve performance in multi-threaded builds. The tasks are safe for concurrent execution because they only perform read operations on input data (metadata reading, string/XML manipulation, logging) without modifying global process state or depending on relative path resolution.

Changes:

  • Added [MSBuildMultiThreadableTask] attribute to six task classes
  • Tasks will now execute in-process within thread nodes instead of sidecar TaskHost processes in multithreaded mode

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/Tasks/GetCompatiblePlatform.cs Added multithreadable attribute - task only reads metadata and calls shared utility
src/Tasks/FindInvalidProjectReferences.cs Added multithreadable attribute - task only reads metadata and logs warnings
src/Tasks/FindAppConfigFile.cs Added multithreadable attribute - task only performs string manipulation and metadata operations
src/Tasks/ErrorFromResources.cs Added multithreadable attribute - task only logs error messages
src/Tasks/CombineXmlElements.cs Added multithreadable attribute - task performs pure XML manipulation
src/Tasks/CombineTargetFrameworkInfoProperties.cs Added multithreadable attribute - task performs pure XML manipulation

@baronfel baronfel merged commit 4618ab5 into dotnet:main Jan 16, 2026
16 checks passed
This was referenced Mar 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants