diff options
| author | Philip Reames <preames@rivosinc.com> | 2025-07-02 18:16:27 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-07-02 18:16:27 -0700 |
| commit | 220a00239696257a02fe625a4819fcd038e9dd07 (patch) | |
| tree | 1454a637eaf06803d5f42389ce952525a23bb850 /lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptedThreadPythonInterface.cpp | |
| parent | 44bed1af0fb641ce169262ab9fdb15ad76fe72a1 (diff) | |
[SDAG] Prefer scalar for prefix of vector GEP expansion (#146719)
When generating SDAG for a getelementptr with a vector result, we were
previously generating splats for each scalar operand. This essentially
has the effect of aggressively vectorizing the sequence, and leaving it
later combines to scalarize if profitable.
Instead, we can keep the accumulating address as a scalar for as long as
the prefix of operands allows before lazily converting to vector on the
first vector operand. This both better fits hardware which frequently
has a scalar base on the scatter/gather instructions, and reduces the
addressing cost even when not as otherwise we end up with a scalar to
vector domain crossing for each scalar operand.
Note that constant splat offsets are treated as scalar for the above,
and only variable offsets can force a conversion to vector.
---------
Co-authored-by: Craig Topper <craig.topper@sifive.com>
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptedThreadPythonInterface.cpp')
0 files changed, 0 insertions, 0 deletions
