< prev index next >

src/hotspot/cpu/x86/templateTable_x86.cpp

Print this page
@@ -3655,13 +3655,12 @@
    __ jump_from_interpreted(method, rax);
  
    __ bind(notFinal);
  
    // get receiver klass
-   __ null_check(recv, oopDesc::klass_offset_in_bytes());
    Register tmp_load_klass = LP64_ONLY(rscratch1) NOT_LP64(noreg);
-   __ load_klass(rax, recv, tmp_load_klass);
+   __ load_klass(rax, recv, tmp_load_klass, true);
  
    // profile this call
    __ profile_virtual_call(rax, rlocals, rdx);
    // get target Method* & entry point
    __ lookup_virtual_method(rax, index, method);

@@ -3748,13 +3747,12 @@
    __ movl(rlocals, rdx);
    __ andl(rlocals, (1 << ConstantPoolCacheEntry::is_vfinal_shift));
    __ jcc(Assembler::zero, notVFinal);
  
    // Get receiver klass into rlocals - also a null check
-   __ null_check(rcx, oopDesc::klass_offset_in_bytes());
    Register tmp_load_klass = LP64_ONLY(rscratch1) NOT_LP64(noreg);
-   __ load_klass(rlocals, rcx, tmp_load_klass);
+   __ load_klass(rlocals, rcx, tmp_load_klass, true);
  
    Label subtype;
    __ check_klass_subtype(rlocals, rax, rbcp, subtype);
    // If we get here the typecheck failed
    recvKlass = rdx;

@@ -3772,12 +3770,11 @@
    // no return from above
    __ bind(notVFinal);
  
    // Get receiver klass into rdx - also a null check
    __ restore_locals();  // restore r14
-   __ null_check(rcx, oopDesc::klass_offset_in_bytes());
-   __ load_klass(rdx, rcx, tmp_load_klass);
+   __ load_klass(rdx, rcx, tmp_load_klass, true);
  
    Label no_such_method;
  
    // Preserve method for throw_AbstractMethodErrorVerbose.
    __ mov(rcx, rbx);

@@ -4021,13 +4018,13 @@
      __ jcc(Assembler::notZero, loop);
      }
  
      // initialize object header only.
      __ bind(initialize_header);
-     __ movptr(Address(rax, oopDesc::mark_offset_in_bytes()),
-               (intptr_t)markWord::prototype().value()); // header
      __ pop(rcx);   // get saved klass back in the register.
+     __ movptr(rbx, Address(rcx, Klass::prototype_header_offset()));
+     __ movptr(Address(rax, oopDesc::mark_offset_in_bytes ()), rbx);
  #ifdef _LP64
      __ xorl(rsi, rsi); // use zero reg to clear memory (shorter code)
      __ store_klass_gap(rax, rsi);  // zero klass gap for compressed oops
  #endif
      Register tmp_store_klass = LP64_ONLY(rscratch1) NOT_LP64(noreg);

@@ -4183,11 +4180,11 @@
  
    __ pop_ptr(rdx); // restore receiver
    __ verify_oop(rdx);
    Register tmp_load_klass = LP64_ONLY(rscratch1) NOT_LP64(noreg);
    __ load_klass(rdx, rdx, tmp_load_klass);
-   __ jmpb(resolved);
+   __ jmp(resolved);
  
    // Get superklass in rax and subklass in rdx
    __ bind(quicked);
    __ load_klass(rdx, rax, tmp_load_klass);
    __ load_resolved_klass_at_index(rax, rcx, rbx);
< prev index next >