[release/10.0] Avoid C4319 build warnings in libunwind#125465
Open
steveisok wants to merge 1 commit intodotnet:release/10.0from
Open
[release/10.0] Avoid C4319 build warnings in libunwind#125465steveisok wants to merge 1 commit intodotnet:release/10.0from
steveisok wants to merge 1 commit intodotnet:release/10.0from
Conversation
Backport of dotnet#123535 (main) / dotnet#122179 (release/9.0) to release/10.0. Include libunwind/libunwind#931 in the build of the libunwind dependency. Adds (size_t) casts to the UNW_ALIGN macro to avoid C4319 warnings that are treated as errors with newer MSVC toolsets. This fixes Windows_x86_BuildPass2 failures in the VMR dotnet-unified-build pipeline on release/10.0.1xx. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
|
Tagging subscribers to this area: @dotnet/runtime-infrastructure |
Contributor
There was a problem hiding this comment.
Pull request overview
Backports the libunwind fix to avoid MSVC C4319 warnings (treated as errors with /WX) by updating the UNW_ALIGN macro to use size_t casts, and records inclusion of upstream libunwind PR #931 in the dependency patch list.
Changes:
- Update
UNW_ALIGNmacro to cast operands tosize_tto avoid MSVC C4319 warning. - Record application of libunwind upstream PR #931 in the libunwind version tracking file.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/native/external/libunwind/include/libunwind_i.h | Uses size_t casts in UNW_ALIGN to prevent MSVC C4319 warnings under /WX. |
| src/native/external/libunwind-version.txt | Documents that libunwind PR #931 is applied in the vendored dependency. |
You can also share your feedback on Copilot code review. Take the survey.
jkoritzinsky
approved these changes
Mar 11, 2026
hoyosjs
approved these changes
Mar 12, 2026
AaronRobinsonMSFT
approved these changes
Mar 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #123535 (main) / #122179 (release/9.0) to release/10.0.
Include libunwind/libunwind#931 in the build of the libunwind dependency. Adds
(size_t)casts to theUNW_ALIGNmacro to avoid C4319 warnings that are treated as errors with newer MSVC toolsets.Context
An MSVC toolset update (
19.44.35220→19.44.35221) introduced stricter C4319 analysis. Combined with/WX(warnings as errors), this breaks the cross-OS DAC build of libunwind on Windows:This is causing
Windows_x86_BuildPass2failures in the VMR dotnet-unified-build pipeline onrelease/10.0.1xx(e.g., internal build 2924142).Fix
Same one-line fix as #122179 / #123535: cast operands to
size_tin theUNW_ALIGNmacro.Risk
Low — targeted cast-only change, already validated on 9.0 and main.