hotspot/src/cpu/sparc/vm/templateTable_sparc.cpp
changeset 6176 4d9030fe341f
parent 5882 6b2aecc4f7d8
child 6453 970dc585ab63
equal deleted inserted replaced
6175:86dbf3cacacc 6176:4d9030fe341f
  3234   Register Rscratch = O4;
  3234   Register Rscratch = O4;
  3235 
  3235 
  3236   __ get_2_byte_integer_at_bcp(1, Rscratch, Roffset, InterpreterMacroAssembler::Unsigned);
  3236   __ get_2_byte_integer_at_bcp(1, Rscratch, Roffset, InterpreterMacroAssembler::Unsigned);
  3237   __ get_cpool_and_tags(Rscratch, G3_scratch);
  3237   __ get_cpool_and_tags(Rscratch, G3_scratch);
  3238   // make sure the class we're about to instantiate has been resolved
  3238   // make sure the class we're about to instantiate has been resolved
       
  3239   // This is done before loading instanceKlass to be consistent with the order
       
  3240   // how Constant Pool is updated (see constantPoolOopDesc::klass_at_put)
  3239   __ add(G3_scratch, typeArrayOopDesc::header_size(T_BYTE) * wordSize, G3_scratch);
  3241   __ add(G3_scratch, typeArrayOopDesc::header_size(T_BYTE) * wordSize, G3_scratch);
  3240   __ ldub(G3_scratch, Roffset, G3_scratch);
  3242   __ ldub(G3_scratch, Roffset, G3_scratch);
  3241   __ cmp(G3_scratch, JVM_CONSTANT_Class);
  3243   __ cmp(G3_scratch, JVM_CONSTANT_Class);
  3242   __ br(Assembler::notEqual, false, Assembler::pn, slow_case);
  3244   __ br(Assembler::notEqual, false, Assembler::pn, slow_case);
  3243   __ delayed()->sll(Roffset, LogBytesPerWord, Roffset);
  3245   __ delayed()->sll(Roffset, LogBytesPerWord, Roffset);
  3244 
  3246   // get instanceKlass
  3245   //__ sll(Roffset, LogBytesPerWord, Roffset);        // executed in delay slot
  3247   //__ sll(Roffset, LogBytesPerWord, Roffset);        // executed in delay slot
  3246   __ add(Roffset, sizeof(constantPoolOopDesc), Roffset);
  3248   __ add(Roffset, sizeof(constantPoolOopDesc), Roffset);
  3247   __ ld_ptr(Rscratch, Roffset, RinstanceKlass);
  3249   __ ld_ptr(Rscratch, Roffset, RinstanceKlass);
  3248 
  3250 
  3249   // make sure klass is fully initialized:
  3251   // make sure klass is fully initialized: