< prev index next >

src/hotspot/share/c1/c1_LIRGenerator.cpp

Print this page
*** 635,11 ***
  void LIRGenerator::monitor_exit(LIR_Opr object, LIR_Opr lock, LIR_Opr new_hdr, LIR_Opr scratch, int monitor_no) {
    if (!GenerateSynchronizationCode) return;
    // setup registers
    LIR_Opr hdr = lock;
    lock = new_hdr;
!   CodeStub* slow_path = new MonitorExitStub(lock, UseFastLocking, monitor_no);
    __ load_stack_address_monitor(monitor_no, lock);
    __ unlock_object(hdr, object, lock, scratch, slow_path);
  }
  
  #ifndef PRODUCT
--- 635,11 ---
  void LIRGenerator::monitor_exit(LIR_Opr object, LIR_Opr lock, LIR_Opr new_hdr, LIR_Opr scratch, int monitor_no) {
    if (!GenerateSynchronizationCode) return;
    // setup registers
    LIR_Opr hdr = lock;
    lock = new_hdr;
!   CodeStub* slow_path = new MonitorExitStub(lock, LockingMode != LM_MONITOR, monitor_no);
    __ load_stack_address_monitor(monitor_no, lock);
    __ unlock_object(hdr, object, lock, scratch, slow_path);
  }
  
  #ifndef PRODUCT

*** 1256,11 ***
                                       NULL); // NULL CodeEmitInfo results in a leaf call
    __ move(call_result, result);
  }
  
  void LIRGenerator::load_klass(LIR_Opr obj, LIR_Opr klass, CodeEmitInfo* null_check_info) {
!   __ load_klass(obj, klass, null_check_info);
  }
  
  // Example: object.getClass ()
  void LIRGenerator::do_getClass(Intrinsic* x) {
    assert(x->number_of_arguments() == 1, "wrong type");
--- 1256,12 ---
                                       NULL); // NULL CodeEmitInfo results in a leaf call
    __ move(call_result, result);
  }
  
  void LIRGenerator::load_klass(LIR_Opr obj, LIR_Opr klass, CodeEmitInfo* null_check_info) {
!   CodeStub* slow_path = UseCompactObjectHeaders ? new LoadKlassStub(klass) : NULL;
+   __ load_klass(obj, klass, null_check_info, slow_path);
  }
  
  // Example: object.getClass ()
  void LIRGenerator::do_getClass(Intrinsic* x) {
    assert(x->number_of_arguments() == 1, "wrong type");
< prev index next >