Fix constant folding logic of setcond2_i32
PATCH 1/1 Fix constant folding logic of setcond2_i32
For setcond2_i32 DST, A_low, A_high, B_low, B_high, TCG_COND_EQ, DST should be 0 as long as either half of A and B are not equal.
Signed-off-by Liren Wei <[email protected]>
--- tcg/optimize.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
tcg/optimize.c +1 -1
@@ -1492,7 +1492,7 @@ void tcg_optimize(TCGContext *s) op->args[2 ], op->args[4 ], TCG_COND_EQ);if (tmp ==0 ) { - goto do_setcond_high; + goto do_setcond_const; }else if (tmp !=1 ) { goto do_default; }
Signature · 1 line
2.33.0
Quoted 13 lines · Liren Wei
For
setcond2_i32DST,A_low,A_high,B_low,B_high,TCG_COND_EQ, DST should be 0 as long as either half of A and B are not equal.Signed-off-by Liren Wei <[email protected]>--- tcg/optimize.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)tcg/optimize.c +0
-0
tcg/optimize.c void tcg_optimize(TCGContext *s) · line 1498
Quoted 8 lines
tcg/optimize.c +1
-1@@ -1492,7 +1492,7 @@ void tcg_optimize(TCGContext *s) op->args[2 ], op->args[4 ], TCG_COND_EQ);if (tmp ==0 ) { - goto do_setcond_high; + goto do_setcond_const; }else if (tmp !=1 ) { goto do_default; }
Just noticed that this has been fixed in new patch series by others, please ignore this. Sorry about that...