< prev index next >

src/hotspot/share/runtime/stubRoutines.cpp

Print this page

158 address StubRoutines::_vectorizedMismatch = NULL;
159 
160 address StubRoutines::_dexp = NULL;
161 address StubRoutines::_dlog = NULL;
162 address StubRoutines::_dlog10 = NULL;
163 address StubRoutines::_dpow = NULL;
164 address StubRoutines::_dsin = NULL;
165 address StubRoutines::_dcos = NULL;
166 address StubRoutines::_dlibm_sin_cos_huge = NULL;
167 address StubRoutines::_dlibm_reduce_pi04l = NULL;
168 address StubRoutines::_dlibm_tan_cot_huge = NULL;
169 address StubRoutines::_dtan = NULL;
170 
171 address StubRoutines::_safefetch32_entry                 = NULL;
172 address StubRoutines::_safefetch32_fault_pc              = NULL;
173 address StubRoutines::_safefetch32_continuation_pc       = NULL;
174 address StubRoutines::_safefetchN_entry                  = NULL;
175 address StubRoutines::_safefetchN_fault_pc               = NULL;
176 address StubRoutines::_safefetchN_continuation_pc        = NULL;
177 



178 address StubRoutines::_vector_f_math[VectorSupport::NUM_VEC_SIZES][VectorSupport::NUM_SVML_OP] = {{NULL}, {NULL}};
179 address StubRoutines::_vector_d_math[VectorSupport::NUM_VEC_SIZES][VectorSupport::NUM_SVML_OP] = {{NULL}, {NULL}};
180 
181 // Initialization
182 //
183 // Note: to break cycle with universe initialization, stubs are generated in two phases.
184 // The first one generates stubs needed during universe init (e.g., _handle_must_compile_first_entry).
185 // The second phase includes all other stubs (which may depend on universe being initialized.)
186 
187 extern void StubGenerator_generate(CodeBuffer* code, bool all); // only interface to generators
188 
189 void UnsafeCopyMemory::create_table(int max_size) {
190   UnsafeCopyMemory::_table = new UnsafeCopyMemory[max_size];
191   UnsafeCopyMemory::_table_max_length = max_size;
192 }
193 
194 bool UnsafeCopyMemory::contains_pc(address pc) {
195   for (int i = 0; i < UnsafeCopyMemory::_table_length; i++) {
196     UnsafeCopyMemory* entry = &UnsafeCopyMemory::_table[i];
197     if (pc >= entry->start_pc() && pc < entry->end_pc()) {

462 #define RETURN_STUB(xxx_fill) { \
463   name = #xxx_fill; \
464   return StubRoutines::xxx_fill(); }
465 
466   switch (t) {
467   case T_BYTE:
468   case T_BOOLEAN:
469     if (!aligned) RETURN_STUB(jbyte_fill);
470     RETURN_STUB(arrayof_jbyte_fill);
471   case T_CHAR:
472   case T_SHORT:
473     if (!aligned) RETURN_STUB(jshort_fill);
474     RETURN_STUB(arrayof_jshort_fill);
475   case T_INT:
476   case T_FLOAT:
477     if (!aligned) RETURN_STUB(jint_fill);
478     RETURN_STUB(arrayof_jint_fill);
479   case T_DOUBLE:
480   case T_LONG:
481   case T_ARRAY:

482   case T_OBJECT:
483   case T_NARROWOOP:
484   case T_NARROWKLASS:
485   case T_ADDRESS:
486   case T_VOID:
487     // Currently unsupported
488     return NULL;
489 
490   default:
491     ShouldNotReachHere();
492     return NULL;
493   }
494 
495 #undef RETURN_STUB
496 }
497 
498 // constants for computing the copy function
499 enum {
500   COPYFUNC_UNALIGNED = 0,
501   COPYFUNC_ALIGNED = 1,                 // src, dest aligned to HeapWordSize

158 address StubRoutines::_vectorizedMismatch = NULL;
159 
160 address StubRoutines::_dexp = NULL;
161 address StubRoutines::_dlog = NULL;
162 address StubRoutines::_dlog10 = NULL;
163 address StubRoutines::_dpow = NULL;
164 address StubRoutines::_dsin = NULL;
165 address StubRoutines::_dcos = NULL;
166 address StubRoutines::_dlibm_sin_cos_huge = NULL;
167 address StubRoutines::_dlibm_reduce_pi04l = NULL;
168 address StubRoutines::_dlibm_tan_cot_huge = NULL;
169 address StubRoutines::_dtan = NULL;
170 
171 address StubRoutines::_safefetch32_entry                 = NULL;
172 address StubRoutines::_safefetch32_fault_pc              = NULL;
173 address StubRoutines::_safefetch32_continuation_pc       = NULL;
174 address StubRoutines::_safefetchN_entry                  = NULL;
175 address StubRoutines::_safefetchN_fault_pc               = NULL;
176 address StubRoutines::_safefetchN_continuation_pc        = NULL;
177 
178 address StubRoutines::_load_inline_type_fields_in_regs = NULL;
179 address StubRoutines::_store_inline_type_fields_to_buf = NULL;
180 
181 address StubRoutines::_vector_f_math[VectorSupport::NUM_VEC_SIZES][VectorSupport::NUM_SVML_OP] = {{NULL}, {NULL}};
182 address StubRoutines::_vector_d_math[VectorSupport::NUM_VEC_SIZES][VectorSupport::NUM_SVML_OP] = {{NULL}, {NULL}};
183 
184 // Initialization
185 //
186 // Note: to break cycle with universe initialization, stubs are generated in two phases.
187 // The first one generates stubs needed during universe init (e.g., _handle_must_compile_first_entry).
188 // The second phase includes all other stubs (which may depend on universe being initialized.)
189 
190 extern void StubGenerator_generate(CodeBuffer* code, bool all); // only interface to generators
191 
192 void UnsafeCopyMemory::create_table(int max_size) {
193   UnsafeCopyMemory::_table = new UnsafeCopyMemory[max_size];
194   UnsafeCopyMemory::_table_max_length = max_size;
195 }
196 
197 bool UnsafeCopyMemory::contains_pc(address pc) {
198   for (int i = 0; i < UnsafeCopyMemory::_table_length; i++) {
199     UnsafeCopyMemory* entry = &UnsafeCopyMemory::_table[i];
200     if (pc >= entry->start_pc() && pc < entry->end_pc()) {

465 #define RETURN_STUB(xxx_fill) { \
466   name = #xxx_fill; \
467   return StubRoutines::xxx_fill(); }
468 
469   switch (t) {
470   case T_BYTE:
471   case T_BOOLEAN:
472     if (!aligned) RETURN_STUB(jbyte_fill);
473     RETURN_STUB(arrayof_jbyte_fill);
474   case T_CHAR:
475   case T_SHORT:
476     if (!aligned) RETURN_STUB(jshort_fill);
477     RETURN_STUB(arrayof_jshort_fill);
478   case T_INT:
479   case T_FLOAT:
480     if (!aligned) RETURN_STUB(jint_fill);
481     RETURN_STUB(arrayof_jint_fill);
482   case T_DOUBLE:
483   case T_LONG:
484   case T_ARRAY:
485   case T_INLINE_TYPE:
486   case T_OBJECT:
487   case T_NARROWOOP:
488   case T_NARROWKLASS:
489   case T_ADDRESS:
490   case T_VOID:
491     // Currently unsupported
492     return NULL;
493 
494   default:
495     ShouldNotReachHere();
496     return NULL;
497   }
498 
499 #undef RETURN_STUB
500 }
501 
502 // constants for computing the copy function
503 enum {
504   COPYFUNC_UNALIGNED = 0,
505   COPYFUNC_ALIGNED = 1,                 // src, dest aligned to HeapWordSize
< prev index next >