[llvm] [SystemZ] Fix bitwidth problem in FindReplicatedImm() (NFC). (PR #115383)

Jonas Paulsson via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 11 12:14:28 PST 2024


JonPsson1 wrote:

Ouch... ofc, that is needed for the SplatBits.

Patch updated to instead truncate the APInt if the store is truncating. This should work also for the case of a BuildVector being truncated to less than the element width.

This is NFC on benchmarks, so not sure if it is worth taking the care to have a handling there. Alternatively FindReplicatedImm() could just bail if the immediate does not fit..?



https://github.com/llvm/llvm-project/pull/115383


More information about the llvm-commits mailing list