Vector algorithms: runtime coverage for ARM64EC non-vectorized fallbacks by AlexGuteniev · Pull Request #6100 · microsoft/STL · GitHub
Skip to content

Vector algorithms: runtime coverage for ARM64EC non-vectorized fallbacks#6100

Closed
AlexGuteniev wants to merge 1 commit into
microsoft:mainfrom
AlexGuteniev:fallback-coverage
Closed

Vector algorithms: runtime coverage for ARM64EC non-vectorized fallbacks#6100
AlexGuteniev wants to merge 1 commit into
microsoft:mainfrom
AlexGuteniev:fallback-coverage

Conversation

@AlexGuteniev

Copy link
Copy Markdown
Contributor

Use them when _ENABLE_STL_INTERNAL_CHECK. is defined.

We have !_USE_STD_VECTOR_ALGORITHMS coverage, so no much concerns about the missing non-vectoziaed coverage.

Putting _VECTORIZED_MINMAX_ELEMENT_64BIT_INT on display, as in-place expression for this quirk is getting complicated.

@StephanTLavavej

Copy link
Copy Markdown
Member

@StephanTLavavej StephanTLavavej added enhancement Something can be improved test Related to test code labels Feb 22, 2026
@AlexGuteniev

AlexGuteniev commented Feb 22, 2026

Copy link
Copy Markdown
Contributor Author
  • Extracting the int64 complexity. Should be fine but should be done in isolation.

Then it should go first. Exercising the fallback without extracting int64 complexity becomes way too complicated.

Can you explain in simpler terms what this is trying to do, and why we have to exercise modes that aren't usually enabled for users? I could potentially be open to adding an off-by-default mode that the tests could optionally activate (in addition to testing vanilla modes) but I want to understand why.

Here you are mentioning #5998 (comment):

I think the ARM64EC vector_algorithms.cpp is used when x64 user .obj files are linked into an ARM64EC binary. That's why the ARM64EC surface must always match the x64 surface.

I'm confident that if this explanation is correct, then used in it means called. Since there's a scenario where they area called exists, we need some coverage to avoid #5993 regression.

Additionally, this will help catching complete omission of such callbacks in newly vectorized function without having to check exports.

This means that we're testing something wildly different than what we're shipping.

I understand this disadvantage. But I think the need for coverage of these outweighs the disadvantage.

@StephanTLavavej

Copy link
Copy Markdown
Member

Ok, let's do the int64 separation first, then we can think about exercising the ARM64EC scenario.

@AlexGuteniev

Copy link
Copy Markdown
Contributor Author

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

Labels

enhancement Something can be improved test Related to test code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants