< prev index next >

src/hotspot/share/c1/c1_LIRAssembler.cpp

Print this page




 145       _masm->block_comment(st.as_string());
 146     }
 147 #endif
 148     s->emit_code(this);
 149 #ifdef ASSERT
 150     s->assert_no_unbound_labels();
 151 #endif
 152   }
 153 }
 154 
 155 
 156 void LIR_Assembler::emit_slow_case_stubs() {
 157   emit_stubs(_slow_case_stubs);
 158 }
 159 
 160 
 161 bool LIR_Assembler::needs_icache(ciMethod* method) const {
 162   return !method->is_static();
 163 }
 164 



 165 
 166 int LIR_Assembler::code_offset() const {
 167   return _masm->offset();
 168 }
 169 
 170 
 171 address LIR_Assembler::pc() const {
 172   return _masm->pc();
 173 }
 174 
 175 // To bang the stack of this compiled method we use the stack size
 176 // that the interpreter would need in case of a deoptimization. This
 177 // removes the need to bang the stack in the deoptimization blob which
 178 // in turn simplifies stack overflow handling.
 179 int LIR_Assembler::bang_size_in_bytes() const {
 180   return MAX2(initial_frame_size_in_bytes() + os::extra_bang_size_in_bytes(), _compilation->interpreter_frame_size());
 181 }
 182 
 183 void LIR_Assembler::emit_exception_entries(ExceptionInfoList* info_list) {
 184   for (int i = 0; i < info_list->length(); i++) {


 604       _masm->nop();
 605       break;
 606 
 607     case lir_label:
 608       Unimplemented();
 609       break;
 610 
 611     case lir_build_frame:
 612       build_frame();
 613       break;
 614 
 615     case lir_std_entry:
 616       // init offsets
 617       offsets()->set_value(CodeOffsets::OSR_Entry, _masm->offset());
 618       _masm->align(CodeEntryAlignment);
 619       if (needs_icache(compilation()->method())) {
 620         check_icache();
 621       }
 622       offsets()->set_value(CodeOffsets::Verified_Entry, _masm->offset());
 623       _masm->verified_entry();



 624       build_frame();
 625       offsets()->set_value(CodeOffsets::Frame_Complete, _masm->offset());
 626       break;
 627 
 628     case lir_osr_entry:
 629       offsets()->set_value(CodeOffsets::OSR_Entry, _masm->offset());
 630       osr_entry();
 631       break;
 632 
 633     case lir_24bit_FPU:
 634       set_24bit_FPU();
 635       break;
 636 
 637     case lir_reset_FPU:
 638       reset_FPU();
 639       break;
 640 
 641     case lir_breakpoint:
 642       breakpoint();
 643       break;




 145       _masm->block_comment(st.as_string());
 146     }
 147 #endif
 148     s->emit_code(this);
 149 #ifdef ASSERT
 150     s->assert_no_unbound_labels();
 151 #endif
 152   }
 153 }
 154 
 155 
 156 void LIR_Assembler::emit_slow_case_stubs() {
 157   emit_stubs(_slow_case_stubs);
 158 }
 159 
 160 
 161 bool LIR_Assembler::needs_icache(ciMethod* method) const {
 162   return !method->is_static();
 163 }
 164 
 165 bool LIR_Assembler::needs_clinit_barrier_on_entry(ciMethod* method) const {
 166   return UseFastClassInitChecks && method->needs_clinit_barrier();
 167 }
 168 
 169 int LIR_Assembler::code_offset() const {
 170   return _masm->offset();
 171 }
 172 
 173 
 174 address LIR_Assembler::pc() const {
 175   return _masm->pc();
 176 }
 177 
 178 // To bang the stack of this compiled method we use the stack size
 179 // that the interpreter would need in case of a deoptimization. This
 180 // removes the need to bang the stack in the deoptimization blob which
 181 // in turn simplifies stack overflow handling.
 182 int LIR_Assembler::bang_size_in_bytes() const {
 183   return MAX2(initial_frame_size_in_bytes() + os::extra_bang_size_in_bytes(), _compilation->interpreter_frame_size());
 184 }
 185 
 186 void LIR_Assembler::emit_exception_entries(ExceptionInfoList* info_list) {
 187   for (int i = 0; i < info_list->length(); i++) {


 607       _masm->nop();
 608       break;
 609 
 610     case lir_label:
 611       Unimplemented();
 612       break;
 613 
 614     case lir_build_frame:
 615       build_frame();
 616       break;
 617 
 618     case lir_std_entry:
 619       // init offsets
 620       offsets()->set_value(CodeOffsets::OSR_Entry, _masm->offset());
 621       _masm->align(CodeEntryAlignment);
 622       if (needs_icache(compilation()->method())) {
 623         check_icache();
 624       }
 625       offsets()->set_value(CodeOffsets::Verified_Entry, _masm->offset());
 626       _masm->verified_entry();
 627       if (needs_clinit_barrier_on_entry(compilation()->method())) {
 628         clinit_barrier(compilation()->method());
 629       }
 630       build_frame();
 631       offsets()->set_value(CodeOffsets::Frame_Complete, _masm->offset());
 632       break;
 633 
 634     case lir_osr_entry:
 635       offsets()->set_value(CodeOffsets::OSR_Entry, _masm->offset());
 636       osr_entry();
 637       break;
 638 
 639     case lir_24bit_FPU:
 640       set_24bit_FPU();
 641       break;
 642 
 643     case lir_reset_FPU:
 644       reset_FPU();
 645       break;
 646 
 647     case lir_breakpoint:
 648       breakpoint();
 649       break;


< prev index next >