isArmstrongNumber:
mov eax, 1
cmp edi, 9
jle .L1
mov esi, 2
cmp edi, 99
jg .L38
.L3:
mov r8d, edi
xor r9d, r9d
mov r10d, 3435973837
jmp .L5
.L15:
mov r8d, ecx
.L5:
mov ecx, r8d
mov rax, rcx
imul rax, r10
shr rax, 35
lea edx, [rax+rax*4]
mov eax, r8d
add edx, edx
sub eax, edx
mov edx, eax
imul edx, eax
cmp esi, 2
je .L4
imul edx, eax
cmp esi, 3
je .L4
imul edx, eax
cmp esi, 4
je .L4
imul edx, eax
cmp esi, 5
je .L4
imul edx, eax
cmp esi, 6
je .L4
imul edx, eax
cmp esi, 7
je .L4
imul edx, eax
cmp esi, 8
je .L4
imul edx, eax
cmp esi, 10
jne .L4
imul edx, eax
.L4:
imul rcx, r10
add r9d, edx
shr rcx, 35
cmp r8d, 9
jg .L15
xor eax, eax
cmp edi, r9d
sete al
.L1:
ret
.L38:
mov esi, 3
cmp edi, 999
jle .L3
mov esi, 4
cmp edi, 9999
jle .L3
mov esi, 5
cmp edi, 99999
jle .L3
mov esi, 6
cmp edi, 999999
jle .L3
mov esi, 7
cmp edi, 9999999
jle .L3
mov esi, 8
cmp edi, 99999999
jle .L3
xor esi, esi
cmp edi, 999999999
setg sil
add esi, 9
jmp .L3
.LC0:
.string "%d\n"
main:
push rbp
mov ebp, 1
push rbx
mov ebx, 3435973837
sub rsp, 8
.L47:
cmp ebp, 9
jle .L75
mov esi, 2
cmp ebp, 99
jle .L42
mov esi, 3
cmp ebp, 999
jle .L42
mov esi, 4
cmp ebp, 9999
jle .L42
mov esi, 5
cmp ebp, 99999
jle .L42
mov esi, 6
cmp ebp, 999999
jle .L42
mov esi, 7
cmp ebp, 9999999
jle .L42
xor esi, esi
cmp ebp, 99999999
setg sil
add esi, 8
.L42:
mov edi, ebp
xor r8d, r8d
jmp .L44
.L55:
mov edi, ecx
.L44:
mov ecx, edi
mov rax, rcx
imul rax, rbx
shr rax, 35
lea edx, [rax+rax*4]
mov eax, edi
add edx, edx
sub eax, edx
mov edx, eax
imul edx, eax
cmp esi, 2
je .L43
imul edx, eax
cmp esi, 3
je .L43
imul edx, eax
cmp esi, 4
je .L43
imul edx, eax
cmp esi, 5
je .L43
imul edx, eax
cmp esi, 6
je .L43
imul edx, eax
cmp esi, 7
je .L43
imul edx, eax
cmp esi, 9
jne .L43
imul edx, eax
.L43:
imul rcx, rbx
add r8d, edx
shr rcx, 35
cmp edi, 9
jg .L55
cmp r8d, ebp
jne .L45
mov esi, ebp
mov edi, OFFSET FLAT:.LC0
xor eax, eax
call printf
.L45:
add ebp, 1
cmp ebp, 146511209
jne .L47
add rsp, 8
xor eax, eax
pop rbx
pop rbp
ret
.L75:
mov esi, ebp
mov edi, OFFSET FLAT:.LC0
xor eax, eax
add ebp, 1
call printf
jmp .L47