[llvm] [SLP]Support revectorization of the previously vectorized scalars (PR #133091)
Gaƫtan Bossu via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 27 09:48:45 PDT 2025
================
@@ -4814,12 +4803,19 @@ class BoUpSLP {
ProcessBundleMember(SD, nullptr);
} else {
ScheduleBundle &Bundle = *cast<ScheduleBundle>(Data);
- for_each(Bundle.getBundle(), [](ScheduleData *SD) {
- SD->setScheduled(/*Scheduled=*/true);
- });
+ Bundle.setScheduled(/*Scheduled=*/true);
LLVM_DEBUG(dbgs() << "SLP: schedule " << Bundle << "\n");
- for (ScheduleData *SD : Bundle.getBundle())
- ProcessBundleMember(SD, &Bundle);
+ for (ScheduleData *SD : Bundle.getBundle()) {
+ if (ArrayRef<ScheduleBundle *> SDBundles =
+ getScheduleBundles(SD->getInst());
+ !SDBundles.empty() &&
+ all_of(SDBundles, [&](const ScheduleBundle *SDBundle) {
+ return SDBundle->isScheduled();
+ })) {
+ SD->setScheduled(/*Scheduled=*/true);
+ ProcessBundleMember(SD, &Bundle);
+ }
----------------
gbossu wrote:
Oh nvm, for some reason I was still checking the old diff, that does look a lot simpler now ;)
https://github.com/llvm/llvm-project/pull/133091
More information about the llvm-commits
mailing list