hotspot/src/os_cpu/bsd_zero/vm/os_bsd_zero.cpp
changeset 19336 ddceb0657500
parent 14583 d70ee55535f4
child 22234 da823d78ad65
equal deleted inserted replaced
19335:ad762bd4ff48 19336:ddceb0657500
    64   return dummy;
    64   return dummy;
    65 }
    65 }
    66 
    66 
    67 frame os::get_sender_for_C_frame(frame* fr) {
    67 frame os::get_sender_for_C_frame(frame* fr) {
    68   ShouldNotCallThis();
    68   ShouldNotCallThis();
       
    69   return frame();
    69 }
    70 }
    70 
    71 
    71 frame os::current_frame() {
    72 frame os::current_frame() {
    72   // The only thing that calls this is the stack printing code in
    73   // The only thing that calls this is the stack printing code in
    73   // VMError::report:
    74   // VMError::report:
   101   // Nothing to do.
   102   // Nothing to do.
   102 }
   103 }
   103 
   104 
   104 address os::Bsd::ucontext_get_pc(ucontext_t* uc) {
   105 address os::Bsd::ucontext_get_pc(ucontext_t* uc) {
   105   ShouldNotCallThis();
   106   ShouldNotCallThis();
       
   107   return NULL;
   106 }
   108 }
   107 
   109 
   108 ExtendedPC os::fetch_frame_from_context(void* ucVoid,
   110 ExtendedPC os::fetch_frame_from_context(void* ucVoid,
   109                                         intptr_t** ret_sp,
   111                                         intptr_t** ret_sp,
   110                                         intptr_t** ret_fp) {
   112                                         intptr_t** ret_fp) {
   111   ShouldNotCallThis();
   113   ShouldNotCallThis();
       
   114   return ExtendedPC();
   112 }
   115 }
   113 
   116 
   114 frame os::fetch_frame_from_context(void* ucVoid) {
   117 frame os::fetch_frame_from_context(void* ucVoid) {
   115   ShouldNotCallThis();
   118   ShouldNotCallThis();
       
   119   return frame();
   116 }
   120 }
   117 
   121 
   118 extern "C" JNIEXPORT int
   122 extern "C" JNIEXPORT int
   119 JVM_handle_bsd_signal(int sig,
   123 JVM_handle_bsd_signal(int sig,
   120                         siginfo_t* info,
   124                         siginfo_t* info,
   238       "caught unhandled signal " INT32_FORMAT " at address " PTR_FORMAT;
   242       "caught unhandled signal " INT32_FORMAT " at address " PTR_FORMAT;
   239   char buf[128];
   243   char buf[128];
   240 
   244 
   241   sprintf(buf, fmt, sig, info->si_addr);
   245   sprintf(buf, fmt, sig, info->si_addr);
   242   fatal(buf);
   246   fatal(buf);
       
   247   return false;
   243 }
   248 }
   244 
   249 
   245 void os::Bsd::init_thread_fpu_state(void) {
   250 void os::Bsd::init_thread_fpu_state(void) {
   246   // Nothing to do
   251   // Nothing to do
   247 }
   252 }
   371 // Stubs for things that would be in bsd_zero.s if it existed.
   376 // Stubs for things that would be in bsd_zero.s if it existed.
   372 // You probably want to disassemble these monkeys to check they're ok.
   377 // You probably want to disassemble these monkeys to check they're ok.
   373 
   378 
   374 extern "C" {
   379 extern "C" {
   375   int SpinPause() {
   380   int SpinPause() {
   376   }
   381     return 1;
   377 
       
   378   int SafeFetch32(int *adr, int errValue) {
       
   379     int value = errValue;
       
   380     value = *adr;
       
   381     return value;
       
   382   }
       
   383   intptr_t SafeFetchN(intptr_t *adr, intptr_t errValue) {
       
   384     intptr_t value = errValue;
       
   385     value = *adr;
       
   386     return value;
       
   387   }
   382   }
   388 
   383 
   389   void _Copy_conjoint_jshorts_atomic(jshort* from, jshort* to, size_t count) {
   384   void _Copy_conjoint_jshorts_atomic(jshort* from, jshort* to, size_t count) {
   390     if (from > to) {
   385     if (from > to) {
   391       jshort *end = from + count;
   386       jshort *end = from + count;