Lines Matching defs:__
48 #define __ masm->
130 __ stx(O0, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8);
131 __ stx(O1, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8);
132 __ stx(O2, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+2*8);
133 __ stx(O3, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+3*8);
134 __ stx(O4, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+4*8);
135 __ stx(O5, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+5*8);
138 __ save(SP, -frame_size, SP);
144 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8, O0);
145 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8, O1);
146 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+2*8, O2);
147 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+3*8, O3);
148 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+4*8, O4);
149 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+5*8, O5);
151 __ stx(O0, SP, o0_offset+STACK_BIAS);
154 __ stx(O1, SP, o1_offset+STACK_BIAS);
158 __ stx(O2, SP, o2_offset+STACK_BIAS);
161 __ stx(O3, SP, o3_offset+STACK_BIAS);
164 __ stx(O4, SP, o4_offset+STACK_BIAS);
167 __ stx(O5, SP, o5_offset+STACK_BIAS);
178 __ stx(G1, SP, g1_offset+STACK_BIAS);
181 __ stx(G3, SP, g3_offset+STACK_BIAS);
184 __ stx(G4, SP, g4_offset+STACK_BIAS);
187 __ stx(G5, SP, g5_offset+STACK_BIAS);
208 __ rdccr( G5 );
209 __ stx(G5, SP, ccr_offset+STACK_BIAS);
210 __ stxfsr(SP, fsr_offset+STACK_BIAS);
216 __ stf(FloatRegisterImpl::D, f, SP, offset+STACK_BIAS);
235 __ ldf(FloatRegisterImpl::D, SP, d00_offset+i*sizeof(float)+STACK_BIAS, as_FloatRegister(i));
238 __ ldx(SP, ccr_offset+STACK_BIAS, G1);
239 __ wrccr (G1) ;
245 __ ldx(SP, g1_offset+STACK_BIAS, G1);
246 __ ldx(SP, g3_offset+STACK_BIAS, G3);
247 __ ldx(SP, g4_offset+STACK_BIAS, G4);
248 __ ldx(SP, g5_offset+STACK_BIAS, G5);
253 __ ldx(SP, o0_offset+STACK_BIAS, O0);
254 __ ldx(SP, o1_offset+STACK_BIAS, O1);
255 __ ldx(SP, o2_offset+STACK_BIAS, O2);
256 __ ldx(SP, o3_offset+STACK_BIAS, O3);
257 __ ldx(SP, o4_offset+STACK_BIAS, O4);
258 __ ldx(SP, o5_offset+STACK_BIAS, O5);
262 __ stx(O0, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8);
263 __ stx(O1, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8);
264 __ stx(O2, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+2*8);
265 __ stx(O3, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+3*8);
266 __ stx(O4, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+4*8);
267 __ stx(O5, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+5*8);
272 __ ldxfsr(SP, fsr_offset+STACK_BIAS);
274 __ restore();
278 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8, O0);
279 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8, O1);
280 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+2*8, O2);
281 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+3*8, O3);
282 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+4*8, O4);
283 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+5*8, O5);
294 __ ldx(SP, g1_offset+STACK_BIAS, G1);
297 __ ldx(SP, o0_offset+STACK_BIAS, O0);
298 __ ldx(SP, o1_offset+STACK_BIAS, O1);
300 __ stx(O0, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8);
301 __ stx(O1, G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8);
304 __ ldf(FloatRegisterImpl::D, SP, d00_offset+STACK_BIAS, as_FloatRegister(0));
306 __ restore();
310 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+0*8, O0);
311 __ ldx(G2_thread, JavaThread::o_reg_temps_offset_in_bytes()+1*8, O1);
529 __ ld_ptr(G5_method, in_bytes(methodOopDesc::code_offset()), G3_scratch);
530 __ br_null(G3_scratch, false, Assembler::pt, L);
531 __ delayed()->nop();
533 __ save_frame(4); // Args in compiled layout; do not blow them
546 __ mov(G1, L1);
547 __ mov(G4, L4);
548 __ mov(G5_method, L5);
549 __ mov(G5_method, O0); // VM needs target method
550 __ mov(I7, O1); // VM needs caller's callsite
554 __ relocate(relocInfo::runtime_call_type);
555 __ jumpl_to(dest, O7, O7);
556 __ delayed()->mov(G2_thread, L7_thread_cache);
557 __ mov(L7_thread_cache, G2_thread);
558 __ mov(L1, G1);
559 __ mov(L4, G4);
560 __ mov(L5, G5_method);
562 __ stx(G1, FP, -8 + STACK_BIAS);
563 __ stx(G4, FP, -16 + STACK_BIAS);
564 __ mov(G5_method, L5);
565 __ mov(G5_method, O0); // VM needs target method
566 __ mov(I7, O1); // VM needs caller's callsite
568 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::fixup_callers_callsite), relocInfo::runtime_call_type);
569 __ delayed()->mov(G2_thread, L7_thread_cache);
570 __ mov(L7_thread_cache, G2_thread);
571 __ ldx(FP, -8 + STACK_BIAS, G1);
572 __ ldx(FP, -16 + STACK_BIAS, G4);
573 __ mov(L5, G5_method);
576 __ restore(); // Restore args
577 __ bind(L);
583 return __ ensure_simm13_or_reg(roc, Rdisp);
588 return __ ensure_simm13_or_reg(roc, Rdisp);
598 __ stx(r, base, next_arg_slot(st_off));
602 __ stw(r, base, arg_slot(st_off)); // lo bits
603 __ srlx(r, 32, r);
604 __ stw(r, base, next_arg_slot(st_off)); // hi bits
608 __ stw(r, base, arg_slot(st_off)); // lo bits
609 __ srlx(r, 32, r);
610 __ stw(r, base, next_arg_slot(st_off)); // hi bits
612 __ stw(r->successor(), base, arg_slot(st_off) ); // lo bits
613 __ stw(r , base, next_arg_slot(st_off)); // hi bits
621 __ st_ptr (r, base, arg_slot(st_off));
626 __ st (r, base, arg_slot(st_off));
635 __ stf(FloatRegisterImpl::D, r_1->as_FloatRegister(), base, next_arg_slot(st_off));
638 __ stf(FloatRegisterImpl::S, r_1->as_FloatRegister(), base, next_arg_slot(st_off));
639 __ stf(FloatRegisterImpl::S, r_2->as_FloatRegister(), base, arg_slot(st_off) );
645 __ stf(FloatRegisterImpl::S, f, base, arg_slot(st_off));
675 __ bind(L_skip_fixup);
692 __ sub(SP, __ ensure_simm13_or_reg(extraspace, G3_scratch), SP);
706 ld_off = __ ensure_simm13_or_reg(ld_off, Rdisp);
708 if (!r_2->is_valid()) __ ld (base, ld_off, G1_scratch);
709 else __ ldx(base, ld_off, G1_scratch);
733 __ ld_ptr(G5_method, in_bytes(methodOopDesc::interpreter_entry_offset()), G3_scratch);
737 __ add(SP, __ ensure_simm13_or_reg(extraspace, G1), O5_savedSP);
739 __ mov((frame::varargs_offset)*wordSize -
742 __ jmpl(G3_scratch, 0, G0);
747 __ delayed()->add(SP, G1, Gargs);
754 __ set(ExternalAddress(code_start), temp_reg);
755 __ set(pointer_delta(code_end, code_start, 1), temp2_reg);
756 __ cmp(pc_reg, temp_reg);
757 __ brx(Assembler::lessEqualUnsigned, false, Assembler::pn, L_fail);
758 __ delayed()->add(temp_reg, temp2_reg, temp_reg);
759 __ cmp(pc_reg, temp_reg);
760 __ cmp_and_brx_short(pc_reg, temp_reg, Assembler::lessUnsigned, Assembler::pt, L_ok);
761 __ bind(L_fail);
809 __ block_comment("verify_i2c { ");
824 __ block_comment(msg);
825 __ stop(msg);
826 __ bind(L_ok);
827 __ block_comment("} verify_i2ce ");
853 __ sub(Gargs, BytesPerWord, Gargs);
913 __ sub(SP, (comp_words_on_stack)*wordSize, SP);
947 __ ld(Gargs, arg_slot(ld_off), r);
954 __ ldx(Gargs, slot, r);
962 __ ldf(FloatRegisterImpl::S, Gargs, arg_slot(ld_off), r_1->as_FloatRegister());
971 __ ldf(FloatRegisterImpl::D, Gargs, slot, r_1->as_FloatRegister());
974 __ ldf(FloatRegisterImpl::S, Gargs, next_arg_slot(ld_off), r_1->as_FloatRegister());
975 __ ldf(FloatRegisterImpl::S, Gargs, arg_slot(ld_off), r_2->as_FloatRegister());
986 RegisterOrConstant slot = __ ensure_simm13_or_reg(st_off, Rdisp);
987 if (!r_2->is_valid()) __ stf(FloatRegisterImpl::S, r_1->as_FloatRegister(), SP, slot);
988 else __ stf(FloatRegisterImpl::D, r_1->as_FloatRegister(), SP, slot);
993 __ ld_ptr(G5_method, in_bytes(methodOopDesc::from_compiled_offset()), G3);
1005 __ st_ptr(G5_method, callee_target_addr);
1009 __ save_frame(0);
1010 __ mov(G0, L0);
1012 __ bind(loop);
1013 __ sub(L0, 1, L0);
1014 __ br_null_short(L0, Assembler::pt, loop);
1015 __ restore();
1018 __ jmpl(G3, 0, G0);
1019 __ delayed()->nop();
1030 address i2c_entry = __ pc();
1046 address c2i_unverified_entry = __ pc();
1053 __ verify_oop(O0);
1054 __ verify_oop(G5_method);
1055 __ load_klass(O0, G3_scratch);
1056 __ verify_oop(G3_scratch);
1058 __ ld_ptr(G5_method, compiledICHolderOopDesc::holder_klass_offset(), R_temp);
1059 __ verify_oop(R_temp);
1060 __ cmp(G3_scratch, R_temp);
1063 __ brx(Assembler::equal, false, Assembler::pt, ok);
1064 __ delayed()->ld_ptr(G5_method, compiledICHolderOopDesc::holder_method_offset(), G5_method);
1065 __ jump_to(ic_miss, G3_scratch);
1066 __ delayed()->nop();
1068 __ bind(ok);
1072 __ ld_ptr(G5_method, in_bytes(methodOopDesc::code_offset()), G3_scratch);
1073 __ bind(ok2);
1074 __ br_null(G3_scratch, false, Assembler::pt, L_skip_fixup);
1075 __ delayed()->nop();
1076 __ jump_to(ic_miss, G3_scratch);
1077 __ delayed()->nop();
1081 address c2i_entry = __ pc();
1085 __ flush();
1238 __ stf(FloatRegisterImpl::S, F0, SP, frame_slots*VMRegImpl::stack_slot_size - 4+STACK_BIAS);
1241 __ stf(FloatRegisterImpl::D, F0, SP, frame_slots*VMRegImpl::stack_slot_size - 8+STACK_BIAS);
1249 __ ldf(FloatRegisterImpl::S, SP, frame_slots*VMRegImpl::stack_slot_size - 4+STACK_BIAS, F0);
1252 __ ldf(FloatRegisterImpl::D, SP, frame_slots*VMRegImpl::stack_slot_size - 8+STACK_BIAS, F0);
1263 __ br_null(Rex_oop, false, Assembler::pt, L);
1264 __ delayed()->mov(L7_thread_cache, G2_thread); // restore in case we have exception
1270 __ jump_to(exception_entry, G3_scratch);
1271 __ delayed()->restore(); // Pop this frame off.
1272 __ bind(L);
1280 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, L5);
1281 __ st(L5, SP, reg2offset(dst.first()) + STACK_BIAS);
1284 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1288 __ st(src.first()->as_Register(), SP, reg2offset(dst.first()) + STACK_BIAS);
1290 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1302 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, L5);
1303 __ st_ptr(L5, SP, reg2offset(dst.first()) + STACK_BIAS);
1306 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1310 __ st_ptr(src.first()->as_Register(), SP, reg2offset(dst.first()) + STACK_BIAS);
1312 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1321 __ ld_ptr(FP, reg2offset(src.first()) + STACK_BIAS, L5);
1322 __ st_ptr(L5, SP, reg2offset(dst.first()) + STACK_BIAS);
1325 __ ld_ptr(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1329 __ st_ptr(src.first()->as_Register(), SP, reg2offset(dst.first()) + STACK_BIAS);
1331 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1351 __ add(FP, reg2offset(src.first()) + STACK_BIAS, rHandle);
1352 __ ld_ptr(rHandle, 0, L4);
1354 __ movr( Assembler::rc_z, L4, G0, rHandle );
1356 __ tst( L4 );
1357 __ movcc( Assembler::zero, false, Assembler::icc, G0, rHandle );
1360 __ st_ptr(rHandle, SP, reg2offset(dst.first()) + STACK_BIAS);
1374 __ st_ptr(rOop, SP, offset + STACK_BIAS);
1379 __ add(SP, offset + STACK_BIAS, rHandle);
1381 __ movr( Assembler::rc_z, rOop, G0, rHandle );
1383 __ tst( rOop );
1384 __ movcc( Assembler::zero, false, Assembler::icc, G0, rHandle );
1388 __ st_ptr(rHandle, SP, reg2offset(dst.first()) + STACK_BIAS);
1390 __ mov(rHandle, dst.first()->as_Register());
1402 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, L5);
1403 __ st(L5, SP, reg2offset(dst.first()) + STACK_BIAS);
1407 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1409 __ ldf(FloatRegisterImpl::S, FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_FloatRegister());
1415 __ st(src.first()->as_Register(), SP, reg2offset(dst.first()) + STACK_BIAS);
1417 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(), SP, reg2offset(dst.first()) + STACK_BIAS);
1424 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1427 __ st(src.first()->as_Register(), FP, -4 + STACK_BIAS);
1428 __ ldf(FloatRegisterImpl::S, FP, -4 + STACK_BIAS, dst.first()->as_FloatRegister());
1432 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(), FP, -4 + STACK_BIAS);
1433 __ ld(FP, -4 + STACK_BIAS, dst.first()->as_Register());
1438 __ fmov(FloatRegisterImpl::S, src.first()->as_FloatRegister(), dst.first()->as_FloatRegister());
1459 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1466 __ srax(src.first()->as_Register(), 32, dst.first()->as_Register());
1474 __ srax(src.first()->as_Register(), 32, L4);
1480 __ ldx(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1506 __ sllx(split.first()->as_Register(), 32, L5);
1509 __ or3(L5, d, d);
1534 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, L5);
1535 __ ld(FP, reg2offset(src.second()) + STACK_BIAS, L4);
1536 __ st(L5, SP, reg2offset(dst.first()) + STACK_BIAS);
1537 __ st(L4, SP, reg2offset(dst.second()) + STACK_BIAS);
1542 __ ld(FP, reg2offset(src.second()) + STACK_BIAS, L4);
1544 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1546 __ ldf(FloatRegisterImpl::S, FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_FloatRegister());
1549 __ st(L4, SP, reg2offset(dst.second()) + STACK_BIAS);
1554 __ ld(FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_Register());
1555 __ ld(FP, reg2offset(src.second()) + STACK_BIAS, dst.second()->as_Register());
1557 __ ldf(FloatRegisterImpl::S, FP, reg2offset(src.first()) + STACK_BIAS, dst.first()->as_FloatRegister());
1558 __ ldf(FloatRegisterImpl::S, FP, reg2offset(src.second()) + STACK_BIAS, dst.second()->as_FloatRegister());
1566 __ st(src.first()->as_Register(), SP, reg2offset(dst.first()) + STACK_BIAS);
1568 __ ld(FP, reg2offset(src.second()) + STACK_BIAS, L4);
1569 __ st(L4, SP, reg2offset(dst.second()) + STACK_BIAS);
1571 __ st(src.second()->as_Register(), SP, reg2offset(dst.second()) + STACK_BIAS);
1581 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(), SP, reg2offset(dst.first()) + STACK_BIAS);
1582 __ stf(FloatRegisterImpl::S, src.second()->as_FloatRegister(), SP, reg2offset(dst.second()) + STACK_BIAS);
1584 __ stf(FloatRegisterImpl::D, src.first()->as_FloatRegister(), SP, reg2offset(dst.first()) + STACK_BIAS);
1593 __ mov(src.first()->as_Register(), dst.first()->as_Register());
1594 __ mov(src.second()->as_Register(), dst.second()->as_Register());
1598 __ stx(src.first()->as_Register(), FP, -8 + STACK_BIAS);
1599 __ stx(src.second()->as_Register(), FP, -4 + STACK_BIAS);
1601 __ ldf(FloatRegisterImpl::S, FP, -8 + STACK_BIAS, dst.first()->as_FloatRegister());
1602 __ ldf(FloatRegisterImpl::S, FP, -4 + STACK_BIAS, dst.second()->as_FloatRegister());
1607 __ stf(FloatRegisterImpl::D, src.first()->as_FloatRegister(), FP, -8 + STACK_BIAS);
1610 __ ld(FP, -8 + STACK_BIAS, dst.first()->as_Register());
1612 __ ld(FP, -4 + STACK_BIAS, dst.second()->as_Register());
1614 __ ld(FP, -4 + STACK_BIAS, L4);
1615 __ st(L4, SP, reg2offset(dst.second()) + STACK_BIAS);
1621 __ fmov(FloatRegisterImpl::D, src.first()->as_FloatRegister(), dst.first()->as_FloatRegister());
1631 __ save_frame(0);
1635 __ mov(G2_thread, L7_thread_cache);
1677 __ stx(reg, SP, offset + STACK_BIAS);
1679 __ ldx(SP, offset + STACK_BIAS, reg);
1686 __ stf(FloatRegisterImpl::D, in_regs[i].first()->as_FloatRegister(), SP, offset + STACK_BIAS);
1688 __ ldf(FloatRegisterImpl::D, SP, offset + STACK_BIAS, in_regs[i].first()->as_FloatRegister());
1700 __ stf(FloatRegisterImpl::S, in_regs[i].first()->as_FloatRegister(), SP, offset + STACK_BIAS);
1702 __ ldf(FloatRegisterImpl::S, SP, offset + STACK_BIAS, in_regs[i].first()->as_FloatRegister());
1721 __ block_comment("check GC_locker::needs_gc");
1724 __ load_bool_contents(sync_state, G3_scratch);
1725 __ cmp_zero_and_br(Assembler::equal, G3_scratch, cont);
1726 __ delayed()->nop();
1734 __ mov(G2_thread, L7_thread_cache);
1736 __ set_last_Java_frame(SP, noreg);
1738 __ block_comment("block_for_jni_critical");
1739 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::block_for_jni_critical), relocInfo::runtime_call_type);
1740 __ delayed()->mov(L7_thread_cache, O0);
1741 oop_maps->add_gc_map( __ offset(), map);
1743 __ restore_thread(L7_thread_cache); // restore G2_thread
1744 __ reset_last_Java_frame();
1750 __ bind(cont);
1762 __ mov(G0, reg);
1765 __ fneg(FloatRegisterImpl::D, in_regs[i].first()->as_FloatRegister(), in_regs[i].first()->as_FloatRegister());
1786 __ cmp(reg.first()->as_Register(), G0);
1787 __ brx(Assembler::equal, false, Assembler::pt, is_null);
1788 __ delayed()->add(reg.first()->as_Register(), arrayOopDesc::base_offset_in_bytes(in_elem_type), L4);
1790 __ ld(reg.first()->as_Register(), arrayOopDesc::length_offset_in_bytes(), L4);
1792 __ ba_short(done);
1793 __ bind(is_null);
1797 __ bind(done);
1813 ld_off = __ ensure_simm13_or_reg(ld_off, temp_reg);
1814 __ ld_ptr(SP, ld_off, temp_reg);
1815 __ verify_oop(temp_reg);
1817 __ verify_oop(r->as_Register());
1853 ld_off = __ ensure_simm13_or_reg(ld_off, member_reg);
1854 __ ld_ptr(SP, ld_off, member_reg);
1874 ld_off = __ ensure_simm13_or_reg(ld_off, member_reg);
1875 __ ld_ptr(SP, ld_off, receiver_reg);
1924 intptr_t start = (intptr_t)__ pc();
1925 int vep_offset = ((intptr_t)__ pc()) - start;
1930 int frame_complete = ((intptr_t)__ pc()) - start; // not complete, period
1931 __ flush();
1957 intptr_t start = (intptr_t)__ pc();
1964 __ verify_oop(O0);
1965 __ load_klass(O0, temp_reg);
1966 __ cmp_and_brx_short(temp_reg, G5_inline_cache_reg, Assembler::equal, Assembler::pt, L);
1968 __ jump_to(ic_miss, temp_reg);
1969 __ delayed()->nop();
1970 __ align(CodeEntryAlignment);
1971 __ bind(L);
1974 int vep_offset = ((intptr_t)__ pc()) - start;
1993 __ ld_ptr(receiver, oopDesc::mark_offset_in_bytes(), header);
1994 __ sethi(markOopDesc::hash_mask, mask);
1995 __ btst(markOopDesc::unlocked_value, header);
1996 __ br(Assembler::zero, false, Assembler::pn, slowCase);
1999 __ delayed()->nop();
2000 __ btst(markOopDesc::biased_lock_bit_in_place, header);
2001 __ br(Assembler::notZero, false, Assembler::pn, slowCase);
2003 __ delayed()->or3(mask, markOopDesc::hash_mask & 0x3ff, mask);
2007 __ srlx(header, markOopDesc::hash_shift, hash);
2009 __ srl(header, markOopDesc::hash_shift, hash);
2011 __ andcc(hash, mask, hash);
2012 __ br(Assembler::equal, false, Assembler::pn, slowCase);
2013 __ delayed()->nop();
2016 __ retl();
2017 __ delayed()->mov(hash, result);
2018 __ bind(slowCase);
2210 __ generate_stack_overflow_check(stack_size);
2213 __ save(SP, -stack_size, SP);
2215 int frame_complete = ((intptr_t)__ pc()) - start;
2217 __ verify_thread();
2326 __ set_oop_constant(JNIHandles::make_local(Klass::cast(method->method_holder())->java_mirror()), O1);
2329 __ st_ptr(O1, SP, klass_offset + STACK_BIAS);
2331 __ add(SP, klass_offset + STACK_BIAS, O1);
2339 __ mov(O1, L6_handle);
2346 intptr_t thepc = (intptr_t) __ pc();
2348 address here = __ pc();
2350 __ call(here + 8, relocInfo::none);
2351 __ delayed()->nop();
2354 intptr_t thepc = __ load_pc_address(O7, 0);
2365 __ mov(G2_thread, L7_thread_cache);
2377 __ save_frame(0);
2378 __ mov(G2_thread, L7_thread_cache);
2379 __ set_oop_constant(JNIHandles::make_local(method()), O1);
2380 __ call_VM_leaf(L7_thread_cache,
2383 __ restore();
2389 __ save_frame(0);
2390 __ mov(G2_thread, L7_thread_cache);
2391 __ set_oop_constant(JNIHandles::make_local(method()), O1);
2392 __ call_VM_leaf(L7_thread_cache,
2395 __ restore();
2413 __ ld_ptr(I1, 0, O1);
2417 __ add(FP, lock_offset+STACK_BIAS, L3_box);
2422 __ st_ptr(L3_box, L3_box, 0);
2428 __ compiler_lock_object(Roop, L1, L3_box, L2);
2429 __ br(Assembler::equal, false, Assembler::pt, done);
2430 __ delayed() -> add(FP, lock_offset+STACK_BIAS, L3_box);
2436 __ mov(Roop, O0); // Need oop in O0
2437 __ mov(L3_box, O1);
2441 __ set_last_Java_frame(FP, I7);
2444 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::complete_monitor_locking_C), relocInfo::runtime_call_type);
2445 __ delayed()->mov(L7_thread_cache, O2);
2447 __ restore_thread(L7_thread_cache); // restore G2_thread
2448 __ reset_last_Java_frame();
2452 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), O0);
2453 __ br_null_short(O0, Assembler::pt, L);
2454 __ stop("no pending exception allowed on exit from IR::monitorenter");
2455 __ bind(L);
2458 __ bind(done);
2464 __ flush_windows();
2466 __ restore();
2471 __ st_ptr(FP, SP, FP->sp_offset_in_saved_window()*wordSize + STACK_BIAS);
2472 __ st_ptr(I7, SP, I7->sp_offset_in_saved_window()*wordSize + STACK_BIAS);
2477 __ add(G2_thread, in_bytes(JavaThread::jni_environment_offset()), O0);
2481 __ set_last_Java_frame(SP, O7);
2484 __ set(JavaFrameAnchor::flushed, G3_scratch);
2485 __ st(G3_scratch, G2_thread, JavaThread::frame_anchor_offset() + JavaFrameAnchor::flags_offset());
2488 __ set(_thread_in_native, G3_scratch);
2492 __ relocate(relocInfo::runtime_call_type);
2493 __ jumpl_to(dest, O7, O7);
2495 __ call(native_func, relocInfo::runtime_call_type);
2497 __ delayed()->st(G3_scratch, G2_thread, JavaThread::thread_state_offset());
2499 __ restore_thread(L7_thread_cache); // restore G2_thread
2512 __ mov(O1, I1);
2518 __ mov(O0, I0);
2520 case T_BOOLEAN: __ subcc(G0, O0, G0); __ addc(G0, 0, I0); break; // !0 => true; 0 => false
2521 case T_BYTE : __ sll(O0, 24, O0); __ sra(O0, 24, I0); break;
2522 case T_CHAR : __ sll(O0, 16, O0); __ srl(O0, 16, I0); break; // cannot use and3, 0xFFFF too big as immediate value!
2523 case T_SHORT : __ sll(O0, 16, O0); __ sra(O0, 16, I0); break;
2544 __ set(_thread_in_native_trans, G3_scratch);
2545 __ st(G3_scratch, G2_thread, JavaThread::thread_state_offset());
2549 __ membar(Assembler::StoreLoad);
2555 __ serialize_memory(G2_thread, G1_scratch, G3_scratch);
2558 __ load_contents(sync_state, G3_scratch);
2559 __ cmp(G3_scratch, SafepointSynchronize::_not_synchronized);
2563 __ br(Assembler::notEqual, false, Assembler::pn, L);
2564 __ delayed()->ld(suspend_state, G3_scratch);
2565 __ cmp_and_br_short(G3_scratch, 0, Assembler::equal, Assembler::pt, no_block);
2566 __ bind(L);
2575 __ call_VM_leaf(L7_thread_cache,
2579 __ call_VM_leaf(L7_thread_cache,
2590 __ ba(after_transition);
2591 __ delayed()->nop();
2594 __ bind(no_block);
2599 __ set(_thread_in_Java, G3_scratch);
2600 __ st(G3_scratch, G2_thread, JavaThread::thread_state_offset());
2601 __ bind(after_transition);
2604 __ ld(G2_thread, JavaThread::stack_guard_state_offset(), G3_scratch);
2605 __ cmp_and_br_short(G3_scratch, JavaThread::stack_guard_yellow_disabled, Assembler::notEqual, Assembler::pt, no_reguard);
2608 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::reguard_yellow_pages));
2609 __ delayed()->nop();
2611 __ restore_thread(L7_thread_cache); // restore G2_thread
2614 __ bind(no_reguard);
2626 __ ld_ptr(L6_handle, 0, L4);
2627 __ add(SP, lock_offset+STACK_BIAS, L3_box);
2630 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), I2_ex_oop);
2633 __ compiler_unlock_object(L4, L1, L3_box, L2);
2634 __ br(Assembler::equal, false, Assembler::pt, done);
2635 __ delayed()-> add(SP, lock_offset+STACK_BIAS, L3_box);
2643 __ st_ptr(G0, G2_thread, in_bytes(Thread::pending_exception_offset()));
2647 __ mov(L3_box, O1);
2649 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::complete_monitor_unlocking_C), relocInfo::runtime_call_type);
2650 __ delayed()->mov(L4, O0); // Need oop in O0
2652 __ restore_thread(L7_thread_cache); // restore G2_thread
2656 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), O0);
2657 __ br_null_short(O0, Assembler::pt, L);
2658 __ stop("no pending exception allowed on exit from IR::monitorexit");
2659 __ bind(L);
2668 __ st_ptr(I2_ex_oop, G2_thread, in_bytes(Thread::pending_exception_offset()));
2669 __ bind(done);
2677 __ set_oop_constant(JNIHandles::make_local(method()), O1);
2678 __ call_VM_leaf(L7_thread_cache,
2685 __ verify_thread(); // G2_thread must be correct
2686 __ reset_last_Java_frame();
2691 __ addcc(G0, I0, G0);
2692 __ brx(Assembler::notZero, true, Assembler::pt, L);
2693 __ delayed()->ld_ptr(I0, 0, I0);
2694 __ mov(G0, I0);
2695 __ bind(L);
2696 __ verify_oop(I0);
2701 __ ld_ptr(G2_thread, in_bytes(JavaThread::active_handles_offset()), L5);
2702 __ st_ptr(G0, L5, JNIHandleBlock::top_offset_in_bytes());
2704 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), G3_scratch);
2715 __ sllx(I0, 32, G1); // Shift bits into high G1
2716 __ srl (I1, 0, I1); // Zero extend O1 (harmless?)
2717 __ or3 (I1, G1, G1); // OR 64 bits into G1
2721 __ ret();
2722 __ delayed()->restore();
2724 __ flush();
2898 intptr_t start = (intptr_t)__ pc();
2906 __ verify_oop(O0);
2907 __ ld_ptr(O0, oopDesc::klass_offset_in_bytes(), temp_reg);
2908 __ cmp_and_brx_short(temp_reg, G5_inline_cache_reg, Assembler::equal, Assembler::pt, L);
2910 __ jump_to(ic_miss, temp_reg);
2911 __ delayed()->nop();
2912 __ align(CodeEntryAlignment);
2913 __ bind(L);
2916 int vep_offset = ((intptr_t)__ pc()) - start;
2924 __ generate_stack_overflow_check(stack_size);
2926 assert(((intptr_t)__ pc() - start - vep_offset) >= 5,
2930 __ save(SP, -stack_size, SP);
2934 int frame_complete = ((intptr_t)__ pc()) - start;
2991 __ ld_ptr(FP, reg2offset(src.first()) + STACK_BIAS, in_reg);
3002 __ mov(G0, tmp->successor());
3004 __ br_null(in_reg, true, Assembler::pn, skipUnbox);
3005 __ delayed()->mov(G0, tmp);
3011 __ ldub(in_reg, box_offset, tmp); break;
3013 __ lduh(in_reg, box_offset, tmp); break;
3015 __ ld(in_reg, box_offset, tmp); break;
3017 __ ld_long(in_reg, box_offset, tmp); break;
3021 __ bind(skipUnbox);
3048 __ mov(s, d);
3052 __ st_ptr(s, SP, reg2offset(dst.first()) + STACK_BIAS);
3058 __ ld_ptr(FP, reg2offset(src.first()) + STACK_BIAS, d);
3062 __ st_ptr(d, SP, reg2offset(dst.first()) + STACK_BIAS);
3068 __ mov(G0, dst.first()->as_Register());
3072 __ st_ptr(G0, SP, reg2offset(dst.first()) + STACK_BIAS);
3091 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(),
3093 __ ld(SP, off, d);
3096 __ set(off, L6);
3099 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(),
3101 __ ld(SP, conversion_off , d);
3107 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(),
3111 __ set(off, L6);
3114 __ stf(FloatRegisterImpl::S, src.first()->as_FloatRegister(),
3139 __ stf(FloatRegisterImpl::D, src.first()->as_FloatRegister(),
3141 __ ld_long(SP, off, d);
3144 __ set(off, L6);
3147 __ stf(FloatRegisterImpl::D, src.first()->as_FloatRegister(),
3149 __ ld_long(SP, conversion_off, d);
3169 __ stx(src.first()->as_Register(), SP, off);
3170 __ ld_long(SP, off, tmp);
3173 __ set(off, L6);
3176 __ stx(src.first()->as_Register(), SP, conversion_off);
3177 __ ld_long(SP, conversion_off, tmp);
3202 __ save_frame(0);
3203 __ mov(G2_thread, L7_thread_cache);
3207 __ set(string_locs * VMRegImpl::stack_slot_size, L2_string_off);
3219 __ mov(d, O0);
3223 __ ld_ptr(FP, reg2offset(dst.first()) + STACK_BIAS, O0);
3227 __ br_null(O0, false, Assembler::pn, skip);
3228 __ delayed()->add(FP, L2_string_off, O1);
3231 __ mov(O1, d);
3235 __ st_ptr(O1, FP, reg2offset(dst.first()) + STACK_BIAS);
3238 __ call(CAST_FROM_FN_PTR(address, SharedRuntime::get_utf),
3240 __ delayed()->add(L2_string_off, max_dtrace_string_size, L2_string_off);
3242 __ bind(skip);
3247 __ mov(L7_thread_cache, G2_thread);
3248 __ restore();
3256 int patch_offset = ((intptr_t)__ pc()) - start;
3258 __ nop();
3263 __ ret();
3264 __ delayed()->restore();
3266 __ flush();
3309 __ ld_ptr(O3array, 0, O7frame_size);
3310 __ sub(G0, O7frame_size, O7frame_size);
3311 __ save(SP, O7frame_size, SP);
3312 __ ld_ptr(G3pcs, 0, I7); // load frame's new pc
3317 __ btst(wordSize*2-1, SP);
3318 __ breakpoint_trap(Assembler::notZero, Assembler::ptr_cc);
3325 __ mov(Oreturn0->after_save(), Oreturn0);
3326 __ mov(Oreturn1->after_save(), Oreturn1);
3329 __ mov(O4array_size->after_save(), O4array_size);
3330 __ sub(O4array_size, 1, O4array_size);
3331 __ mov(O3array->after_save(), O3array);
3332 __ mov(O2UnrollBlock->after_save(), O2UnrollBlock);
3333 __ add(G3pcs, wordSize, G3pcs); // point to next pc value
3337 __ set(0xDEAD0000, I0);
3338 __ add(I0, 2, I1);
3339 __ add(I0, 4, I2);
3340 __ add(I0, 6, I3);
3341 __ add(I0, 8, I4);
3343 __ set(0xDEADBEEF, L0);
3344 __ mov(L0, L1);
3345 __ mov(L0, L2);
3346 __ mov(L0, L3);
3347 __ mov(L0, L4);
3348 __ mov(L0, L5);
3351 __ set(0xDEAD0001, O7);
3354 __ mov(SP, O5_savedSP);
3374 __ ld(O2UnrollBlock, Deoptimization::UnrollBlock::total_frame_sizes_offset_in_bytes(), O4);
3375 __ bang_stack_size(O4, O3, G3_scratch);
3378 __ ld(O2UnrollBlock, Deoptimization::UnrollBlock::number_of_frames_offset_in_bytes(), O4array_size);
3379 __ ld_ptr(O2UnrollBlock, Deoptimization::UnrollBlock::frame_pcs_offset_in_bytes(), G3pcs);
3380 __ ld_ptr(O2UnrollBlock, Deoptimization::UnrollBlock::frame_sizes_offset_in_bytes(), O3array);
3393 __ ld(O2UnrollBlock, Deoptimization::UnrollBlock::caller_adjustment_offset_in_bytes(), O7);
3394 __ mov(SP, O5_savedSP); // remember initial sender's original sp before adjustment
3395 __ sub(SP, O7, SP);
3399 __ tst(O4array_size);
3400 __ breakpoint_trap(Assembler::zero, Assembler::icc);
3404 __ bind(loop);
3410 __ cmp_zero_and_br(Assembler::notZero, O4array_size, loop);
3411 __ delayed()->add(O3array, wordSize, O3array);
3412 __ ld_ptr(G3pcs, 0, O7); // load final frame new pc
3480 int start = __ offset();
3483 __ get_thread();
3490 __ ba(cont);
3491 __ delayed()->mov(Deoptimization::Unpack_deopt, L0deopt_mode);
3493 int exception_offset = __ offset() - start;
3496 __ get_thread();
3507 __ st_ptr(Oexception, G2_thread, JavaThread::exception_oop_offset());
3512 int exception_in_tls_offset = __ offset() - start;
3518 __ get_thread();
3524 __ ld_ptr(G2_thread, JavaThread::exception_oop_offset(), Oexception);
3525 __ br_notnull_short(Oexception, Assembler::pt, has_exception);
3526 __ stop("no exception in thread");
3527 __ bind(has_exception);
3532 __ ld_ptr(exception_addr, Oexception);
3533 __ br_null_short(Oexception, Assembler::pt, no_pending_exception);
3534 __ stop("must not have pending exception here");
3535 __ bind(no_pending_exception);
3539 __ ba(cont);
3540 __ delayed()->mov(Deoptimization::Unpack_exception, L0deopt_mode);;
3545 int reexecute_offset = __ offset() - start;
3550 __ mov(Deoptimization::Unpack_reexecute, L0deopt_mode);
3552 __ bind(cont);
3554 __ set_last_Java_frame(SP, noreg);
3558 __ mov(G2_thread, L7_thread_cache);
3559 __ call(CAST_FROM_FN_PTR(address, Deoptimization::fetch_unroll_info), relocInfo::runtime_call_type);
3560 __ delayed()->mov(G2_thread, O0);
3564 oop_maps->add_gc_map( __ offset()-start, map);
3566 __ mov(L7_thread_cache, G2_thread);
3568 __ reset_last_Java_frame();
3573 __ mov(L0deopt_mode, G4deopt_mode);
3575 __ mov(O0, O2UnrollBlock->after_save());
3580 __ cmp_and_br_short(G4deopt_mode, Deoptimization::Unpack_exception, Assembler::notEqual, Assembler::pt, noException);
3584 __ ld_ptr(G2_thread, in_bytes(JavaThread::exception_oop_offset()), Oexception);
3585 __ st_ptr(G0, G2_thread, in_bytes(JavaThread::exception_oop_offset()));
3586 __ bind(noException);
3589 __ mov(Oreturn0, Oreturn0->after_save());
3590 __ mov(Oreturn1, Oreturn1->after_save());
3591 __ mov(O2UnrollBlock, O2UnrollBlock->after_save());
3592 __ restore();
3602 __ save(SP, -frame_size_words*wordSize, SP);
3603 __ stf(FloatRegisterImpl::D, Freturn0, saved_Freturn0_addr);
3607 __ stx(Greturn1, saved_Greturn1_addr);
3609 __ set_last_Java_frame(SP, noreg);
3610 __ call_VM_leaf(L7_thread_cache, CAST_FROM_FN_PTR(address, Deoptimization::unpack_frames), G2_thread, G4deopt_mode);
3613 __ mov(G4deopt_mode, O1);
3614 __ set_last_Java_frame(SP, G0);
3615 __ call_VM_leaf(L7_thread_cache, CAST_FROM_FN_PTR(address, Deoptimization::unpack_frames), G2_thread, O1);
3617 __ reset_last_Java_frame();
3618 __ ldf(FloatRegisterImpl::D, saved_Freturn0_addr, Freturn0);
3624 __ cmp_and_br_short(O0,T_LONG, Assembler::notEqual, Assembler::pt, not_long);
3625 __ ldd(saved_Greturn1_addr,I0);
3626 __ bind(not_long);
3628 __ ret();
3629 __ delayed()->restore();
3690 __ save_frame(0);
3691 __ set_last_Java_frame(SP, noreg);
3692 __ mov(I0, O2klass_index);
3693 __ call_VM_leaf(L7_thread_cache, CAST_FROM_FN_PTR(address, Deoptimization::uncommon_trap), G2_thread, O2klass_index);
3694 __ reset_last_Java_frame();
3695 __ mov(O0, O2UnrollBlock->after_save());
3696 __ restore();
3699 __ mov(O2UnrollBlock, O2UnrollBlock->after_save());
3700 __ restore();
3710 __ save_frame(0);
3711 __ set_last_Java_frame(SP, noreg);
3712 __ mov(Deoptimization::Unpack_uncommon_trap, O3); // indicate it is the uncommon trap case
3713 __ call_VM_leaf(L7_thread_cache, CAST_FROM_FN_PTR(address, Deoptimization::unpack_frames), G2_thread, O3);
3714 __ reset_last_Java_frame();
3715 __ ret();
3716 __ delayed()->restore();
3719 _uncommon_trap_blob = UncommonTrapBlob::create(&buffer, NULL, __ total_frame_size_in_bytes(0)/wordSize);
3762 int start = __ offset();
3767 __ restore();
3771 __ ld_ptr(G2_thread, in_bytes(JavaThread::saved_exception_pc_offset()), O7);
3772 __ sub(O7, frame::pc_return_offset, O7);
3778 __ set_last_Java_frame(SP, noreg);
3782 __ mov(G2_thread, O0);
3783 __ save_thread(L7_thread_cache);
3784 __ call(call_ptr);
3785 __ delayed()->nop();
3791 oop_maps->add_gc_map( __ offset() - start, map);
3793 __ restore_thread(L7_thread_cache);
3795 __ reset_last_Java_frame();
3800 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), O1);
3801 __ br_notnull_short(O1, Assembler::pn, pending);
3807 __ retl();
3808 __ delayed()->nop();
3812 __ bind(pending);
3820 __ set((intptr_t)StubRoutines::forward_exception_entry(), O0);
3821 __ JMP(O0, 0);
3822 __ delayed()->nop();
3856 int start = __ offset();
3860 int frame_complete = __ offset();
3863 __ set_last_Java_frame(SP, noreg);
3867 __ mov(G2_thread, O0);
3868 __ save_thread(L7_thread_cache);
3869 __ call(destination, relocInfo::runtime_call_type);
3870 __ delayed()->nop();
3878 oop_maps->add_gc_map( __ offset() - start, map);
3880 __ restore_thread(L7_thread_cache);
3882 __ reset_last_Java_frame();
3887 __ ld_ptr(G2_thread, in_bytes(Thread::pending_exception_offset()), O1);
3888 __ br_notnull_short(O1, Assembler::pn, pending);
3892 __ get_vm_result(G5_method);
3893 __ stx(G5_method, SP, RegisterSaver::G5_offset()+STACK_BIAS);
3897 __ stx(O0, SP, RegisterSaver::G3_offset()+STACK_BIAS);
3903 __ JMP(G3, 0);
3904 __ delayed()->nop();
3908 __ bind(pending);
3916 __ set((intptr_t)StubRoutines::forward_exception_entry(), O0);
3917 __ JMP(O0, 0);
3918 __ delayed()->nop();