From: Andy Polyakov Date: Sat, 25 Feb 2017 21:16:38 +0000 (+0100) Subject: camellia/asm/cmll-x86_64.pl: add CFI annotations. X-Git-Tag: OpenSSL_1_1_1-pre1~2254 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=49508b23ce929ad5c8381bdc4b397eb41fd06137;p=oweals%2Fopenssl.git camellia/asm/cmll-x86_64.pl: add CFI annotations. Reviewed-by: Rich Salz --- diff --git a/crypto/camellia/asm/cmll-x86_64.pl b/crypto/camellia/asm/cmll-x86_64.pl index da5ad7b7e0..02c52c3efe 100644 --- a/crypto/camellia/asm/cmll-x86_64.pl +++ b/crypto/camellia/asm/cmll-x86_64.pl @@ -137,11 +137,17 @@ Camellia_EncryptBlock: .align 16 .Lenc_rounds: Camellia_EncryptBlock_Rounds: +.cfi_startproc push %rbx +.cfi_push %rbx push %rbp +.cfi_push %rbp push %r13 +.cfi_push %r13 push %r14 +.cfi_push %r14 push %r15 +.cfi_push %r15 .Lenc_prologue: #mov %rsi,$inp # put away arguments @@ -173,13 +179,20 @@ Camellia_EncryptBlock_Rounds: mov @S[3],12($out) mov 0(%rsp),%r15 +.cfi_restore %r15 mov 8(%rsp),%r14 +.cfi_restore %r14 mov 16(%rsp),%r13 +.cfi_restore %r13 mov 24(%rsp),%rbp +.cfi_restore %rbp mov 32(%rsp),%rbx +.cfi_restore %rbx lea 40(%rsp),%rsp +.cfi_adjust_cfa_offset -40 .Lenc_epilogue: ret +.cfi_endproc .size Camellia_EncryptBlock_Rounds,.-Camellia_EncryptBlock_Rounds .type _x86_64_Camellia_encrypt,\@abi-omnipotent @@ -247,11 +260,17 @@ Camellia_DecryptBlock: .align 16 .Ldec_rounds: Camellia_DecryptBlock_Rounds: +.cfi_startproc push %rbx +.cfi_push %rbx push %rbp +.cfi_push %rbp push %r13 +.cfi_push %r13 push %r14 +.cfi_push %r14 push %r15 +.cfi_push %r15 .Ldec_prologue: #mov %rsi,$inp # put away arguments @@ -283,13 +302,20 @@ Camellia_DecryptBlock_Rounds: mov @S[3],12($out) mov 0(%rsp),%r15 +.cfi_restore %r15 mov 8(%rsp),%r14 +.cfi_restore %r14 mov 16(%rsp),%r13 +.cfi_restore %r13 mov 24(%rsp),%rbp +.cfi_restore %rbp mov 32(%rsp),%rbx +.cfi_restore %rbx lea 40(%rsp),%rsp +.cfi_adjust_cfa_offset -40 .Ldec_epilogue: ret +.cfi_endproc .size Camellia_DecryptBlock_Rounds,.-Camellia_DecryptBlock_Rounds .type _x86_64_Camellia_decrypt,\@abi-omnipotent @@ -409,11 +435,17 @@ $code.=<<___; .type Camellia_Ekeygen,\@function,3 .align 16 Camellia_Ekeygen: +.cfi_startproc push %rbx +.cfi_push %rbx push %rbp +.cfi_push %rbp push %r13 +.cfi_push %r13 push %r14 +.cfi_push %r14 push %r15 +.cfi_push %r15 .Lkey_prologue: mov %edi,${keyend}d # put away arguments, keyBitLength @@ -573,13 +605,20 @@ $code.=<<___; mov \$4,%eax .Ldone: mov 0(%rsp),%r15 +.cfi_restore %r15 mov 8(%rsp),%r14 +.cfi_restore %r14 mov 16(%rsp),%r13 +.cfi_restore %r13 mov 24(%rsp),%rbp +.cfi_restore %rbp mov 32(%rsp),%rbx +.cfi_restore %rbx lea 40(%rsp),%rsp +.cfi_adjust_cfa_offset -40 .Lkey_epilogue: ret +.cfi_endproc .size Camellia_Ekeygen,.-Camellia_Ekeygen ___ } @@ -637,17 +676,25 @@ $code.=<<___; .type Camellia_cbc_encrypt,\@function,6 .align 16 Camellia_cbc_encrypt: +.cfi_startproc cmp \$0,%rdx je .Lcbc_abort push %rbx +.cfi_push %rbx push %rbp +.cfi_push %rbp push %r12 +.cfi_push %r12 push %r13 +.cfi_push %r13 push %r14 +.cfi_push %r14 push %r15 +.cfi_push %r15 .Lcbc_prologue: mov %rsp,%rbp +.cfi_def_cfa_register %rbp sub \$64,%rsp and \$-64,%rsp @@ -668,6 +715,7 @@ Camellia_cbc_encrypt: mov %r8,$_ivp mov %rbp,$_rsp +.cfi_cfa_expression $_rsp,deref,+56 .Lcbc_body: lea .LCamellia_SBOX(%rip),$Tbl @@ -856,15 +904,24 @@ Camellia_cbc_encrypt: .align 16 .Lcbc_done: mov $_rsp,%rcx +.cfi_def_cfa %rcx,56 mov 0(%rcx),%r15 +.cfi_restore %r15 mov 8(%rcx),%r14 +.cfi_restore %r14 mov 16(%rcx),%r13 +.cfi_restore %r13 mov 24(%rcx),%r12 +.cfi_restore %r12 mov 32(%rcx),%rbp +.cfi_restore %rbp mov 40(%rcx),%rbx +.cfi_restore %rbx lea 48(%rcx),%rsp +.cfi_def_cfa %rsp,8 .Lcbc_abort: ret +.cfi_endproc .size Camellia_cbc_encrypt,.-Camellia_cbc_encrypt .asciz "Camellia for x86_64 by "