fix(vmi): lower compact reduction stores with point stores - #1030
Merged
zhangstevenunity merged 1 commit intoJul 29, 2026
Merged
Conversation
mouliangyu
marked this pull request as ready for review
July 29, 2026 01:31
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.
What
vcadd/vcmax/vcminresults to unit-stridegroup_store.group = 1when its only consumer is the store, allowing the existing group-slot lowering to emit1PT_B32directly.Why
A direct
1 x T -> 1reduction followed byvstorepreviously lowered through neutral-init materialization, an extra vector add, predicate construction, and a masked store. The compact result can instead use the existing group-store representation and lower tovcaddplus1PT_B32store.The layout regression test now uses memory-backed operands, allowing layout assignment to select a direct
DINTLV_B32load for multi-part widening/reduction flows instead of introducing an artificial conversion at a VMI register function argument.Tests
cmake --build build-main-llvm21 --target pto-test-opt -j2llvm-lit -sv build-main-llvm21/test/lit/vmi_new(438/438 passed)Closes #1022.
The focused reproducer and performance context are in #1013.