From f5881ed68a05b371e7578966470ff3801b180578 Mon Sep 17 00:00:00 2001 From: Andreas Gampe Date: Wed, 23 Jul 2014 10:05:02 -0700 Subject: [PATCH] ART: Fix x86_64 instrumentation_exit, also movsd -> movq Change movd/movsd to movq. Bug: 16386215 (cherry picked from commit fea29016a79f39ac12a4ba4ebdcbc86800c03427) Change-Id: Icca71ca2aeeb2917aff46043051d6046f04395d4 --- runtime/arch/x86/quick_entrypoints_x86.S | 6 +++--- runtime/arch/x86_64/quick_entrypoints_x86_64.S | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/runtime/arch/x86/quick_entrypoints_x86.S b/runtime/arch/x86/quick_entrypoints_x86.S index 3d872978d..15221294a 100644 --- a/runtime/arch/x86/quick_entrypoints_x86.S +++ b/runtime/arch/x86/quick_entrypoints_x86.S @@ -1277,12 +1277,12 @@ DEFINE_FUNCTION art_quick_instrumentation_exit mov %esp, %ecx // Remember SP subl LITERAL(8), %esp // Save float return value. CFI_ADJUST_CFA_OFFSET(8) - movsd %xmm0, (%esp) + movq %xmm0, (%esp) PUSH edx // Save gpr return value. PUSH eax subl LITERAL(16), %esp // Align stack CFI_ADJUST_CFA_OFFSET(16) - movsd %xmm0, (%esp) // Pass float return value. + movq %xmm0, (%esp) // Pass float return value. PUSH edx // Pass gpr return value. PUSH eax PUSH ecx // Pass SP. @@ -1297,7 +1297,7 @@ DEFINE_FUNCTION art_quick_instrumentation_exit // (ebx is pretending to be our LR). POP eax // Restore gpr return value. POP edx - movsd (%esp), %xmm0 // Restore fpr return value. + movq (%esp), %xmm0 // Restore fpr return value. addl LITERAL(8), %esp CFI_ADJUST_CFA_OFFSET(-8) RESTORE_REF_ONLY_CALLEE_SAVE_FRAME diff --git a/runtime/arch/x86_64/quick_entrypoints_x86_64.S b/runtime/arch/x86_64/quick_entrypoints_x86_64.S index 885fbfde5..af2823f50 100644 --- a/runtime/arch/x86_64/quick_entrypoints_x86_64.S +++ b/runtime/arch/x86_64/quick_entrypoints_x86_64.S @@ -1492,7 +1492,7 @@ DEFINE_FUNCTION art_quick_instrumentation_exit PUSH rax // Save integer result. subq LITERAL(8), %rsp // Save floating-point result. CFI_ADJUST_CFA_OFFSET(8) - movd %xmm0, (%rsp) + movq %xmm0, (%rsp) movq %gs:THREAD_SELF_OFFSET, %rdi // Pass Thread. movq %rax, %rdx // Pass integer result. @@ -1503,7 +1503,7 @@ DEFINE_FUNCTION art_quick_instrumentation_exit movq %rax, %rdi // Store return PC movq %rdx, %rsi // Store second return PC in hidden arg. - movd (%rsp), %xmm0 // Restore floating-point result. + movq (%rsp), %xmm0 // Restore floating-point result. addq LITERAL(8), %rsp CFI_ADJUST_CFA_OFFSET(-8) POP rax // Restore integer result. -- 2.11.0