OSDN Git Service

Fix cfi directives in small strncmp case.
authorChristopher Ferris <cferris@google.com>
Thu, 18 Feb 2016 00:34:02 +0000 (16:34 -0800)
committerChristopher Ferris <cferris@google.com>
Thu, 18 Feb 2016 00:34:02 +0000 (16:34 -0800)
Bug: 27227225
Change-Id: Id4f88fe288109a82822ad1b2291858c1c85b0ca7

libc/arch-x86/atom/string/ssse3-strcmp-atom.S

index 1275379..ee253b9 100644 (file)
@@ -115,6 +115,7 @@ name:                                       \
 ENTRY (STRCMP)
 #ifdef USE_AS_STRNCMP
        PUSH    (%ebp)
+       cfi_remember_state
 #endif
        movl    STR1(%esp), %edx
        movl    STR2(%esp), %eax
@@ -213,9 +214,6 @@ L(crosspage):
        PUSH    (%ebx)
        PUSH    (%edi)
        PUSH    (%esi)
-#ifdef USE_AS_STRNCMP
-       cfi_remember_state
-#endif
 
        movl    %edx, %edi
        movl    %eax, %ecx
@@ -2103,7 +2101,6 @@ L(neq_bigger):
        RETURN
 
 #ifdef USE_AS_STRNCMP
-       cfi_restore_state
        .p2align 4
 L(more8byteseq):
        POP     (%esi)
@@ -2120,7 +2117,7 @@ L(eq):
        ret
 
 #ifdef USE_AS_STRNCMP
-       CFI_PUSH (%ebp)
+       cfi_restore_state
 
        .p2align 4
 L(less16bytes_sncmp):