also rename throw_exception_from_trampoline() to throw_from_trampoline() and throw_exception_from_signal() to throw_from_signal().
Signed-off-by: Tomek Grabiec <tgrab...@gmail.com> --- arch/x86/exception.c | 8 ++++---- arch/x86/unwind_32.S | 2 +- arch/x86/unwind_64.S | 2 +- include/jit/exception.h | 12 ++++++------ jit/exception.c | 10 +++++----- vm/signal.c | 6 +++--- 6 files changed, 20 insertions(+), 20 deletions(-) diff --git a/arch/x86/exception.c b/arch/x86/exception.c index 1e6b5e3..97729c1 100644 --- a/arch/x86/exception.c +++ b/arch/x86/exception.c @@ -47,10 +47,10 @@ throw_exception(struct compilation_unit *cu, struct vm_object *exception) signal_exception(exception); - return throw_exception_from(cu, frame, native_ptr); + return throw_from_jit(cu, frame, native_ptr); } -void throw_exception_from_signal(void *ctx, struct vm_object *exception) +void throw_from_signal(void *ctx, struct vm_object *exception) { struct jit_stack_frame *frame; struct compilation_unit *cu; @@ -66,12 +66,12 @@ void throw_exception_from_signal(void *ctx, struct vm_object *exception) cu = jit_lookup_cu(source_addr); frame = (struct jit_stack_frame*)uc->uc_mcontext.gregs[REG_BP]; - eh = throw_exception_from(cu, frame, (unsigned char*)source_addr); + eh = throw_from_jit(cu, frame, (unsigned char*)source_addr); uc->uc_mcontext.gregs[REG_IP] = (unsigned long)eh; } -void throw_exception_from_trampoline(void *ctx, struct vm_object *exception) +void throw_from_trampoline(void *ctx, struct vm_object *exception) { unsigned long return_address; unsigned long *stack; diff --git a/arch/x86/unwind_32.S b/arch/x86/unwind_32.S index 146961a..6b78563 100644 --- a/arch/x86/unwind_32.S +++ b/arch/x86/unwind_32.S @@ -34,7 +34,7 @@ unwind: pushl %edx # native ptr pushl %ebp # frame pushl %ecx # cu - call throw_exception_from + call throw_from_jit addl $12, %esp pushl %eax diff --git a/arch/x86/unwind_64.S b/arch/x86/unwind_64.S index fc02857..0f120c6 100644 --- a/arch/x86/unwind_64.S +++ b/arch/x86/unwind_64.S @@ -34,7 +34,7 @@ unwind: pushq %rdx # native ptr pushq %rbp # frame pushq %rcx # cu - call throw_exception_from + call throw_from_jit addq $24, %rsp pushq %rax diff --git a/include/jit/exception.h b/include/jit/exception.h index 3185cce..8d423e1 100644 --- a/include/jit/exception.h +++ b/include/jit/exception.h @@ -47,15 +47,15 @@ extern __thread struct vm_object *exception_holder; struct cafebabe_code_attribute_exception * lookup_eh_entry(struct vm_method *method, unsigned long target); -unsigned char *throw_exception_from(struct compilation_unit *cu, - struct jit_stack_frame *frame, - unsigned char *native_ptr); +unsigned char *throw_from_jit(struct compilation_unit *cu, + struct jit_stack_frame *frame, + unsigned char *native_ptr); int insert_exception_spill_insns(struct compilation_unit *cu); unsigned char *throw_exception(struct compilation_unit *cu, struct vm_object *exception); -void throw_exception_from_signal(void *ctx, struct vm_object *exception); -void throw_exception_from_trampoline(void *ctx, struct vm_object *exception); +void throw_from_signal(void *ctx, struct vm_object *exception); +void throw_from_trampoline(void *ctx, struct vm_object *exception); void unwind(void); void signal_exception(struct vm_object *obj); int signal_new_exception(struct vm_class *vmc, const char *msg); @@ -106,7 +106,7 @@ static inline struct vm_object *exception_occurred(void) vm_leave_vm_native(); \ \ cu = jit_lookup_cu((unsigned long)native_ptr); \ - eh = throw_exception_from(cu, frame, native_ptr); \ + eh = throw_from_jit(cu, frame, native_ptr); \ \ __override_return_address(eh); \ __cleanup_args(args_size); \ diff --git a/jit/exception.c b/jit/exception.c index 16b1c5a..ae1a889 100644 --- a/jit/exception.c +++ b/jit/exception.c @@ -212,9 +212,9 @@ is_inside_unwind_unlock(struct compilation_unit *cu, unsigned char *ptr) } /** - * throw_exception_from - returns native pointer inside jitted method - * that sould be executed to handle exception. - * This can be one of the following: + * throw_from_jit - returns native pointer inside jitted method + * that sould be executed to handle exception. + * This can be one of the following: * 1) registered exception handler (catch/finally block) * 2) method's unwind block (when no handler is found) * 3) method's exit block (when no handler is found and @@ -226,8 +226,8 @@ is_inside_unwind_unlock(struct compilation_unit *cu, unsigned char *ptr) * @native_ptr: pointer to instruction that caused exception */ unsigned char * -throw_exception_from(struct compilation_unit *cu, struct jit_stack_frame *frame, - unsigned char *native_ptr) +throw_from_jit(struct compilation_unit *cu, struct jit_stack_frame *frame, + unsigned char *native_ptr) { struct vm_object *exception; unsigned long bc_offset; diff --git a/vm/signal.c b/vm/signal.c index 85d69a4..d7c9196 100644 --- a/vm/signal.c +++ b/vm/signal.c @@ -60,7 +60,7 @@ unsigned long throw_from_signal_bh(unsigned long jit_addr) cu = jit_lookup_cu(jit_addr); - return (unsigned long)throw_exception_from(cu, frame, + return (unsigned long)throw_from_jit(cu, frame, (unsigned char *)jit_addr); } @@ -139,9 +139,9 @@ static void sigsegv_handler(int sig, siginfo_t *si, void *ctx) } if (si->si_addr == trampoline_exceptions_guard_page) - throw_exception_from_trampoline(ctx, exception); + throw_from_trampoline(ctx, exception); else - throw_exception_from_signal(ctx, exception); + throw_from_signal(ctx, exception); return; } -- 1.6.0.6 ------------------------------------------------------------------------------ _______________________________________________ Jatovm-devel mailing list Jatovm-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jatovm-devel