tvm_tirx.ir.prim.if_then_else#
- tvm_tirx.ir.prim.if_then_else(cond, t, f, loc=UNKNOWN_LOC)#
Conditional selection expression.
- Parameters:
- Returns:
result (Node) – The result of conditional expression.
Note
Unlike Select, if_then_else will not execute the branch that does not satisfy the condition. You can use it to guard against out of bound access. Unlike Select, if_then_else cannot be vectorized if some lanes in the vector have different conditions.