Lines Matching refs:scratch

281     Register scratch = temps.Acquire();
282 DCHECK(!AreAliased(object, value, scratch));
283 Ld(scratch, MemOperand(address));
284 Assert(eq, AbortReason::kWrongAddressOrValuePassedToRecordWrite, scratch,
304 value, // Used as scratch.
307 value, // Used as scratch.
347 Register scratch = temps.Acquire();
348 DCHECK(rs != scratch);
349 li(scratch, rt);
350 addu(rd, rs, scratch);
364 Register scratch = temps.Acquire();
365 DCHECK(rs != scratch);
366 li(scratch, rt);
367 daddu(rd, rs, scratch);
383 Register scratch = temps.Acquire();
384 DCHECK(rs != scratch);
387 li(scratch, -rt.immediate());
388 addu(rd, rs, scratch);
391 li(scratch, rt);
392 subu(rd, rs, scratch);
413 Register scratch = temps.Acquire();
414 li(scratch, Operand(-rt.immediate()));
415 Daddu(rd, rs, scratch);
419 Register scratch = temps.Acquire();
420 li(scratch, rt);
421 dsubu(rd, rs, scratch);
432 Register scratch = temps.Acquire();
433 DCHECK(rs != scratch);
434 li(scratch, rt);
435 mul(rd, rs, scratch);
450 Register scratch = temps.Acquire();
451 DCHECK(rs != scratch);
452 li(scratch, rt);
454 mult(rs, scratch);
457 muh(rd, rs, scratch);
473 Register scratch = temps.Acquire();
474 DCHECK(rs != scratch);
475 li(scratch, rt);
477 multu(rs, scratch);
480 muhu(rd, rs, scratch);
496 Register scratch = temps.Acquire();
497 DCHECK(rs != scratch);
498 li(scratch, rt);
500 dmul(rd, rs, scratch);
502 dmult(rs, scratch);
519 Register scratch = temps.Acquire();
520 DCHECK(rs != scratch);
521 li(scratch, rt);
523 dmuh(rd, rs, scratch);
525 dmult(rs, scratch);
537 Register scratch = temps.Acquire();
538 DCHECK(rs != scratch);
539 li(scratch, rt);
540 mult(rs, scratch);
550 Register scratch = temps.Acquire();
551 DCHECK(rs != scratch);
552 li(scratch, rt);
553 dmult(rs, scratch);
563 Register scratch = temps.Acquire();
564 DCHECK(rs != scratch);
565 li(scratch, rt);
566 multu(rs, scratch);
576 Register scratch = temps.Acquire();
577 DCHECK(rs != scratch);
578 li(scratch, rt);
579 dmultu(rs, scratch);
589 Register scratch = temps.Acquire();
590 DCHECK(rs != scratch);
591 li(scratch, rt);
592 div(rs, scratch);
607 Register scratch = temps.Acquire();
608 DCHECK(rs != scratch);
609 li(scratch, rt);
611 div(rs, scratch);
614 div(res, rs, scratch);
630 Register scratch = temps.Acquire();
631 DCHECK(rs != scratch);
632 li(scratch, rt);
634 div(rs, scratch);
637 mod(rd, rs, scratch);
653 Register scratch = temps.Acquire();
654 DCHECK(rs != scratch);
655 li(scratch, rt);
657 divu(rs, scratch);
660 modu(rd, rs, scratch);
671 Register scratch = temps.Acquire();
672 DCHECK(rs != scratch);
673 li(scratch, rt);
674 ddiv(rs, scratch);
686 Register scratch = temps.Acquire();
687 DCHECK(rs != scratch);
688 li(scratch, rt);
689 ddiv(rs, scratch);
698 Register scratch = temps.Acquire();
699 DCHECK(rs != scratch);
700 li(scratch, rt);
701 ddiv(rd, rs, scratch);
712 Register scratch = temps.Acquire();
713 DCHECK(rs != scratch);
714 li(scratch, rt);
715 divu(rs, scratch);
730 Register scratch = temps.Acquire();
731 DCHECK(rs != scratch);
732 li(scratch, rt);
734 divu(rs, scratch);
737 divu(res, rs, scratch);
748 Register scratch = temps.Acquire();
749 DCHECK(rs != scratch);
750 li(scratch, rt);
751 ddivu(rs, scratch);
766 Register scratch = temps.Acquire();
767 DCHECK(rs != scratch);
768 li(scratch, rt);
770 ddivu(rs, scratch);
773 ddivu(res, rs, scratch);
786 Register scratch = temps.Acquire();
787 DCHECK(rs != scratch);
788 li(scratch, rt);
789 ddiv(rs, scratch);
798 Register scratch = temps.Acquire();
799 DCHECK(rs != scratch);
800 li(scratch, rt);
801 dmod(rd, rs, scratch);
814 Register scratch = temps.Acquire();
815 DCHECK(rs != scratch);
816 li(scratch, rt);
817 ddivu(rs, scratch);
826 Register scratch = temps.Acquire();
827 DCHECK(rs != scratch);
828 li(scratch, rt);
829 dmodu(rd, rs, scratch);
843 Register scratch = temps.Acquire();
844 DCHECK(rs != scratch);
845 li(scratch, rt);
846 and_(rd, rs, scratch);
860 Register scratch = temps.Acquire();
861 DCHECK(rs != scratch);
862 li(scratch, rt);
863 or_(rd, rs, scratch);
877 Register scratch = temps.Acquire();
878 DCHECK(rs != scratch);
879 li(scratch, rt);
880 xor_(rd, rs, scratch);
891 Register scratch = temps.Acquire();
892 DCHECK(rs != scratch);
893 li(scratch, rt);
894 nor(rd, rs, scratch);
912 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
913 DCHECK(rs != scratch);
914 li(scratch, rt);
915 slt(rd, rs, scratch);
936 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
937 DCHECK(rs != scratch);
938 li(scratch, rt);
939 sltu(rd, rs, scratch);
950 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
952 DCHECK(rs != scratch);
953 li(scratch, rt);
954 slt(rd, scratch, rs);
965 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
967 DCHECK(rs != scratch);
968 li(scratch, rt);
969 sltu(rd, scratch, rs);
990 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
992 DCHECK(rs != scratch);
993 li(scratch, rt);
994 slt(rd, scratch, rs);
1004 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
1006 DCHECK(rs != scratch);
1007 li(scratch, rt);
1008 sltu(rd, scratch, rs);
1043 Register scratch) {
1048 Register tmp = rd == rt ? scratch : rd;
1056 Register scratch) {
1061 Register tmp = rd == rt ? scratch : rd;
1141 Register scratch = temps.Acquire();
1142 lwr(scratch, MemOperand(rs.rm(), rs.offset() + kMipsLwrOffset));
1143 lwl(scratch, MemOperand(rs.rm(), rs.offset() + kMipsLwlOffset));
1144 mov(rd, scratch);
1187 Register scratch = temps.Acquire();
1188 if (source.rm() == scratch) {
1191 Lbu(scratch, source);
1194 Lbu(scratch, MemOperand(source.rm(), source.offset() + 1));
1198 Lbu(scratch, source);
1201 Lbu(scratch, MemOperand(source.rm(), source.offset() + 1));
1206 or_(rd, rd, scratch);
1221 Register scratch = temps.Acquire();
1222 if (source.rm() == scratch) {
1225 Lbu(scratch, source);
1228 Lbu(scratch, MemOperand(source.rm(), source.offset() + 1));
1232 Lbu(scratch, source);
1235 Lbu(scratch, MemOperand(source.rm(), source.offset() + 1));
1240 or_(rd, rd, scratch);
1244 void TurboAssembler::Ush(Register rd, const MemOperand& rs, Register scratch) {
1247 DCHECK(rs.rm() != scratch);
1248 DCHECK(scratch != at);
1257 if (scratch != rd) {
1258 mov(scratch, rd);
1262 Sb(scratch, source);
1263 srl(scratch, scratch, 8);
1264 Sb(scratch, MemOperand(source.rm(), source.offset() + 1));
1266 Sb(scratch, MemOperand(source.rm(), source.offset() + 1));
1267 srl(scratch, scratch, 8);
1268 Sb(scratch, source);
1289 Register scratch = temps.Acquire();
1290 ldr(scratch, MemOperand(rs.rm(), rs.offset() + kMipsLdrOffset));
1291 ldl(scratch, MemOperand(rs.rm(), rs.offset() + kMipsLdlOffset));
1292 mov(rd, scratch);
1301 Register scratch) {
1303 Lw(scratch, MemOperand(rs.rm(), rs.offset() + kPointerSize / 2));
1304 dsll32(scratch, scratch, 0);
1305 Daddu(rd, rd, scratch);
1326 Register scratch) {
1328 dsrl32(scratch, rd, 0);
1329 Sw(scratch, MemOperand(rs.rm(), rs.offset() + kPointerSize / 2));
1333 Register scratch) {
1338 Ulw(scratch, rs);
1339 mtc1(scratch, fd);
1344 Register scratch) {
1349 mfc1(scratch, fd);
1350 Usw(scratch, rs);
1355 Register scratch) {
1356 DCHECK(scratch != at);
1361 Uld(scratch, rs);
1362 dmtc1(scratch, fd);
1367 Register scratch) {
1368 DCHECK(scratch != at);
1373 dmfc1(scratch, fd);
1374 Usd(scratch, rs);
1475 Register scratch = temps.Acquire();
1476 li(scratch, rs.offset());
1477 daddu(scratch, scratch, rs.rm());
1478 ll(rd, MemOperand(scratch, 0));
1489 Register scratch = temps.Acquire();
1490 li(scratch, rs.offset());
1491 daddu(scratch, scratch, rs.rm());
1492 lld(rd, MemOperand(scratch, 0));
1503 Register scratch = temps.Acquire();
1504 li(scratch, rs.offset());
1505 daddu(scratch, scratch, rs.rm());
1506 sc(rd, MemOperand(scratch, 0));
1517 Register scratch = temps.Acquire();
1518 li(scratch, rs.offset());
1519 daddu(scratch, scratch, rs.rm());
1520 scd(rd, MemOperand(scratch, 0));
2063 Register scratch = temps.Acquire();
2064 Dsubu(scratch, zero_reg, pos);
2065 Dror(dest, dest, scratch);
2245 FPURegister scratch) {
2261 FPURegister scratch) {
2263 Trunc_uw_d(t8, fs, scratch);
2268 FPURegister scratch) {
2270 Trunc_uw_s(t8, fs, scratch);
2275 FPURegister scratch, Register result) {
2277 Trunc_ul_d(t8, fs, scratch, result);
2282 FPURegister scratch, Register result) {
2284 Trunc_ul_s(t8, fs, scratch, result);
2305 FPURegister scratch) {
2306 DCHECK(fs != scratch);
2310 // Load 2^31 into scratch as its float representation.
2314 mtc1(zero_reg, scratch);
2315 mthc1(scratch1, scratch);
2317 // Test if scratch > fd.
2320 CompareF64(OLT, fs, scratch);
2325 sub_d(scratch, fs, scratch);
2326 trunc_w_d(scratch, scratch);
2327 mfc1(rd, scratch);
2334 trunc_w_d(scratch, fs);
2335 mfc1(rd, scratch);
2341 FPURegister scratch) {
2342 DCHECK(fs != scratch);
2346 // Load 2^31 into scratch as its float representation.
2350 mtc1(scratch1, scratch);
2352 // Test if scratch > fs.
2355 CompareF32(OLT, fs, scratch);
2360 sub_s(scratch, fs, scratch);
2361 trunc_w_s(scratch, scratch);
2362 mfc1(rd, scratch);
2369 trunc_w_s(scratch, fs);
2370 mfc1(rd, scratch);
2376 FPURegister scratch, Register result) {
2377 DCHECK(fs != scratch);
2383 Move(scratch, -1.0);
2385 CompareF64(OLE, fs, scratch);
2387 CompareIsNanF64(fs, scratch);
2391 // Load 2^63 into scratch as its double representation.
2393 dmtc1(at, scratch);
2395 // Test if scratch > fs.
2397 CompareF64(OLT, fs, scratch);
2402 sub_d(scratch, fs, scratch);
2403 trunc_l_d(scratch, scratch);
2404 dmfc1(rd, scratch);
2410 trunc_l_d(scratch, fs);
2411 dmfc1(rd, scratch);
2421 dmfc1(result, scratch);
2431 FPURegister scratch, Register result) {
2432 DCHECK(fs != scratch);
2438 Move(scratch, -1.0f);
2440 CompareF32(OLE, fs, scratch);
2442 CompareIsNanF32(fs, scratch);
2447 // Load 2^63 into scratch as its float representation.
2451 mtc1(scratch1, scratch);
2454 // Test if scratch > fs.
2456 CompareF32(OLT, fs, scratch);
2461 sub_s(scratch, fs, scratch);
2462 trunc_l_s(scratch, scratch);
2463 dmfc1(rd, scratch);
2469 trunc_l_s(scratch, fs);
2470 dmfc1(rd, scratch);
2480 dmfc1(result, scratch);
2493 Register scratch = t8;
2495 cfc1(scratch, FCSR);
2499 ctc1(scratch, FCSR);
2505 mfhc1(scratch, src);
2506 Ext(at, scratch, HeapNumber::kExponentShift, HeapNumber::kExponentBits);
2515 srl(at, scratch, 31);
2554 Register scratch = t8;
2556 cfc1(scratch, FCSR);
2560 ctc1(scratch, FCSR);
2569 mfc1(scratch, src);
2570 Ext(at, scratch, kFloat32MantissaBits, kFloat32ExponentBits);
2579 srl(at, scratch, 31);
2617 Register scratch = temps.Acquire();
2620 Lbu(scratch, src);
2621 insert_b(dst, laneidx, scratch);
2624 Lhu(scratch, src);
2625 insert_h(dst, laneidx, scratch);
2628 Lwu(scratch, src);
2629 insert_w(dst, laneidx, scratch);
2632 Ld(scratch, src);
2633 insert_d(dst, laneidx, scratch);
2643 Register scratch = temps.Acquire();
2646 copy_u_b(scratch, src, laneidx);
2647 Sb(scratch, dst);
2650 copy_u_h(scratch, src, laneidx);
2651 Sh(scratch, dst);
2658 copy_u_w(scratch, src, laneidx);
2659 Sw(scratch, dst);
2667 copy_s_d(scratch, src, laneidx);
2668 Sd(scratch, dst);
2715 Register scratch = temps.Acquire();
2718 Lb(scratch, src);
2719 fill_b(dst, scratch);
2722 Lh(scratch, src);
2723 fill_h(dst, scratch);
2726 Lw(scratch, src);
2727 fill_w(dst, scratch);
2730 Ld(scratch, src);
2731 fill_d(dst, scratch);
2761 Register scratch = t8;
2763 cfcmsa(scratch, MSACSR);
2771 ctcmsa(MSACSR, scratch);
2777 Register scratch = t8;
2779 cfcmsa(scratch, MSACSR);
2787 ctcmsa(MSACSR, scratch);
2791 FPURegister ft, FPURegister scratch) {
2792 DCHECK(fr != scratch && fs != scratch && ft != scratch);
2793 mul_s(scratch, fs, ft);
2794 add_s(fd, fr, scratch);
2798 FPURegister ft, FPURegister scratch) {
2799 DCHECK(fr != scratch && fs != scratch && ft != scratch);
2800 mul_d(scratch, fs, ft);
2801 add_d(fd, fr, scratch);
2805 FPURegister ft, FPURegister scratch) {
2806 DCHECK(fr != scratch && fs != scratch && ft != scratch);
2807 mul_s(scratch, fs, ft);
2808 sub_s(fd, scratch, fr);
2812 FPURegister ft, FPURegister scratch) {
2813 DCHECK(fr != scratch && fs != scratch && ft != scratch);
2814 mul_d(scratch, fs, ft);
2815 sub_d(fd, scratch, fr);
2963 Register scratch = temps.Acquire();
2964 DCHECK(src_low != scratch);
2965 mfhc1(scratch, dst);
2967 mthc1(scratch, dst);
2972 Register scratch = temps.Acquire();
2973 li(scratch, Operand(static_cast<int32_t>(src)));
2974 mtc1(scratch, dst);
2990 Register scratch = temps.Acquire();
2991 li(scratch, Operand(lo));
2992 mtc1(scratch, dst);
3000 Register scratch = temps.Acquire();
3001 li(scratch, Operand(hi));
3002 mthc1(scratch, dst);
3185 Register scratch = temps.Acquire();
3186 Daddu(scratch, rs, -1);
3187 Xor(rd, scratch, rs);
3188 And(rd, rd, scratch);
3193 li(scratch, 32);
3194 Subu(rd, scratch, rd);
3211 Register scratch = temps.Acquire();
3212 Daddu(scratch, rs, -1);
3213 Xor(rd, scratch, rs);
3214 And(rd, rd, scratch);
3219 li(scratch, 64);
3220 Dsubu(rd, scratch, rd);
3256 Register scratch = temps.Acquire();
3258 srl(scratch, rs, 1);
3260 And(scratch, scratch, scratch2);
3261 Subu(scratch, rs, scratch);
3263 And(rd, scratch, scratch2);
3264 srl(scratch, scratch, 2);
3265 And(scratch, scratch, scratch2);
3266 Addu(scratch, rd, scratch);
3267 srl(rd, scratch, 4);
3268 Addu(rd, rd, scratch);
3271 li(scratch, value);
3272 Mul(rd, rd, scratch);
3286 Register scratch = temps.Acquire();
3288 dsrl(scratch, rs, 1);
3290 And(scratch, scratch, scratch2);
3291 Dsubu(scratch, rs, scratch);
3293 And(rd, scratch, scratch2);
3294 dsrl(scratch, scratch, 2);
3295 And(scratch, scratch, scratch2);
3296 Daddu(scratch, rd, scratch);
3297 dsrl(rd, scratch, 4);
3298 Daddu(rd, rd, scratch);
3301 li(scratch, value);
3302 Dmul(rd, rd, scratch);
3311 Register scratch = t9;
3317 cfc1(scratch, FCSR);
3319 And(scratch, scratch,
3323 Branch(done, eq, scratch, Operand(zero_reg));
3426 Register scratch = temps.Acquire();
3427 LoadRoot(scratch, index);
3428 Branch(L, cond, rs, Operand(scratch), bdslot);
3475 Register scratch) {
3480 r2 = scratch;
3495 Register* scratch, const Operand& rt) {
3497 *scratch = GetRtAsRegisterHelper(rt, *scratch);
3508 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
3524 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3526 beq(rs, scratch, offset);
3532 // We don't want any other register but scratch clobbered.
3533 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3535 beqc(rs, scratch, offset);
3542 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3544 bne(rs, scratch, offset);
3550 // We don't want any other register but scratch clobbered.
3551 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3553 bnec(rs, scratch, offset);
3563 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3565 bltzc(scratch, offset);
3570 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3572 DCHECK(rs != scratch);
3573 bltc(scratch, rs, offset);
3582 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3584 blezc(scratch, offset);
3589 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3591 DCHECK(rs != scratch);
3592 bgec(rs, scratch, offset);
3600 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3602 bgtzc(scratch, offset);
3607 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3609 DCHECK(rs != scratch);
3610 bltc(rs, scratch, offset);
3619 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3621 bgezc(scratch, offset);
3626 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3628 DCHECK(rs != scratch);
3629 bgec(scratch, rs, offset);
3639 if (!CalculateOffset(L, &offset, OffsetSize::kOffset21, &scratch, rt))
3641 bnezc(scratch, offset);
3646 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3648 DCHECK(rs != scratch);
3649 bltuc(scratch, rs, offset);
3658 if (!CalculateOffset(L, &offset, OffsetSize::kOffset21, &scratch, rt))
3660 beqzc(scratch, offset);
3665 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3667 DCHECK(rs != scratch);
3668 bgeuc(rs, scratch, offset);
3676 if (!CalculateOffset(L, &offset, OffsetSize::kOffset21, &scratch, rt))
3678 bnezc(scratch, offset);
3682 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3684 DCHECK(rs != scratch);
3685 bltuc(rs, scratch, offset);
3694 if (!CalculateOffset(L, &offset, OffsetSize::kOffset26, &scratch, rt))
3701 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
3703 DCHECK(rs != scratch);
3704 bgeuc(scratch, rs, offset);
3723 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
3741 // We don't want any other register but scratch clobbered.
3742 scratch = GetRtAsRegisterHelper(rt, scratch);
3744 beq(rs, scratch, offset32);
3752 // We don't want any other register but scratch clobbered.
3753 scratch = GetRtAsRegisterHelper(rt, scratch);
3755 bne(rs, scratch, offset32);
3765 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
3767 bne(scratch, zero_reg, offset32);
3775 Slt(scratch, rs, rt);
3777 beq(scratch, zero_reg, offset32);
3785 Slt(scratch, rs, rt);
3787 bne(scratch, zero_reg, offset32);
3795 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
3797 beq(scratch, zero_reg, offset32);
3807 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
3809 bne(scratch, zero_reg, offset32);
3817 Sltu(scratch, rs, rt);
3819 beq(scratch, zero_reg, offset32);
3826 Sltu(scratch, rs, rt);
3828 bne(scratch, zero_reg, offset32);
3836 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
3838 beq(scratch, zero_reg, offset32);
3975 Register scratch = temps.hasAvailable() ? temps.Acquire() : t8;
3987 Subu(scratch, rs, rt);
3989 beqzalc(scratch, offset);
3993 Subu(scratch, rs, rt);
3995 bnezalc(scratch, offset);
4004 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
4006 bltzalc(scratch, offset);
4012 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4014 bnezalc(scratch, offset);
4023 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
4025 blezalc(scratch, offset);
4031 Slt(scratch, rs, rt);
4033 beqzalc(scratch, offset);
4041 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
4043 bgtzalc(scratch, offset);
4049 Slt(scratch, rs, rt);
4051 bnezalc(scratch, offset);
4060 if (!CalculateOffset(L, &offset, OffsetSize::kOffset16, &scratch, rt))
4062 bgezalc(scratch, offset);
4068 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4070 beqzalc(scratch, offset);
4078 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4080 bnezalc(scratch, offset);
4085 Sltu(scratch, rs, rt);
4087 beqzalc(scratch, offset);
4092 Sltu(scratch, rs, rt);
4094 bnezalc(scratch, offset);
4099 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4101 beqzalc(scratch, offset);
4119 Register scratch = t8;
4128 bne(rs, GetRtAsRegisterHelper(rt, scratch), 2);
4134 beq(rs, GetRtAsRegisterHelper(rt, scratch), 2);
4142 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4143 addiu(scratch, scratch, -1);
4145 bgezal(scratch, offset);
4148 Slt(scratch, rs, rt);
4149 addiu(scratch, scratch, -1);
4151 bltzal(scratch, offset);
4154 Slt(scratch, rs, rt);
4155 addiu(scratch, scratch, -1);
4157 bgezal(scratch, offset);
4160 Slt(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4161 addiu(scratch, scratch, -1);
4163 bltzal(scratch, offset);
4168 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4169 addiu(scratch, scratch, -1);
4171 bgezal(scratch, offset);
4174 Sltu(scratch, rs, rt);
4175 addiu(scratch, scratch, -1);
4177 bltzal(scratch, offset);
4180 Sltu(scratch, rs, rt);
4181 addiu(scratch, scratch, -1);
4183 bgezal(scratch, offset);
4186 Sltu(scratch, GetRtAsRegisterHelper(rt, scratch), rs);
4187 addiu(scratch, scratch, -1);
4189 bltzal(scratch, offset);
4360 Register scratch = temps.Acquire();
4361 Dsubu(scratch, value, Operand(lower_limit));
4362 Branch(on_in_range, ls, scratch, Operand(higher_limit - lower_limit));
4440 Register scratch = temps.Acquire();
4441 mov(scratch, ra);
4446 mov(ra, scratch); // in delay slot
4567 ArgumentsCountMode mode, Register scratch) {
4575 DCHECK_NE(scratch, no_reg);
4576 SmiScale(scratch, count, kPointerSizeLog2);
4577 Daddu(sp, sp, scratch);
4594 Register scratch) {
4598 DropArguments(argc, type, kCountIncludesReceiver, scratch);
4601 DropArguments(argc, type, mode, scratch);
4615 Register scratch = temps.Acquire();
4616 li(scratch, drop_size);
4618 daddu(sp, sp, scratch);
4657 void MacroAssembler::Swap(Register reg1, Register reg2, Register scratch) {
4658 if (scratch == no_reg) {
4663 mov(scratch, reg1);
4665 mov(reg2, scratch);
4678 Register scratch = temps.Acquire();
4679 li(scratch, Operand(smi));
4680 push(scratch);
4685 Register scratch = temps.Acquire();
4686 li(scratch, Operand(handle));
4687 push(scratch);
4690 void TurboAssembler::PushArray(Register array, Register size, Register scratch,
4692 DCHECK(!AreAliased(array, size, scratch, scratch2));
4695 mov(scratch, zero_reg);
4698 Dlsa(scratch2, array, scratch, kPointerSizeLog2);
4701 Daddu(scratch, scratch, Operand(1));
4703 Branch(&loop, less, scratch, Operand(size));
4705 mov(scratch, size);
4708 Dlsa(scratch2, array, scratch, kPointerSizeLog2);
4712 Daddu(scratch, scratch, Operand(-1));
4713 Branch(&loop, greater_equal, scratch, Operand(zero_reg));
4744 Register scratch = temps.Acquire();
4745 li(scratch,
4747 Sd(a1, MemOperand(scratch));
5082 Register scratch = t8;
5090 DCHECK(left != scratch && right_reg != scratch && dst != scratch &&
5091 overflow != scratch);
5095 daddu(scratch, left, right_reg);
5096 xor_(overflow, scratch, left);
5097 xor_(at, scratch, right_reg);
5099 mov(dst, scratch);
5113 Register scratch = t8;
5121 DCHECK(left != scratch && right_reg != scratch && dst != scratch &&
5122 overflow != scratch);
5126 dsubu(scratch, left, right_reg);
5127 xor_(overflow, left, scratch);
5130 mov(dst, scratch);
5144 Register scratch = t8;
5152 DCHECK(left != scratch && right_reg != scratch && dst != scratch &&
5153 overflow != scratch);
5157 Mul(scratch, left, right_reg);
5159 mov(dst, scratch);
5165 dsra32(scratch, dst, 0);
5166 xor_(overflow, overflow, scratch);
5337 Register scratch = temps.Acquire();
5338 li(scratch, Operand(StackFrame::TypeToMarker(type)));
5339 PushCommonFrame(scratch);
5391 Register scratch = temps.Acquire();
5392 li(scratch, Operand(StackFrame::TypeToMarker(frame_type)));
5393 Sd(scratch, MemOperand(sp, 1 * kPointerSize));
5439 Register scratch = temps.Acquire();
5440 daddiu(scratch, sp, kPointerSize);
5441 Sd(scratch, MemOperand(fp, ExitFrameConstants::kSPOffset));
5474 Register scratch = temp.Acquire();
5475 li(scratch, Operand(Context::kInvalidContext));
5476 Sd(scratch, MemOperand(t8));
5526 Register scratch = temps.Acquire();
5527 andi(scratch, sp, frame_alignment_mask);
5528 Branch(&alignment_as_expected, eq, scratch, Operand(zero_reg));
5551 Register scratch = temps.Acquire();
5552 andi(scratch, value, kSmiTagMask);
5553 Branch(bd, smi_label, eq, scratch, Operand(zero_reg));
5560 Register scratch = temps.Acquire();
5561 andi(scratch, value, kSmiTagMask);
5562 Branch(bd, not_smi_label, ne, scratch, Operand(zero_reg));
5570 Register scratch = temps.Acquire();
5571 andi(scratch, object, kSmiTagMask);
5572 Check(ne, AbortReason::kOperandIsASmi, scratch, Operand(zero_reg));
5581 Register scratch = temps.Acquire();
5582 andi(scratch, object, kSmiTagMask);
5583 Check(eq, AbortReason::kOperandIsASmi, scratch, Operand(zero_reg));
5680 Register scratch) {
5685 LoadRoot(scratch, RootIndex::kUndefinedValue);
5686 Branch(&done_checking, eq, object, Operand(scratch));
5687 GetObjectType(object, scratch, scratch);
5688 Assert(eq, AbortReason::kExpectedUndefinedOrCell, scratch,
5914 Register scratch) {
5930 mov(scratch, sp);
5934 Sd(scratch, MemOperand(sp, stack_passed_arguments * kPointerSize));
5941 Register scratch) {
5942 PrepareCallCFunction(num_reg_arguments, 0, scratch);
5989 Register scratch = temps.Acquire();
5990 And(scratch, sp, Operand(frame_alignment_mask));
5991 Branch(&alignment_as_expected, eq, scratch, Operand(zero_reg));
6013 // 't' registers are caller-saved so this is safe as a scratch register.
6015 Register scratch = t2;
6016 DCHECK(!AreAliased(pc_scratch, scratch, function));
6018 mov(scratch, ra);
6021 mov(ra, scratch);
6031 li(scratch, ExternalReference::fast_c_call_caller_pc_address(isolate()));
6032 Sd(pc_scratch, MemOperand(scratch));
6033 li(scratch, ExternalReference::fast_c_call_caller_fp_address(isolate()));
6034 Sd(fp, MemOperand(scratch));
6045 li(scratch, ExternalReference::fast_c_call_caller_fp_address(isolate()));
6046 Sd(zero_reg, MemOperand(scratch));
6064 void TurboAssembler::CheckPageFlag(Register object, Register scratch, int mask,
6067 And(scratch, object, Operand(~kPageAlignmentMask));
6068 Ld(scratch, MemOperand(scratch, BasicMemoryChunk::kFlagsOffset));
6069 And(scratch, scratch, Operand(mask));
6070 Branch(condition_met, cc, scratch, Operand(zero_reg));
6136 Register scratch = kScratchReg;
6137 DCHECK(!AreAliased(destination, scratch));
6138 DCHECK(!AreAliased(code_object, scratch));
6143 Lw(scratch, FieldMemOperand(code_object, Code::kFlagsOffset));
6144 And(scratch, scratch, Operand(Code::IsOffHeapTrampoline::kMask));
6145 Branch(&if_code_is_off_heap, ne, scratch, Operand(zero_reg));
6155 Lw(scratch, FieldMemOperand(code_object, Code::kBuiltinIndexOffset));
6156 Dlsa(destination, kRootRegister, scratch, kSystemPointerSizeLog2);