<feed xmlns='http://www.w3.org/2005/Atom'>
<title>llvm-project.git/llvm/lib/Transforms/Vectorize/VPlanRecipes.cpp, branch main</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] Only apply forced cost to recipes with underlying values. (#168372)</title>
<updated>2025-11-21T14:21:16+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-21T14:21:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=31711c908fbd391601122c3457e71d0714fe4117'/>
<id>31711c908fbd391601122c3457e71d0714fe4117</id>
<content type='text'>
Only apply forced instruction costs to recipes with underlying values to
match the legacy cost model. A VPlan may have a number of additional
VPInstructions without underlying values that are not considered for its
cost, and assigning forced costs to them would incorrectly inflate its
cost.

This fixes a cost divergence between legacy and VPlan-based cost models
with forced instruction costs.

PR: https://github.com/llvm/llvm-project/pull/168372</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Only apply forced instruction costs to recipes with underlying values to
match the legacy cost model. A VPlan may have a number of additional
VPInstructions without underlying values that are not considered for its
cost, and assigning forced costs to them would incorrectly inflate its
cost.

This fixes a cost divergence between legacy and VPlan-based cost models
with forced instruction costs.

PR: https://github.com/llvm/llvm-project/pull/168372</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Remove PtrIV::IsScalarAfterVectorization, use VPlan analysis. (#168289)</title>
<updated>2025-11-20T18:58:25+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-20T18:58:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=7acfbc23a71cf66bbba89de55568064d732a61d1'/>
<id>7acfbc23a71cf66bbba89de55568064d732a61d1</id>
<content type='text'>
Remove `VPWidenPointerInductionRecipe::IsScalarAfterVectorization` and
replace it with `onlyScalarValuesUsed`. This removes the need to carry
state from the legacy cost model through VPlan, and the VPlan-based
analysis gives more accurate results, avoiding a number of extracts.

PR: https://github.com/llvm/llvm-project/pull/168289</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove `VPWidenPointerInductionRecipe::IsScalarAfterVectorization` and
replace it with `onlyScalarValuesUsed`. This removes the need to carry
state from the legacy cost model through VPlan, and the VPlan-based
analysis gives more accurate results, avoiding a number of extracts.

PR: https://github.com/llvm/llvm-project/pull/168289</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Print debug info for all recipes. (#168454)</title>
<updated>2025-11-19T10:10:08+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-19T10:10:08+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=07309135291e804945de3ec7068b787a45a3499f'/>
<id>07309135291e804945de3ec7068b787a45a3499f</id>
<content type='text'>
Use the recently refactored VPRecipeBase::print to print debug location
for all recipes.

PR: https://github.com/llvm/llvm-project/pull/168454</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use the recently refactored VPRecipeBase::print to print debug location
for all recipes.

PR: https://github.com/llvm/llvm-project/pull/168454</pre>
</div>
</content>
</entry>
<entry>
<title>[TTI] Use MemIntrinsicCostAttributes for getMaskedMemoryOpCost (#168029)</title>
<updated>2025-11-19T01:51:12+00:00</updated>
<author>
<name>Shih-Po Hung</name>
<email>shihpo.hung@sifive.com</email>
</author>
<published>2025-11-19T01:51:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=961940e1a7c9b4bbe0ae54c2ea4bdc69308947d6'/>
<id>961940e1a7c9b4bbe0ae54c2ea4bdc69308947d6</id>
<content type='text'>
- Split from #165532. This is a step toward a unified interface for
masked/gather-scatter/strided/expand-compress cost modeling.
- Replace the ad-hoc parameter list with a single attributes object.

API change:
```
- InstructionCost getMaskedMemoryOpCost(Opcode, Src, Alignment,
-                                       AddressSpace, CostKind);

+ InstructionCost getMaskedMemoryOpCost(MemIntrinsicCostAttributes,
+                                       CostKind);
```
Notes:
- NFCI intended: callers populate MemIntrinsicCostAttributes with the
same information as before.
- Follow-up: migrate gather/scatter, strided, and expand/compress cost
queries to the same attributes-based entry point.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Split from #165532. This is a step toward a unified interface for
masked/gather-scatter/strided/expand-compress cost modeling.
- Replace the ad-hoc parameter list with a single attributes object.

API change:
```
- InstructionCost getMaskedMemoryOpCost(Opcode, Src, Alignment,
-                                       AddressSpace, CostKind);

+ InstructionCost getMaskedMemoryOpCost(MemIntrinsicCostAttributes,
+                                       CostKind);
```
Notes:
- NFCI intended: callers populate MemIntrinsicCostAttributes with the
same information as before.
- Follow-up: migrate gather/scatter, strided, and expand/compress cost
queries to the same attributes-based entry point.</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] VPIRFlags kind for FCmp with predicate + fast-math flags (NFCI).</title>
<updated>2025-11-18T22:09:53+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-18T22:09:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=1e3ea03293229c4b5ca65427076fce154988675f'/>
<id>1e3ea03293229c4b5ca65427076fce154988675f</id>
<content type='text'>
FCmp instructions have both a predicate and fast-math flags. Introduce a
new FCmp kind, that combines both to model this correctly in the current
system.

This should be NFC modulo VPlan printing which now includes the correct
fast-math flags.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
FCmp instructions have both a predicate and fast-math flags. Introduce a
new FCmp kind, that combines both to model this correctly in the current
system.

This should be NFC modulo VPlan printing which now includes the correct
fast-math flags.
</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Populate and use VPIRFlags from initial VPInstruction. (#168450)</title>
<updated>2025-11-18T15:15:14+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-18T15:15:14+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=2befda2225a6c61d0308e536c19b066ab27bbf2a'/>
<id>2befda2225a6c61d0308e536c19b066ab27bbf2a</id>
<content type='text'>
Update VPlan to populate VPIRFlags during VPInstruction construction and
use it when creating widened recipes, instead of constructing VPIRFlags
from the underlying IR instruction each time. The VPRecipeWithIRFlags
constructor taking an underlying instruction and setting the flags based
on it has been removed.

This centralizes initial VPIRFlags creation and ensures flags are
consistently available throughout VPlan transformations and makes sure
we don't accidentally re-add flags from the underlying instruction that
already got dropped during transformations.

Follow-up to https://github.com/llvm/llvm-project/pull/167253, which did
the same for VPIRMetadata.

Should be NFC w.r.t. to the generated IR.

PR: https://github.com/llvm/llvm-project/pull/168450</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update VPlan to populate VPIRFlags during VPInstruction construction and
use it when creating widened recipes, instead of constructing VPIRFlags
from the underlying IR instruction each time. The VPRecipeWithIRFlags
constructor taking an underlying instruction and setting the flags based
on it has been removed.

This centralizes initial VPIRFlags creation and ensures flags are
consistently available throughout VPlan transformations and makes sure
we don't accidentally re-add flags from the underlying instruction that
already got dropped during transformations.

Follow-up to https://github.com/llvm/llvm-project/pull/167253, which did
the same for VPIRMetadata.

Should be NFC w.r.t. to the generated IR.

PR: https://github.com/llvm/llvm-project/pull/168450</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Populate and use VPIRMetadata from VPInstructions (NFC) (#167253)</title>
<updated>2025-11-17T21:28:49+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-17T21:28:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=3cba379e3d9bd2f929f5625fe38d17c34f4b7bb7'/>
<id>3cba379e3d9bd2f929f5625fe38d17c34f4b7bb7</id>
<content type='text'>
Update VPlan to populate VPIRMetadata during VPInstruction construction
and use it when creating widened recipes, instead of constructing
VPIRMetadata from the underlying IR instruction each time.

This centralizes VPIRMetadata in VPInstructions and ensures metadata is
consistently available throughout VPlan transformations.

PR: https://github.com/llvm/llvm-project/pull/167253</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update VPlan to populate VPIRMetadata during VPInstruction construction
and use it when creating widened recipes, instead of constructing
VPIRMetadata from the underlying IR instruction each time.

This centralizes VPIRMetadata in VPInstructions and ensures metadata is
consistently available throughout VPlan transformations.

PR: https://github.com/llvm/llvm-project/pull/167253</pre>
</div>
</content>
</entry>
<entry>
<title>Reland [VPlan] Expand WidenInt inductions with nuw/nsw (#168354)</title>
<updated>2025-11-17T13:44:25+00:00</updated>
<author>
<name>Ramkumar Ramachandra</name>
<email>ramkumar.ramachandra@codasip.com</email>
</author>
<published>2025-11-17T13:44:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=ef023cae388d7becd18df602cb2d77bdb3d59e55'/>
<id>ef023cae388d7becd18df602cb2d77bdb3d59e55</id>
<content type='text'>
Changes: The previous patch had to be reverted to a mismatching-OpType
assert in cse. The reduced-test has now been added corresponding to a
RVV pointer-induction, and the pointer-induction case has been updated
to use createOverflowingBinaryOp.

While at it, record VPIRFlags in VPWidenInductionRecipe.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Changes: The previous patch had to be reverted to a mismatching-OpType
assert in cse. The reduced-test has now been added corresponding to a
RVV pointer-induction, and the pointer-induction case has been updated
to use createOverflowingBinaryOp.

While at it, record VPIRFlags in VPWidenInductionRecipe.</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Add printRecipe, prepare printing metadata in ::print (NFC) (#166244)</title>
<updated>2025-11-17T12:01:40+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-17T12:01:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=7e730da128df186a63c6fde19693129322024c50'/>
<id>7e730da128df186a63c6fde19693129322024c50</id>
<content type='text'>
Add a new pinrRecipe which handles printing the recipe without common
info like debug info or metadata.

Prepares to print them once, in ::print(), after/in combination with
https://github.com/llvm/llvm-project/pull/165825.

PR: https://github.com/llvm/llvm-project/pull/166244</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a new pinrRecipe which handles printing the recipe without common
info like debug info or metadata.

Prepares to print them once, in ::print(), after/in combination with
https://github.com/llvm/llvm-project/pull/165825.

PR: https://github.com/llvm/llvm-project/pull/166244</pre>
</div>
</content>
</entry>
<entry>
<title>[VPlan] Delegate to other VPInstruction constructors. (NFCI)</title>
<updated>2025-11-16T22:21:00+00:00</updated>
<author>
<name>Florian Hahn</name>
<email>flo@fhahn.com</email>
</author>
<published>2025-11-16T22:20:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.belthelziquor.com/llvm-project.git/commit/?id=67c8e38b8b439b44c2cd35f590c4897b928eb682'/>
<id>67c8e38b8b439b44c2cd35f590c4897b928eb682</id>
<content type='text'>
Update VPInstruction constructor to delegate to constructor with more
comprehensive checking and validation.

This required updating some unit tests, to make sure the constructed
VPInstructions are valid.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update VPInstruction constructor to delegate to constructor with more
comprehensive checking and validation.

This required updating some unit tests, to make sure the constructed
VPInstructions are valid.
</pre>
</div>
</content>
</entry>
</feed>
