diff options
| author | David Green <david.green@arm.com> | 2025-11-04 07:50:51 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-11-04 07:50:51 +0000 |
| commit | 6ad25c5912fcf13b44fcc03bd6a66dc33348cd68 (patch) | |
| tree | feeb99f4c63f3d93c2997bbf7d2d69334cdb5dc9 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp | |
| parent | 25a592cc63f0a252b8ae980271d0767a342a0a77 (diff) | |
| download | llvm-6ad25c5912fcf13b44fcc03bd6a66dc33348cd68.zip llvm-6ad25c5912fcf13b44fcc03bd6a66dc33348cd68.tar.gz llvm-6ad25c5912fcf13b44fcc03bd6a66dc33348cd68.tar.bz2 | |
[AArch64] Improve the cost model for extending mull (#125651)
We already have cost model code for detecting extending mull multiplies
for the form `mul(ext, ext)`. Since it was added the codegen for mull
has been improved, this attempts to catch the cost model up.
The main idea is to incorporate extends of larger sizes. A vector `v8i32
mul(zext(v8i8), zext(v8i8))` will be code-generated as `zext (v8i16
mul(zext(v8i8), zext(v8i8))`, or umull+ushll+ushll2.
So the total cost should be 3ish if each instruction costs 1. Where
exactly we attribute the costs is dependable, this patch opts to sets
the cost of the extend to 0 (or the cost of the extend not included in
the mull) and the mul gets the cost of the mull+extra extends.
isWideningInstruction is split into two functions for the two types of
operands it supports. isSingleExtWideningInstruction now handles addw
instructions that extend the second operand, isBinExtWideningInstruction
is for instructions like addl that extend both operands.
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp')
0 files changed, 0 insertions, 0 deletions
