there's no need to prematurely convert the condition into registers before emitting the test.
Unified · Split
| @@ -5797,19 +5797,6 @@ static void expr_cond(void) · 5796 unmodified lines | ||
| 5797 | 5797 | } else if (c < 0) { |
| 5798 | 5798 | /* needed to avoid having different registers saved in |
| 5799 | 5799 | each branch */ |
| 5800 | − rc = RC_INT; | |
| 5801 | − if (is_float(vtop->type.t)) { | |
| 5802 | − rc = RC_FLOAT; | |
| 5803 | −#ifdef TCC_TARGET_X86_64 | |
| 5804 | − if ((vtop->type.t & VT_BTYPE) == VT_LDOUBLE) { | |
| 5805 | − rc = RC_ST0; | |
| 5806 | − } | |
| 5807 | −#elif defined TCC_TARGET_RISCV64 | |
| 5808 | − if ((vtop->type.t & VT_BTYPE) == VT_LDOUBLE) | |
| 5809 | − rc = RC_INT; | |
| 5810 | −#endif | |
| 5811 | − } | |
| 5812 | − gv(rc); | |
| 5813 | 5800 | save_regs(1); |
| 5814 | 5801 | gv_dup(); |
| 5815 | 5802 | tt = gvtst(0, 0); |