Commit 2daa362
committed
[InstCombine] Use intersectForOffsetAdd() in CommonPointerBase
Transform using this will add up all the offsets, so we should use
intersectForOffsetAdd() instead of plain intersection.
Annoyingly, this requires specially handling the first GEP to
avoid losing flags in that case.
Fixes #157714.1 parent d685508 commit 2daa362
File tree
2 files changed
+17
-5
lines changed- llvm
- lib/Transforms/InstCombine
- test/Transforms/InstCombine
2 files changed
+17
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2115 | 2115 | | |
2116 | 2116 | | |
2117 | 2117 | | |
| 2118 | + | |
2118 | 2119 | | |
2119 | 2120 | | |
2120 | 2121 | | |
| |||
2123 | 2124 | | |
2124 | 2125 | | |
2125 | 2126 | | |
2126 | | - | |
| 2127 | + | |
| 2128 | + | |
| 2129 | + | |
| 2130 | + | |
| 2131 | + | |
| 2132 | + | |
2127 | 2133 | | |
2128 | 2134 | | |
2129 | 2135 | | |
| |||
2132 | 2138 | | |
2133 | 2139 | | |
2134 | 2140 | | |
| 2141 | + | |
2135 | 2142 | | |
2136 | 2143 | | |
2137 | 2144 | | |
2138 | 2145 | | |
2139 | 2146 | | |
2140 | 2147 | | |
2141 | | - | |
| 2148 | + | |
| 2149 | + | |
| 2150 | + | |
| 2151 | + | |
| 2152 | + | |
| 2153 | + | |
2142 | 2154 | | |
2143 | 2155 | | |
2144 | 2156 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
838 | 838 | | |
839 | 839 | | |
840 | 840 | | |
841 | | - | |
842 | | - | |
843 | | - | |
| 841 | + | |
| 842 | + | |
| 843 | + | |
844 | 844 | | |
845 | 845 | | |
846 | 846 | | |
| |||
0 commit comments