[all-commits] [llvm/llvm-project] f5d153: [VectorCombine] Fold binary op of reductions. (#12...
Mikhail Gudim via All-commits
all-commits at lists.llvm.org
Sat Feb 22 03:11:55 PST 2025
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: f5d153ef26a9a206ab6eb4307de24c16b600c0d9
https://github.com/llvm/llvm-project/commit/f5d153ef26a9a206ab6eb4307de24c16b600c0d9
Author: Mikhail Gudim <mgudim at gmail.com>
Date: 2025-02-22 (Sat, 22 Feb 2025)
Changed paths:
M llvm/include/llvm/Transforms/Utils/LoopUtils.h
M llvm/lib/Transforms/Utils/LoopUtils.cpp
M llvm/lib/Transforms/Vectorize/VectorCombine.cpp
A llvm/test/Transforms/VectorCombine/ARM/fold-binop-of-reductions.ll
M llvm/test/Transforms/VectorCombine/fold-binop-of-reductions.ll
Log Message:
-----------
[VectorCombine] Fold binary op of reductions. (#121567)
Replace binary of of two reductions with one reduction of the binary op
applied to vectors. For example:
```
%v0_red = tail call i32 @llvm.vector.reduce.add.v16i32(<16 x i32> %v0)
%v1_red = tail call i32 @llvm.vector.reduce.add.v16i32(<16 x i32> %v1)
%res = add i32 %v0_red, %v1_red
```
gets transformed to:
```
%1 = add <16 x i32> %v0, %v1
%res = call i32 @llvm.vector.reduce.add.v16i32(<16 x i32> %1)
```
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