< prev index next >

src/hotspot/cpu/ppc/macroAssembler_ppc.cpp

Print this page
rev 47398 : 8166317: InterpreterCodeSize should be computed
Reviewed-by: kvn, coleenp


3206   const Register Rqueue_index = Rtmp2,
3207                  Rqueue_buf   = Rtmp3;
3208   ld(Rqueue_index, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_index()), R16_thread);
3209   cmpdi(CCR0, Rqueue_index, 0);
3210   beq(CCR0, runtime); // index == 0 then jump to runtime
3211   ld(Rqueue_buf, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_buf()), R16_thread);
3212 
3213   addi(Rqueue_index, Rqueue_index, -wordSize); // decrement index
3214   std(Rqueue_index, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_index()), R16_thread);
3215 
3216   stdx(Rcard_addr, Rqueue_buf, Rqueue_index); // store card
3217   b(filtered);
3218 
3219   bind(runtime);
3220 
3221   // Save the live input values.
3222   call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_post), Rcard_addr, R16_thread);
3223 
3224   bind(filtered_int);
3225 }





3226 #endif // INCLUDE_ALL_GCS
3227 
3228 // Values for last_Java_pc, and last_Java_sp must comply to the rules
3229 // in frame_ppc.hpp.
3230 void MacroAssembler::set_last_Java_frame(Register last_Java_sp, Register last_Java_pc) {
3231   // Always set last_Java_pc and flags first because once last_Java_sp
3232   // is visible has_last_Java_frame is true and users will look at the
3233   // rest of the fields. (Note: flags should always be zero before we
3234   // get here so doesn't need to be set.)
3235 
3236   // Verify that last_Java_pc was zeroed on return to Java
3237   asm_assert_mem8_is_zero(in_bytes(JavaThread::last_Java_pc_offset()), R16_thread,
3238                           "last_Java_pc not zeroed before leaving Java", 0x200);
3239 
3240   // When returning from calling out from Java mode the frame anchor's
3241   // last_Java_pc will always be set to NULL. It is set here so that
3242   // if we are doing a call to native (not VM) that we capture the
3243   // known pc and don't have to rely on the native call having a
3244   // standard frame linkage where we can find the pc.
3245   if (last_Java_pc != noreg)




3206   const Register Rqueue_index = Rtmp2,
3207                  Rqueue_buf   = Rtmp3;
3208   ld(Rqueue_index, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_index()), R16_thread);
3209   cmpdi(CCR0, Rqueue_index, 0);
3210   beq(CCR0, runtime); // index == 0 then jump to runtime
3211   ld(Rqueue_buf, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_buf()), R16_thread);
3212 
3213   addi(Rqueue_index, Rqueue_index, -wordSize); // decrement index
3214   std(Rqueue_index, in_bytes(JavaThread::dirty_card_queue_offset() + DirtyCardQueue::byte_offset_of_index()), R16_thread);
3215 
3216   stdx(Rcard_addr, Rqueue_buf, Rqueue_index); // store card
3217   b(filtered);
3218 
3219   bind(runtime);
3220 
3221   // Save the live input values.
3222   call_VM_leaf(CAST_FROM_FN_PTR(address, SharedRuntime::g1_wb_post), Rcard_addr, R16_thread);
3223 
3224   bind(filtered_int);
3225 }
3226 
3227 // Called from init_globals() after universe_init() and before interpreter_init()
3228 void g1_barrier_stubs_init() {
3229   // G1 barrier stubs currently only generated on SPARC
3230 }
3231 #endif // INCLUDE_ALL_GCS
3232 
3233 // Values for last_Java_pc, and last_Java_sp must comply to the rules
3234 // in frame_ppc.hpp.
3235 void MacroAssembler::set_last_Java_frame(Register last_Java_sp, Register last_Java_pc) {
3236   // Always set last_Java_pc and flags first because once last_Java_sp
3237   // is visible has_last_Java_frame is true and users will look at the
3238   // rest of the fields. (Note: flags should always be zero before we
3239   // get here so doesn't need to be set.)
3240 
3241   // Verify that last_Java_pc was zeroed on return to Java
3242   asm_assert_mem8_is_zero(in_bytes(JavaThread::last_Java_pc_offset()), R16_thread,
3243                           "last_Java_pc not zeroed before leaving Java", 0x200);
3244 
3245   // When returning from calling out from Java mode the frame anchor's
3246   // last_Java_pc will always be set to NULL. It is set here so that
3247   // if we are doing a call to native (not VM) that we capture the
3248   // known pc and don't have to rely on the native call having a
3249   // standard frame linkage where we can find the pc.
3250   if (last_Java_pc != noreg)


< prev index next >