diff options
author | Ian Rogers <irogers@google.com> | 2014-01-03 01:21:40 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2014-01-03 01:21:41 +0000 |
commit | 5de028bf066052afd15c6733a4e6edfe91ad222c (patch) | |
tree | d6dd2f91821ca08ba40ab12ad11694b7fbe62ac2 | |
parent | 53ee14a160fba2c71b811c97268400c50eb08249 (diff) | |
parent | da0a4dbede243c5ac473db88d44ba6139e7dd87e (diff) | |
download | art-5de028bf066052afd15c6733a4e6edfe91ad222c.tar.gz art-5de028bf066052afd15c6733a4e6edfe91ad222c.tar.bz2 art-5de028bf066052afd15c6733a4e6edfe91ad222c.zip |
Merge "Remove extraneous CFI from x86 entrypoints to fix backtrace."
-rw-r--r-- | runtime/arch/x86/quick_entrypoints_x86.S | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/runtime/arch/x86/quick_entrypoints_x86.S b/runtime/arch/x86/quick_entrypoints_x86.S index 96794713cf..4687ecc244 100644 --- a/runtime/arch/x86/quick_entrypoints_x86.S +++ b/runtime/arch/x86/quick_entrypoints_x86.S @@ -26,11 +26,8 @@ */ MACRO0(SETUP_SAVE_ALL_CALLEE_SAVE_FRAME) PUSH edi // Save callee saves (ebx is saved/restored by the upcall) - .cfi_rel_offset edi, -8 PUSH esi - .cfi_rel_offset esi, -12 PUSH ebp - .cfi_rel_offset ebp, -16 subl MACRO_LITERAL(16), %esp // Grow stack by 4 words, bottom word will hold Method* .cfi_adjust_cfa_offset 16 END_MACRO @@ -41,11 +38,8 @@ END_MACRO */ MACRO0(SETUP_REF_ONLY_CALLEE_SAVE_FRAME) PUSH edi // Save callee saves (ebx is saved/restored by the upcall) - .cfi_rel_offset edi, -8 PUSH esi - .cfi_rel_offset esi, -12 PUSH ebp - .cfi_rel_offset ebp, -16 subl MACRO_LITERAL(16), %esp // Grow stack by 4 words, bottom word will hold Method* .cfi_adjust_cfa_offset 16 END_MACRO @@ -53,11 +47,8 @@ END_MACRO MACRO0(RESTORE_REF_ONLY_CALLEE_SAVE_FRAME) addl MACRO_LITERAL(16), %esp // Unwind stack up to return address POP ebp // Restore callee saves (ebx is saved/restored by the upcall) - .cfi_restore ebp POP esi - .cfi_restore esi POP edi - .cfi_restore edi .cfi_adjust_cfa_offset -28 END_MACRO @@ -67,36 +58,23 @@ END_MACRO */ MACRO0(SETUP_REF_AND_ARGS_CALLEE_SAVE_FRAME) PUSH edi // Save callee saves - .cfi_rel_offset edi, -8 PUSH esi - .cfi_rel_offset esi, -12 PUSH ebp - .cfi_rel_offset ebp, -16 PUSH ebx // Save args - .cfi_rel_offset ebx, -20 PUSH edx - .cfi_rel_offset edx, -24 PUSH ecx - .cfi_rel_offset ecx, -28 PUSH eax // Align stack, eax will be clobbered by Method* - .cfi_rel_offset eax, -28 END_MACRO MACRO0(RESTORE_REF_AND_ARGS_CALLEE_SAVE_FRAME) addl MACRO_LITERAL(4), %esp // Remove padding .cfi_adjust_cfa_offset -4 POP ecx // Restore args except eax - .cfi_restore ecx POP edx - .cfi_restore edx POP ebx - .cfi_restore ebx POP ebp // Restore callee saves - .cfi_restore ebp POP esi - .cfi_restore esi POP edi - .cfi_restore edi END_MACRO /* @@ -214,19 +192,12 @@ MACRO2(INVOKE_TRAMPOLINE, c_name, cxx_name) // Set up the callee save frame to conform with Runtime::CreateCalleeSaveMethod(kRefsAndArgs) // return address PUSH edi - .cfi_rel_offset edi, -8 PUSH esi - .cfi_rel_offset esi, -12 PUSH ebp - .cfi_rel_offset ebp, -16 PUSH ebx // Save args - .cfi_rel_offset ebx, -20 PUSH edx - .cfi_rel_offset edx, -24 PUSH ecx - .cfi_rel_offset ecx, -28 PUSH eax // <-- callee save Method* to go here - .cfi_rel_offset eax, -32 movl %esp, %edx // remember SP // Outgoing argument set up subl MACRO_LITERAL(12), %esp // alignment padding @@ -243,15 +214,10 @@ MACRO2(INVOKE_TRAMPOLINE, c_name, cxx_name) addl MACRO_LITERAL(36), %esp // Pop arguments skip eax .cfi_adjust_cfa_offset -36 POP ecx // Restore args except eax - .cfi_restore ecx POP edx - .cfi_restore edx POP ebx - .cfi_restore ebx POP ebp // Restore callee saves - .cfi_restore ebp POP esi - .cfi_restore esi // Swap EDI callee save with code pointer. xchgl %edi, (%esp) testl %eax, %eax // Branch forward if exception pending. @@ -286,9 +252,7 @@ INVOKE_TRAMPOLINE art_quick_invoke_virtual_trampoline_with_access_check, artInvo */ DEFINE_FUNCTION art_quick_invoke_stub PUSH ebp // save ebp - .cfi_rel_offset ebp, -8 PUSH ebx // save ebx - .cfi_rel_offset ebx, -12 mov %esp, %ebp // copy value of stack pointer into base pointer .cfi_def_cfa_register ebp mov 20(%ebp), %ebx // get arg array size @@ -311,9 +275,7 @@ DEFINE_FUNCTION art_quick_invoke_stub mov %ebp, %esp // restore stack pointer .cfi_def_cfa_register esp POP ebx // pop ebx - .cfi_restore ebx POP ebp // pop ebp - .cfi_restore ebp mov 20(%esp), %ecx // get result pointer cmpl LITERAL(68), 24(%esp) // test if result type char == 'D' je return_double_quick @@ -527,9 +489,7 @@ END_FUNCTION art_quick_is_assignable DEFINE_FUNCTION art_quick_check_cast PUSH eax // alignment padding PUSH ecx // pass arg2 - obj->klass - .cfi_rel_offset ecx, -12 PUSH eax // pass arg1 - checked class - .cfi_rel_offset eax, -16 call SYMBOL(artIsAssignableFromCode) // (Class* klass, Class* ref_klass) testl %eax, %eax jz 1f // jump forward if not assignable @@ -538,9 +498,7 @@ DEFINE_FUNCTION art_quick_check_cast ret 1: POP eax // pop arguments - .cfi_restore eax POP ecx - .cfi_restore ecx addl LITERAL(4), %esp .cfi_adjust_cfa_offset -12 SETUP_SAVE_ALL_CALLEE_SAVE_FRAME // save all registers as basis for long jump context |