diff options
author | Simon Pilgrim <llvm-dev@redking.me.uk> | 2020-06-09 18:36:14 +0100 |
---|---|---|
committer | Simon Pilgrim <llvm-dev@redking.me.uk> | 2020-06-09 19:02:05 +0100 |
commit | 5dc4e7c2b95fc665c1dc86c6b40cf02171f8801d (patch) | |
tree | cebab77093ca3bcaa682431c09bb6cc230fc1d8b /llvm/lib/CodeGen/MachineScheduler.cpp | |
parent | bc38793852c0552337bae54961eb14fb0bacf356 (diff) | |
download | llvm-5dc4e7c2b95fc665c1dc86c6b40cf02171f8801d.zip llvm-5dc4e7c2b95fc665c1dc86c6b40cf02171f8801d.tar.gz llvm-5dc4e7c2b95fc665c1dc86c6b40cf02171f8801d.tar.bz2 |
[VectorCombine] scalarizeBinop - support an all-constant src vector operand
scalarizeBinop currently folds
vec_bo((inselt VecC0, V0, Index), (inselt VecC1, V1, Index))
->
inselt(vec_bo(VecC0, VecC1), scl_bo(V0,V1), Index)
This patch extends this to account for cases where one of the vec_bo operands is already all-constant and performs similar cost checks to determine if the scalar binop with a constant still makes sense:
vec_bo((inselt VecC0, V0, Index), VecC1)
->
inselt(vec_bo(VecC0, VecC1), scl_bo(V0,extractelt(V1,Index)), Index)
Fixes PR42174
Differential Revision: https://reviews.llvm.org/D80885
Diffstat (limited to 'llvm/lib/CodeGen/MachineScheduler.cpp')
0 files changed, 0 insertions, 0 deletions