1) select c, x, x => x
| 5189 | |
| 5190 | // 1) select c, x, x => x |
| 5191 | static OpFoldResult tryFoldSelectSameOperands(SelectOp op, |
| 5192 | SelectOp::FoldAdaptor adaptor) { |
| 5193 | Value t = op.getValIfTrue(); |
| 5194 | Value f = op.getValIfFalse(); |
| 5195 | if (t == f) |
| 5196 | return t; |
| 5197 | return {}; |
| 5198 | } |
| 5199 | |
| 5200 | // 2) select true, x, y => x |
| 5201 | // select false, x, y => y |
nothing calls this directly
no outgoing calls
no test coverage detected