<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Transforms/Vectorize/VPlanVerifier.cpp, branch users/nico/python-2</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/'/>
<entry>
<title>[VPlan] Support VPWidenIntOrFpInductionRecipes with EVL tail folding (#144666)</title>
<updated>2025-07-01T11:29:24+00:00</updated>
<author>
<name>Luke Lau</name>
<email>luke@igalia.com</email>
</author>
<published>2025-07-01T11:29:24+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=4a2fa0847fb07d181ef71798cb8d7f4c34599fbf'/>
<id>4a2fa0847fb07d181ef71798cb8d7f4c34599fbf</id>
<content type='text'>
Following on from #118638, this handles widened induction variables with
EVL tail folding by setting the VF operand to be EVL, calculated in the
vector body.

We need to do this for correctness since with EVL tail folding the
number of elements processed in the penultimate iteration may not be VF,
but the runtime EVL, and we need take this into account when updating
the backedge value.

- Because the VF may now not be a live-in we need to move the insertion
point to just after the VFs definition
- We also need to avoid truncating it when it's the same size as the
step type, previously this wasn't a problem for live-ins.
- Also because the VF may be smaller than the IV type, since the EVL is
always i32, we may need to zext it.

On -march=rva23u64 -O3 we get 87.1% more loops vectorized on TSVC, and
42.8% more loops vectorized on SPEC CPU 2017</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Following on from #118638, this handles widened induction variables with
EVL tail folding by setting the VF operand to be EVL, calculated in the
vector body.

We need to do this for correctness since with EVL tail folding the
number of elements processed in the penultimate iteration may not be VF,
but the runtime EVL, and we need take this into account when updating
the backedge value.

- Because the VF may now not be a live-in we need to move the insertion
point to just after the VFs definition
- We also need to avoid truncating it when it's the same size as the
step type, previously this wasn't a problem for live-ins.
- Also because the VF may be smaller than the IV type, since the EVL is
always i32, we may need to zext it.

On -march=rva23u64 -O3 we get 87.1% more loops vectorized on TSVC, and
42.8% more loops vectorized on SPEC CPU 2017</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Replace all uses of VF when EVL tail folding. NFCI (#146339)</title>
<updated>2025-06-30T12:47:38+00:00</updated>
<author>
<name>Luke Lau</name>
<email>luke@igalia.com</email>
</author>
<published>2025-06-30T12:47:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=f01a7936bea491324e06dcf203749dda08ce7c07'/>
<id>f01a7936bea491324e06dcf203749dda08ce7c07</id>
<content type='text'>
With EVL tail folding, any use of the VF live in should be replaced by
the EVL. Otherwise, it should likely be directly emitted as a constant
via VPTransformState::VF.

This strengthens the EVL transformation by replacing all uses of VF with
EVL and asserting that the only users are VPVectorEndPointerRecipe and
VPScalarIVStepsRecipe, the latter of which is new.

This should be NFC because even though we didn't previously replace the
EVL of VPScalarIVStepsRecipe, it's only used when unrolling which we
don't allow with EVL tail folding yet.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With EVL tail folding, any use of the VF live in should be replaced by
the EVL. Otherwise, it should likely be directly emitted as a constant
via VPTransformState::VF.

This strengthens the EVL transformation by replacing all uses of VF with
EVL and asserting that the only users are VPVectorEndPointerRecipe and
VPScalarIVStepsRecipe, the latter of which is new.

This should be NFC because even though we didn't previously replace the
EVL of VPScalarIVStepsRecipe, it's only used when unrolling which we
don't allow with EVL tail folding yet.</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Always verify VPCanonicalIVPHIRecipe placement (NFC).</title>
<updated>2025-06-11T19:45:48+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-06-11T19:45:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ace356bc9777e6a5b5aa0ba2335d2546ac6f330e'/>
<id>ace356bc9777e6a5b5aa0ba2335d2546ac6f330e</id>
<content type='text'>
Loop regions are dissolved since dcef154b5caf6556e69bb1, remove the
check for VerifyLate and corresponding TODO.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Loop regions are dissolved since dcef154b5caf6556e69bb1, remove the
check for VerifyLate and corresponding TODO.
</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Remove ResumePhi opcode, use regular PHI instead (NFC). (#140405)</title>
<updated>2025-05-30T11:50:08+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-30T11:50:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=10bd4cd9cd0f11f158c0fe276441c65ba6bca30a'/>
<id>10bd4cd9cd0f11f158c0fe276441c65ba6bca30a</id>
<content type='text'>
Use regular VPPhi instead of a separate opcode for resume phis. This
removes an unneeded specialized opcode and unifies the code
(verification, printing, updating when CFG is changed).

Depends on https://github.com/llvm/llvm-project/pull/140132.

PR: https://github.com/llvm/llvm-project/pull/140405</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use regular VPPhi instead of a separate opcode for resume phis. This
removes an unneeded specialized opcode and unifies the code
(verification, printing, updating when CFG is changed).

Depends on https://github.com/llvm/llvm-project/pull/140132.

PR: https://github.com/llvm/llvm-project/pull/140405</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Replace VPRegionBlock with explicit CFG before execute (NFCI). (#117506)</title>
<updated>2025-05-24T18:17:16+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-24T18:17:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=dcef154b5caf6556e69bb18bbb0506d274aa474e'/>
<id>dcef154b5caf6556e69bb18bbb0506d274aa474e</id>
<content type='text'>
Building on top of https://github.com/llvm/llvm-project/pull/114305,
replace VPRegionBlocks with explicit CFG before executing.

This brings the final VPlan closer to the IR that is generated and
helps to simplify codegen.

It will also enable further simplifications of phi handling during
execution and transformations that do not have to preserve the 
canonical IV required by loop regions. This for example could include
replacing the canonical IV with an EVL based phi while completely
removing the original canonical IV.

PR: https://github.com/llvm/llvm-project/pull/117506</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Building on top of https://github.com/llvm/llvm-project/pull/114305,
replace VPRegionBlocks with explicit CFG before executing.

This brings the final VPlan closer to the IR that is generated and
helps to simplify codegen.

It will also enable further simplifications of phi handling during
execution and transformations that do not have to preserve the 
canonical IV required by loop regions. This for example could include
replacing the canonical IV with an EVL based phi while completely
removing the original canonical IV.

PR: https://github.com/llvm/llvm-project/pull/117506</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Verify final VPlan, just before execution. (NFC)</title>
<updated>2025-05-17T16:53:06+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-17T16:53:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=e81fab68478754097c3354c0d2749ab009f8f0c8'/>
<id>e81fab68478754097c3354c0d2749ab009f8f0c8</id>
<content type='text'>
Add additional verifier call just before execution, to make sure the
final VPlan is valid.

Note that this currently requires disabling a small number of checks
when running late.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add additional verifier call just before execution, to make sure the
final VPlan is valid.

Note that this currently requires disabling a small number of checks
when running late.
</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Add VPTypeAnalysis constructor taking a VPlan (NFC).</title>
<updated>2025-05-15T21:19:36+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-15T21:19:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=efae492ad1ba80764ec4a85f5622a8713646f970'/>
<id>efae492ad1ba80764ec4a85f5622a8713646f970</id>
<content type='text'>
Add constructor that retrieves the scalar type from the trip count
expression, if no canonical IV is available. Used in the verifier, in
preparation for late verification, when the canonical IV has been
dissolved.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add constructor that retrieves the scalar type from the trip count
expression, if no canonical IV is available. Used in the verifier, in
preparation for late verification, when the canonical IV has been
dissolved.
</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Verify dominance for incoming values of phi-like recipes. (#124838)</title>
<updated>2025-05-15T11:20:54+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-15T11:20:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=8bbe0d050ae49062835a8a0729b3219ba1f6362b'/>
<id>8bbe0d050ae49062835a8a0729b3219ba1f6362b</id>
<content type='text'>
Update the verifier to verify dominance for incoming values for phi-like
recipes. The defining recipe must dominate the incoming block for the
incoming value.

Builds on top of https://github.com/llvm/llvm-project/pull/138472 to
retrieve incoming values &amp; corresponding blocks for phi-like recipes.

PR: https://github.com/llvm/llvm-project/pull/124838</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update the verifier to verify dominance for incoming values for phi-like
recipes. The defining recipe must dominate the incoming block for the
incoming value.

Builds on top of https://github.com/llvm/llvm-project/pull/138472 to
retrieve incoming values &amp; corresponding blocks for phi-like recipes.

PR: https://github.com/llvm/llvm-project/pull/124838</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Print use and definition in verifier on violation.</title>
<updated>2025-05-13T08:52:02+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-13T08:51:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ba2dacd276522d483a38f786cce66b16a349446b'/>
<id>ba2dacd276522d483a38f786cce66b16a349446b</id>
<content type='text'>
Improves the error message when a use comes before the def by including
the use and def, when print utilities are available.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Improves the error message when a use comes before the def by including
the use and def, when print utilities are available.
</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Verify number preds and operands matches for VPIRPhis. (NFC)</title>
<updated>2025-05-05T14:32:02+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-05-05T14:25:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=aadf35cb41db9bc4594d9a70cfdc6d43d795a097'/>
<id>aadf35cb41db9bc4594d9a70cfdc6d43d795a097</id>
<content type='text'>
Extend the verifier to ensure the number of predecessors and operands
match for VPIRPhis.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Extend the verifier to ensure the number of predecessors and operands
match for VPIRPhis.
</pre>
</div>
</content>
</entry>
</feed>
