diff -rud tcc-0.9.24-immed4/tcc.c tcc-0.9.24-my/tcc.c --- tcc-0.9.24-immed4/tcc.c Fri Sep 5 18:13:54 2008 +++ tcc-0.9.24-my/tcc.c Fri Sep 5 04:21:19 2008 @@ -4975,6 +4975,9 @@ #endif r = vtop->r & VT_VALMASK; + rc2 = RC_INT; + if (rc == RC_IRET) + rc2 = RC_LRET; /* need to reload if: - constant - lvalue (need to dereference pointer) @@ -4983,7 +4986,7 @@ (vtop->r & VT_LVAL) || !(reg_classes[r] & rc) || ((vtop->type.t & VT_BTYPE) == VT_LLONG && - !(reg_classes[vtop->r2] & rc))) { + !(reg_classes[vtop->r2] & rc2))) { r = get_reg(rc); if ((vtop->type.t & VT_BTYPE) == VT_LLONG) { /* two register type load : expand to two words @@ -5020,9 +5023,6 @@ vtop->r = vtop[-1].r2; } /* allocate second register */ - rc2 = RC_INT; - if (rc == RC_IRET) - rc2 = RC_LRET; r2 = get_reg(rc2); load(r2, vtop); vpop();