Skip to content

Instantly share code, notes, and snippets.

@slowriot
Created November 19, 2014 22:51
Show Gist options
  • Save slowriot/8eb50f4760a6dde44a94 to your computer and use it in GitHub Desktop.
Save slowriot/8eb50f4760a6dde44a94 to your computer and use it in GitHub Desktop.
O3 result
LHOTB12:
.align 2
.p2align 4,,-1
.globl __ZN4SHA115buffer_to_blockERKSsPm
.def __ZN4SHA115buffer_to_blockERKSsPm; .scl 2; .type 32; .endef
__ZN4SHA115buffer_to_blockERKSsPm:
LFB1210:
.cfi_startproc
pushl %esi #
.cfi_def_cfa_offset 8
.cfi_offset 6, -8
pushl %ebx #
.cfi_def_cfa_offset 12
.cfi_offset 3, -12
movl 12(%esp), %eax # buffer, buffer
movl 16(%esp), %ebx # block, ivtmp.254
movl (%eax), %esi # MEM[(const struct basic_string *)buffer_8(D)]._M_dataplus._M_p, D.29502
leal 3(%esi), %ecx #, ivtmp.249
addl $67, %esi #, D.29501
.p2align 4,,10
L60:
movsbl -3(%ecx), %eax # MEM[base: _71, offset: 4294967293], D.29498
movzbl (%ecx), %edx # MEM[base: _71, offset: 0], D.29498
addl $4, %ecx #, ivtmp.249
addl $4, %ebx #, ivtmp.254
sall $24, %eax #, D.29498
orl %edx, %eax # D.29498, D.29498
movsbl -5(%ecx), %edx # MEM[base: _71, offset: 4294967295], D.29498
sall $8, %edx #, D.29498
movzwl %dx, %edx # D.29498, D.29498
orl %edx, %eax # D.29498, D.29498
movzbl -6(%ecx), %edx # MEM[base: _71, offset: 4294967294], D.29498
sall $16, %edx #, D.29498
orl %edx, %eax # D.29498, tmp129
movl %eax, -4(%ebx) # tmp129, MEM[base: _67, offset: 0B]
cmpl %esi, %ecx # D.29501, ivtmp.249
jne L60 #,
popl %ebx #
.cfi_restore 3
.cfi_def_cfa_offset 8
popl %esi #
.cfi_restore 6
.cfi_def_cfa_offset 4
ret
.cfi_endproc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment