Skip to content

Tracking issue for i686 msvc CI issues with latest Windows 2022 runner image 20250224.5.0+ #137733

Closed

Description

@jieyouxu

This is a tracking issue for CI compilation errors related to missing SSE2 types encountered when trying to use latest Windows 2022 runner image 20250224.5.0+ on the i686-msvc-{1,2} and dist-i686-msvc jobs. Key difference for the image version is the Windows 11 SDK version bump from 10.0.22621.0 -> 10.0.26100.0 that modified UCRT headers (see below).

Context

Zulip thread: https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/spurious.20.28.3F.29.20i686.20msvc.20errors.

cc <= 1.2.15 emits /arch:IA32 for clang-cl on x86 arch Windows targets, which in conjunction with GitHub Runner Image versions Windows 2022 20250224.5.0+ seems to cause a bunch of failures related to compilation errors failing to using SSE2 types without enabling SSE2 via /arch:SSE2. msvc seems to silently accept this1 and happily emit SSE2 instruments but clang-cl will error.

As Fulgen pointed out (thanks!) on the zulip thread:

The UCRT headers are, which is where they differ (10.0.22621.0/ucrt/wchar.h doesn't have the vectorization, 10.0.26100.0/ucrt/wchar.h does)

Current mitigation attempts

Work needed to unblock using latest Windows 2022 runner image 20250224.5.0+ again

Warning

These steps are advisory and likely incomplete, we may find that we need to transitively bump cc versions in more deps.

Footnotes

  1. https://developercommunity.visualstudio.com/t/wcharh-from-SDK-100261000-cannot-be/10860122 ↩

Activity

  1. added
    C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFC
    T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.
    on Feb 27, 2025
  2. changed the title [-]Tracking issue for i686 CI issues with latest Windows 2022 runner image 20250224.5.0+[/-] [+]Tracking issue for i686 msvc CI issues with latest Windows 2022 runner image 20250224.5.0+[/+] on Feb 27, 2025
  3. added
    O-windows-msvcToolchain: MSVC, Operating system: Windows
    O-x86_32Target: x86 processors, 32 bit (like i686-*) (also known as IA-32, i386, i586, i686)
    A-CIArea: Our Github Actions CI
    on Feb 27, 2025
  4. Fulgen301 commented on Feb 27, 2025

    @Fulgen301
    Contributor

    Fix cc to not emit /arch:IA32, but instead either omit it or explicitly set /arch:SSE2 for clang-cl on x86:

    This has been fixed in the meantime, but to have it noted: Before this was fixed, C code with clang-cl was compiled without SSE2 support, whereas Rust code using that C code would be compiled with SSE2 enabled. The default function call ABI is likely fine, since extern "C" passes it all over the stack anyway, but I'm not an opsem person, maybe this could have broken something that nobody ever noticed.

  5. added 6 commits that reference this issue on Feb 27, 2025
  6. 4 remaining items

  7. added a commit that references this issue on Feb 28, 2025
  8. added
    T-cargoRelevant to the cargo team, which will review and decide on the PR/issue.
    on Feb 28, 2025
  9. added a commit that references this issue on Feb 28, 2025
  10. added a commit that references this issue on Mar 1, 2025
  11. added 2 commits that reference this issue on Mar 3, 2025
  12. added a commit that references this issue on Mar 4, 2025
  13. Epixu commented on Mar 5, 2025

    @Epixu

    Apologies for randomly intruding here.
    I just encountered a CI failure for the same reasons and found only this relevant thread. In my case it was the cherry on top, because I'm at the brink of abandoning 32bit MSVC builds in their entirety at this point, because they have been bringing me nothing but grief lately.
    I was just curious, have you often encountered as many code generation errors, slow build speeds and constexpr-related ICE's associated with MSVC v143 x86 builds in particular?
    If so, considering you're still supporting them, am I doing something wrong and is it worth it to invest the time to research your coping mechanisms? Or would it be wiser for me, as a single developer, to just outright abandon these configurations...

  14. jieyouxu commented on Mar 5, 2025

    @jieyouxu
    MemberAuthor

    I just encountered a CI failure for the same reasons and found only this relevant thread. In my case it was the cherry on top, because I'm at the brink of abandoning 32bit MSVC builds in their entirety at this point, because they have been bringing me nothing but grief lately. I was just curious, have you often encountered as many code generation errors, slow build speeds and constexpr-related ICE's associated with MSVC v143 x86 builds in particular? If so, considering you're still supporting them, am I doing something wrong and is it worth it to invest the time to research your coping mechanisms? Or would it be wiser for me, as a single developer, to just outright abandon these configurations...

    Our most recent 32-bit msvc CI issue (this issue) was very specific. Known cause, one of our deps was incorrectly instructing msvc to use /arch:IA32 when we should've been using default or /arch:SSE2. I don't recall running into

    as many code generation errors, slow build speeds and constexpr-related ICE's associated with MSVC v143 x86 builds in particular

    in our CI recently. Fix for our CI purposes is to just fix the dep to emit the right /arch, which I suspect is not remotely close to what you are experiencing (sorry to hear that).

  15. jieyouxu commented on Mar 5, 2025

    @jieyouxu
    MemberAuthor

    You will probably have to take that up with the MSVC team, since I assume your CI is exercising C++ code much more heavily?

  16. Epixu commented on Mar 5, 2025

    @Epixu

    Yes, I've already documented about three compiler bugs, one even got fixed recently. But I'm running out of energy to cope with those. I tend to test all possible combinations and it's always the particular configurations that interfere. Like, I literally yesterday excluded SSE/AVX/AVX2 x86 builds due to ICE's and code generation errors. And just now, when I decided it's all figured out, I get this absolutely horrid runner update introducing problems even for clang-cl, which pissed me even more.
    Anyways, thanks for the feedback!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-CIArea: Our Github Actions CIC-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCO-windows-msvcToolchain: MSVC, Operating system: WindowsO-x86_32Target: x86 processors, 32 bit (like i686-*) (also known as IA-32, i386, i586, i686)T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)T-cargoRelevant to the cargo team, which will review and decide on the PR/issue.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.T-infraRelevant to the infrastructure team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions