Commit 365cb80
committed
[X86] Fold (add X, (srl Y, 7)) -> (sub X, (icmp_sgt 0, Y)) on vXi8 vectors
Undo the vectorcombine canonicalisation as SSE has awful vXi8 shift support, but can easily splat the MSB using the PCMPGTB(0,x) trick.
Alternative to llvm#143106 which could cause infinite loops between srl/sra conversions
Fixes llvm#1305491 parent c738308 commit 365cb80
File tree
4 files changed
+557
-582
lines changed- llvm
- lib/Target/X86
- test/CodeGen/X86
4 files changed
+557
-582
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
58117 | 58117 | | |
58118 | 58118 | | |
58119 | 58119 | | |
58120 | | - | |
58121 | | - | |
58122 | | - | |
58123 | | - | |
58124 | | - | |
58125 | 58120 | | |
58126 | 58121 | | |
58127 | 58122 | | |
58128 | 58123 | | |
| 58124 | + | |
| 58125 | + | |
| 58126 | + | |
| 58127 | + | |
| 58128 | + | |
| 58129 | + | |
58129 | 58130 | | |
58130 | 58131 | | |
58131 | 58132 | | |
58132 | 58133 | | |
58133 | 58134 | | |
58134 | 58135 | | |
| 58136 | + | |
| 58137 | + | |
| 58138 | + | |
| 58139 | + | |
| 58140 | + | |
| 58141 | + | |
| 58142 | + | |
| 58143 | + | |
| 58144 | + | |
58135 | 58145 | | |
58136 | 58146 | | |
58137 | 58147 | | |
| |||
0 commit comments