[all-commits] [llvm/llvm-project] 79ae40: [ConstantFolding] Fold intrinsics of scalable vect...
Luke Lau via All-commits
all-commits at lists.llvm.org
Wed May 28 15:30:03 PDT 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 79ae407c95715f0be5a78260c3b135090f679637
https://github.com/llvm/llvm-project/commit/79ae407c95715f0be5a78260c3b135090f679637
Author: Luke Lau <luke at igalia.com>
Date: 2025-05-28 (Wed, 28 May 2025)
Changed paths:
M llvm/lib/Analysis/ConstantFolding.cpp
M llvm/lib/IR/Constants.cpp
M llvm/test/Transforms/InstSimplify/ConstProp/abs.ll
M llvm/test/Transforms/InstSimplify/ConstProp/fma.ll
M llvm/test/Transforms/InstSimplify/exp10.ll
Log Message:
-----------
[ConstantFolding] Fold intrinsics of scalable vectors with splatted operands (#141845)
As noted in
https://github.com/llvm/llvm-project/pull/141821#issuecomment-2917328924,
whilst we currently constant fold intrinsics of fixed-length vectors via
their scalar counterpart, we don't do the same for scalable vectors.
This handles the scalable vector case when the operands are splats.
One weird snag in ConstantVector::getSplat was that it produced a undef
if passed in poison, so this also contains a fix by checking for
PoisonValue before UndefValue.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list