File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -1649,6 +1649,17 @@ simplify_exprt::resultt<> simplify_exprt::simplify_object(const exprt &expr)
16491649simplify_exprt::resultt<>
16501650simplify_exprt::simplify_byte_extract (const byte_extract_exprt &expr)
16511651{
1652+ // lift up any ID_if on the object
1653+ if (expr.op ().id () == ID_if)
1654+ {
1655+ if_exprt if_expr = lift_if (expr, 0 );
1656+ if_expr.true_case () =
1657+ simplify_byte_extract (to_byte_extract_expr (if_expr.true_case ()));
1658+ if_expr.false_case () =
1659+ simplify_byte_extract (to_byte_extract_expr (if_expr.false_case ()));
1660+ return changed (simplify_if (if_expr));
1661+ }
1662+
16521663 const auto el_size = pointer_offset_bits (expr.type (), ns);
16531664 if (el_size.has_value () && *el_size < 0 )
16541665 return unchanged (expr);
You can’t perform that action at this time.
0 commit comments