File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -2169,7 +2169,9 @@ void c_typecheck_baset::typecheck_side_effect_function_call(
21692169 }
21702170 else if (
21712171 identifier == CPROVER_PREFIX " saturating_minus" ||
2172- identifier == CPROVER_PREFIX " saturating_plus" )
2172+ identifier == CPROVER_PREFIX " saturating_plus" ||
2173+ identifier == " __builtin_elementwise_add_sat" ||
2174+ identifier == " __builtin_elementwise_sub_sat" )
21732175 {
21742176 exprt result = typecheck_saturating_arithmetic (expr);
21752177 expr.swap (result);
@@ -3842,10 +3844,18 @@ exprt c_typecheck_baset::typecheck_saturating_arithmetic(
38423844 }
38433845
38443846 exprt result;
3845- if (identifier == CPROVER_PREFIX " saturating_minus" )
3847+ if (
3848+ identifier == CPROVER_PREFIX " saturating_minus" ||
3849+ identifier == " __builtin_elementwise_sub_sat" )
3850+ {
38463851 result = saturating_minus_exprt{expr.arguments ()[0 ], expr.arguments ()[1 ]};
3847- else if (identifier == CPROVER_PREFIX " saturating_plus" )
3852+ }
3853+ else if (
3854+ identifier == CPROVER_PREFIX " saturating_plus" ||
3855+ identifier == " __builtin_elementwise_add_sat" )
3856+ {
38483857 result = saturating_plus_exprt{expr.arguments ()[0 ], expr.arguments ()[1 ]};
3858+ }
38493859 else
38503860 UNREACHABLE;
38513861
You can’t perform that action at this time.
0 commit comments