96 // Nothing to do. |
96 // Nothing to do. |
97 } |
97 } |
98 |
98 |
99 address os::Linux::ucontext_get_pc(ucontext_t * uc) { |
99 address os::Linux::ucontext_get_pc(ucontext_t * uc) { |
100 //return (address)uc->uc_mcontext.gregs[REG_PC]; |
100 //return (address)uc->uc_mcontext.gregs[REG_PC]; |
101 return (address)uc->uc_mcontext.pc;//aoqi:what is gregs? |
101 return (address)uc->uc_mcontext.pc; |
102 } |
102 } |
103 |
103 |
104 intptr_t* os::Linux::ucontext_get_sp(ucontext_t * uc) { |
104 intptr_t* os::Linux::ucontext_get_sp(ucontext_t * uc) { |
105 return (intptr_t*)uc->uc_mcontext.gregs[REG_SP]; |
105 return (intptr_t*)uc->uc_mcontext.gregs[REG_SP]; |
106 } |
106 } |
564 || sig == SIGSYS |
564 || sig == SIGSYS |
565 #endif |
565 #endif |
566 ) && |
566 ) && |
567 //(uc->uc_mcontext.cause == 2 || uc->uc_mcontext.cause == 3)) { |
567 //(uc->uc_mcontext.cause == 2 || uc->uc_mcontext.cause == 3)) { |
568 (uc->uc_mcontext.hi1 == 2 || uc->uc_mcontext.hi1 == 3)) { |
568 (uc->uc_mcontext.hi1 == 2 || uc->uc_mcontext.hi1 == 3)) { |
569 //aoqi: copy from jdk1.5, dont understand the struct mcontext_t. |
|
570 #ifdef PRINT_SIGNAL_HANDLE |
569 #ifdef PRINT_SIGNAL_HANDLE |
571 tty->print_cr("execution protection violation\n"); |
570 tty->print_cr("execution protection violation\n"); |
572 #endif |
571 #endif |
573 |
572 |
574 int page_size = os::vm_page_size(); |
573 int page_size = os::vm_page_size(); |