files
stringlengths
20
22
x86
stringlengths
639
12.7k
risc
stringlengths
363
8.21k
eval/problem145/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 272 mov QWORD PTR -264[rbp], rdi mov QWORD PTR -272[rbp], rsi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov DWORD PTR -248[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -264[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -248[rbp] cdqe mov BYTE PTR -224[rbp+rax], dl add DWORD PTR -248[rbp], 1 .L2: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -264[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 47 jne .L3 mov eax, DWORD PTR -248[rbp] cdqe mov BYTE PTR -224[rbp+rax], 0 lea rax, -224[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -240[rbp], eax mov DWORD PTR -244[rbp], 0 add DWORD PTR -248[rbp], 1 jmp .L4 .L5: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -264[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -244[rbp] cdqe mov BYTE PTR -112[rbp+rax], dl add DWORD PTR -248[rbp], 1 add DWORD PTR -244[rbp], 1 .L4: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -264[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L5 mov eax, DWORD PTR -244[rbp] cdqe mov BYTE PTR -112[rbp+rax], 0 lea rax, -112[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -236[rbp], eax mov DWORD PTR -248[rbp], 0 jmp .L6 .L7: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -272[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -248[rbp] cdqe mov BYTE PTR -224[rbp+rax], dl add DWORD PTR -248[rbp], 1 .L6: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -272[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 47 jne .L7 mov eax, DWORD PTR -248[rbp] cdqe mov BYTE PTR -224[rbp+rax], 0 lea rax, -224[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -232[rbp], eax mov DWORD PTR -244[rbp], 0 add DWORD PTR -248[rbp], 1 jmp .L8 .L9: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -272[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -244[rbp] cdqe mov BYTE PTR -112[rbp+rax], dl add DWORD PTR -248[rbp], 1 add DWORD PTR -244[rbp], 1 .L8: mov eax, DWORD PTR -248[rbp] movsx rdx, eax mov rax, QWORD PTR -272[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L9 mov eax, DWORD PTR -244[rbp] cdqe mov BYTE PTR -112[rbp+rax], 0 lea rax, -112[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -228[rbp], eax mov eax, DWORD PTR -240[rbp] imul eax, DWORD PTR -232[rbp] mov edx, DWORD PTR -236[rbp] mov ecx, edx imul ecx, DWORD PTR -228[rbp] cdq idiv ecx mov eax, edx test eax, eax jne .L10 mov eax, 1 jmp .L12 .L10: mov eax, 0 .L12: mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L13 call __stack_chk_fail@PLT .L13: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-272 sd ra,264(sp) sd s0,256(sp) addi s0,sp,272 sd a0,-264(s0) sd a1,-272(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) sw zero,-256(s0) j .L2 .L3: lw a5,-256(s0) ld a4,-264(s0) add a5,a4,a5 lbu a4,0(a5) lw a5,-256(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-216(a5) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) .L2: lw a5,-256(s0) ld a4,-264(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,47 bne a4,a5,.L3 lw a5,-256(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-216(a5) addi a5,s0,-232 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-248(s0) sw zero,-252(s0) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) j .L4 .L5: lw a5,-256(s0) ld a4,-264(s0) add a5,a4,a5 lbu a4,0(a5) lw a5,-252(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-112(a5) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) lw a5,-252(s0) addiw a5,a5,1 sw a5,-252(s0) .L4: lw a5,-256(s0) ld a4,-264(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L5 lw a5,-252(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-112(a5) addi a5,s0,-128 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-244(s0) sw zero,-256(s0) j .L6 .L7: lw a5,-256(s0) ld a4,-272(s0) add a5,a4,a5 lbu a4,0(a5) lw a5,-256(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-216(a5) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) .L6: lw a5,-256(s0) ld a4,-272(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,47 bne a4,a5,.L7 lw a5,-256(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-216(a5) addi a5,s0,-232 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-240(s0) sw zero,-252(s0) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) j .L8 .L9: lw a5,-256(s0) ld a4,-272(s0) add a5,a4,a5 lbu a4,0(a5) lw a5,-252(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-112(a5) lw a5,-256(s0) addiw a5,a5,1 sw a5,-256(s0) lw a5,-252(s0) addiw a5,a5,1 sw a5,-252(s0) .L8: lw a5,-256(s0) ld a4,-272(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L9 lw a5,-252(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-112(a5) addi a5,s0,-128 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-236(s0) lw a4,-248(s0) lw a5,-240(s0) mulw a5,a4,a5 sext.w a3,a5 lw a4,-244(s0) lw a5,-236(s0) mulw a5,a4,a5 sext.w a5,a5 mv a4,a3 remw a5,a4,a5 sext.w a5,a5 bnez a5,.L10 li a5,1 j .L12 .L10: li a5,0 .L12: mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L13 call __stack_chk_fail@plt .L13: mv a0,a3 ld ra,264(sp) ld s0,256(sp) addi sp,sp,272 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem44/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 jmp .L2 .L7: mov eax, DWORD PTR -8[rbp] add eax, 1 mov DWORD PTR -4[rbp], eax jmp .L3 .L6: mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] add eax, edx test eax, eax jne .L4 mov eax, 1 jmp .L5 .L4: add DWORD PTR -4[rbp], 1 .L3: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L6 add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 mov eax, 0 .L5: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) j .L2 .L7: lw a5,-24(s0) addiw a5,a5,1 sw a5,-20(s0) j .L3 .L6: lw a5,-24(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) addw a5,a4,a5 sext.w a5,a5 bnez a5,.L4 li a5,1 j .L5 .L4: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L3: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 li a5,0 .L5: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem55/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -8[rbp], eax mov rax, QWORD PTR -48[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax mov DWORD PTR -24[rbp], 0 jmp .L2 .L9: mov BYTE PTR -26[rbp], 0 mov DWORD PTR -20[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -24[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -20[rbp] movsx rcx, eax mov rax, QWORD PTR -48[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al jne .L4 mov BYTE PTR -26[rbp], 1 jmp .L5 .L4: add DWORD PTR -20[rbp], 1 .L3: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -4[rbp] jl .L6 .L5: movzx eax, BYTE PTR -26[rbp] xor eax, 1 test al, al je .L7 mov eax, 0 jmp .L8 .L7: add DWORD PTR -24[rbp], 1 .L2: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -8[rbp] jl .L9 mov DWORD PTR -16[rbp], 0 jmp .L10 .L16: mov BYTE PTR -25[rbp], 0 mov DWORD PTR -12[rbp], 0 jmp .L11 .L14: mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -12[rbp] movsx rcx, eax mov rax, QWORD PTR -40[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al jne .L12 mov BYTE PTR -25[rbp], 1 jmp .L13 .L12: add DWORD PTR -12[rbp], 1 .L11: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -8[rbp] jl .L14 .L13: movzx eax, BYTE PTR -25[rbp] xor eax, 1 test al, al je .L15 mov eax, 0 jmp .L8 .L15: add DWORD PTR -16[rbp], 1 .L10: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -4[rbp] jl .L16 mov eax, 1 .L8: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-24(s0) ld a0,-64(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) sw zero,-40(s0) j .L2 .L9: sb zero,-42(s0) sw zero,-36(s0) j .L3 .L6: lw a5,-40(s0) ld a4,-56(s0) add a5,a4,a5 lbu a3,0(a5) lw a5,-36(s0) ld a4,-64(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a3 bne a4,a5,.L4 li a5,1 sb a5,-42(s0) j .L5 .L4: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: lw a4,-36(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 .L5: lbu a5,-42(s0) xori a5,a5,1 andi a5,a5,0xff beqz a5,.L7 li a5,0 j .L8 .L7: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L2: lw a4,-40(s0) lw a5,-24(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 sw zero,-32(s0) j .L10 .L16: sb zero,-41(s0) sw zero,-28(s0) j .L11 .L14: lw a5,-32(s0) ld a4,-64(s0) add a5,a4,a5 lbu a3,0(a5) lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a3 bne a4,a5,.L12 li a5,1 sb a5,-41(s0) j .L13 .L12: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L11: lw a4,-28(s0) lw a5,-24(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L14 .L13: lbu a5,-41(s0) xori a5,a5,1 andi a5,a5,0xff beqz a5,.L15 li a5,0 j .L8 .L15: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L10: lw a4,-32(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L16 li a5,1 .L8: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem61/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -4[rbp], edi mov eax, DWORD PTR -4[rbp] add eax, 1 imul eax, DWORD PTR -4[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 mv a5,a0 sw a5,-20(s0) lw a5,-20(s0) addiw a5,a5,1 sext.w a5,a5 lw a4,-20(s0) mulw a5,a4,a5 sext.w a5,a5 srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a5,a5 mv a0,a5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem10/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi cmp DWORD PTR -28[rbp], 0 jg .L2 mov eax, 0 jmp .L3 .L2: mov eax, DWORD PTR -28[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax cmp QWORD PTR -8[rbp], 0 jne .L4 mov eax, 0 jmp .L3 .L4: mov rax, QWORD PTR -24[rbp] mov eax, DWORD PTR [rax] mov DWORD PTR -16[rbp], eax mov DWORD PTR -12[rbp], 0 jmp .L5 .L7: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -16[rbp], eax jge .L6 mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -16[rbp], eax .L6: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -16[rbp] mov DWORD PTR [rdx], eax add DWORD PTR -12[rbp], 1 .L5: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 mov rax, QWORD PTR -8[rbp] .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) lw a5,-44(s0) sext.w a5,a5 bgtz a5,.L2 li a5,0 j .L3 .L2: lw a5,-44(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) bnez a5,.L4 li a5,0 j .L3 .L4: ld a5,-40(s0) lw a5,0(a5) sw a5,-32(s0) sw zero,-28(s0) j .L5 .L7: lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-32(s0) sext.w a5,a5 bge a5,a4,.L6 lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-32(s0) .L6: lw a5,-28(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-32(s0) sw a4,0(a5) lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L5: lw a4,-28(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 ld a5,-24(s0) .L3: mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem56/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 4048 mov DWORD PTR -4036[rbp], edi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax lea rdx, -4016[rbp] mov eax, 0 mov ecx, 500 mov rdi, rdx rep stosq mov DWORD PTR -4016[rbp], 0 mov DWORD PTR -4012[rbp], 1 mov DWORD PTR -4020[rbp], 2 jmp .L2 .L3: mov eax, DWORD PTR -4020[rbp] sub eax, 1 cdqe mov edx, DWORD PTR -4016[rbp+rax*4] mov eax, DWORD PTR -4020[rbp] sub eax, 2 cdqe mov eax, DWORD PTR -4016[rbp+rax*4] add edx, eax mov eax, DWORD PTR -4020[rbp] cdqe mov DWORD PTR -4016[rbp+rax*4], edx add DWORD PTR -4020[rbp], 1 .L2: mov eax, DWORD PTR -4020[rbp] cmp eax, DWORD PTR -4036[rbp] jle .L3 mov eax, DWORD PTR -4036[rbp] cdqe mov eax, DWORD PTR -4016[rbp+rax*4] mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L5 call __stack_chk_fail@PLT .L5: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-2032 sd ra,2024(sp) sd s0,2016(sp) addi s0,sp,2032 addi sp,sp,-2016 mv a4,a0 li a5,-4096 addi a3,s0,-16 add a5,a3,a5 sw a4,76(a5) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) li a5,-4096 addi a4,s0,-16 add a5,a4,a5 addi a4,a5,88 li a5,4096 addi a5,a5,-96 mv a2,a5 li a1,0 mv a0,a4 call memset@plt li a5,-4096 addi a4,s0,-16 add a5,a4,a5 sw zero,88(a5) li a5,-4096 addi a4,s0,-16 add a5,a4,a5 li a4,1 sw a4,92(a5) li a5,-4096 addi a4,s0,-16 add a5,a4,a5 li a4,2 sw a4,84(a5) j .L2 .L3: li a5,-4096 addi a4,s0,-16 add a5,a4,a5 lw a5,84(a5) addiw a5,a5,-1 sext.w a5,a5 li a4,-4096 addi a3,s0,-16 add a4,a3,a4 slli a5,a5,2 add a5,a4,a5 lw a4,88(a5) li a5,-4096 addi a3,s0,-16 add a5,a3,a5 lw a5,84(a5) addiw a5,a5,-2 sext.w a5,a5 li a3,-4096 addi a2,s0,-16 add a3,a2,a3 slli a5,a5,2 add a5,a3,a5 lw a5,88(a5) addw a5,a4,a5 sext.w a4,a5 li a5,-4096 addi a3,s0,-16 add a3,a3,a5 li a5,-4096 addi a2,s0,-16 add a5,a2,a5 lw a5,84(a5) slli a5,a5,2 add a5,a3,a5 sw a4,88(a5) li a5,-4096 addi a4,s0,-16 add a5,a4,a5 li a4,-4096 addi a3,s0,-16 add a4,a3,a4 lw a4,84(a4) addiw a4,a4,1 sw a4,84(a5) .L2: li a5,-4096 addi a4,s0,-16 add a4,a4,a5 li a5,-4096 addi a3,s0,-16 add a5,a3,a5 lw a4,84(a4) lw a5,76(a5) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L3 li a5,-4096 addi a4,s0,-16 add a4,a4,a5 li a5,-4096 addi a3,s0,-16 add a5,a3,a5 lw a5,76(a5) slli a5,a5,2 add a5,a4,a5 lw a5,88(a5) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L5 call __stack_chk_fail@plt .L5: mv a0,a3 addi sp,sp,2016 ld ra,2024(sp) ld s0,2016(sp) addi sp,sp,2032 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem11/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -12[rbp] add eax, eax add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax cmp QWORD PTR -8[rbp], 0 jne .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -24[rbp], 0 jmp .L4 .L12: mov DWORD PTR -16[rbp], 1 mov DWORD PTR -20[rbp], 0 jmp .L5 .L8: mov edx, DWORD PTR -24[rbp] mov eax, DWORD PTR -20[rbp] add eax, edx movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -12[rbp] sub eax, 1 sub eax, DWORD PTR -20[rbp] movsx rcx, eax mov rax, QWORD PTR -40[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al je .L6 mov DWORD PTR -16[rbp], 0 jmp .L7 .L6: add DWORD PTR -20[rbp], 1 .L5: mov eax, DWORD PTR -12[rbp] sub eax, DWORD PTR -24[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -20[rbp], eax jl .L8 .L7: cmp DWORD PTR -16[rbp], 0 je .L9 mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rcx, QWORD PTR -40[rbp] mov rax, QWORD PTR -8[rbp] mov rsi, rcx mov rdi, rax call strncpy@PLT mov DWORD PTR -20[rbp], 0 jmp .L10 .L11: mov eax, DWORD PTR -24[rbp] sub eax, DWORD PTR -20[rbp] cdqe lea rdx, -1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov ecx, DWORD PTR -12[rbp] mov edx, DWORD PTR -20[rbp] add edx, ecx movsx rcx, edx mov rdx, QWORD PTR -8[rbp] add rdx, rcx movzx eax, BYTE PTR [rax] mov BYTE PTR [rdx], al add DWORD PTR -20[rbp], 1 .L10: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -24[rbp] jl .L11 mov edx, DWORD PTR -12[rbp] mov eax, DWORD PTR -24[rbp] add eax, edx movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rax, QWORD PTR -8[rbp] jmp .L3 .L9: add DWORD PTR -24[rbp], 1 .L4: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -12[rbp] jl .L12 mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rcx, QWORD PTR -40[rbp] mov rax, QWORD PTR -8[rbp] mov rsi, rcx mov rdi, rax call strncpy@PLT mov DWORD PTR -20[rbp], 0 jmp .L13 .L14: mov eax, DWORD PTR -12[rbp] sub eax, DWORD PTR -20[rbp] cdqe lea rdx, -1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov ecx, DWORD PTR -12[rbp] mov edx, DWORD PTR -20[rbp] add edx, ecx movsx rcx, edx mov rdx, QWORD PTR -8[rbp] add rdx, rcx movzx eax, BYTE PTR [rax] mov BYTE PTR [rdx], al add DWORD PTR -20[rbp], 1 .L13: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -12[rbp] jl .L14 mov eax, DWORD PTR -12[rbp] add eax, eax movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rax, QWORD PTR -8[rbp] .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-28(s0) lw a5,-28(s0) slliw a5,a5,1 sext.w a5,a5 addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) bnez a5,.L2 li a5,0 j .L3 .L2: sw zero,-40(s0) j .L4 .L12: li a5,1 sw a5,-32(s0) sw zero,-36(s0) j .L5 .L8: lw a4,-40(s0) lw a5,-36(s0) addw a5,a4,a5 sext.w a5,a5 mv a4,a5 ld a5,-56(s0) add a5,a5,a4 lbu a3,0(a5) lw a5,-28(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-36(s0) subw a5,a4,a5 sext.w a5,a5 mv a4,a5 ld a5,-56(s0) add a5,a5,a4 lbu a5,0(a5) mv a4,a3 beq a4,a5,.L6 sw zero,-32(s0) j .L7 .L6: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L5: lw a4,-28(s0) lw a5,-40(s0) subw a5,a4,a5 sext.w a5,a5 srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 blt a5,a4,.L8 .L7: lw a5,-32(s0) sext.w a5,a5 beqz a5,.L9 lw a5,-28(s0) mv a2,a5 ld a1,-56(s0) ld a0,-24(s0) call strncpy@plt sw zero,-36(s0) j .L10 .L11: lw a4,-40(s0) lw a5,-36(s0) subw a5,a4,a5 sext.w a5,a5 addi a5,a5,-1 ld a4,-56(s0) add a4,a4,a5 lw a3,-28(s0) lw a5,-36(s0) addw a5,a3,a5 sext.w a5,a5 mv a3,a5 ld a5,-24(s0) add a5,a5,a3 lbu a4,0(a4) sb a4,0(a5) lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L10: lw a4,-36(s0) lw a5,-40(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L11 lw a4,-28(s0) lw a5,-40(s0) addw a5,a4,a5 sext.w a5,a5 mv a4,a5 ld a5,-24(s0) add a5,a5,a4 sb zero,0(a5) ld a5,-24(s0) j .L3 .L9: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L4: lw a4,-40(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L12 lw a5,-28(s0) mv a2,a5 ld a1,-56(s0) ld a0,-24(s0) call strncpy@plt sw zero,-36(s0) j .L13 .L14: lw a4,-28(s0) lw a5,-36(s0) subw a5,a4,a5 sext.w a5,a5 addi a5,a5,-1 ld a4,-56(s0) add a4,a4,a5 lw a3,-28(s0) lw a5,-36(s0) addw a5,a3,a5 sext.w a5,a5 mv a3,a5 ld a5,-24(s0) add a5,a5,a3 lbu a4,0(a4) sb a4,0(a5) lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L13: lw a4,-36(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L14 lw a5,-28(s0) slliw a5,a5,1 sext.w a5,a5 mv a4,a5 ld a5,-24(s0) add a5,a5,a4 sb zero,0(a5) ld a5,-24(s0) .L3: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem5/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi pxor xmm0, xmm0 movss DWORD PTR -16[rbp], xmm0 mov DWORD PTR -8[rbp], 0 mov DWORD PTR -8[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] movss xmm1, DWORD PTR -16[rbp] addss xmm0, xmm1 movss DWORD PTR -16[rbp], xmm0 add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L3 cvtsi2ss xmm1, DWORD PTR -28[rbp] movss xmm0, DWORD PTR -16[rbp] divss xmm0, xmm1 movss DWORD PTR -4[rbp], xmm0 pxor xmm0, xmm0 movss DWORD PTR -12[rbp], xmm0 mov DWORD PTR -8[rbp], 0 jmp .L4 .L5: mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] subss xmm0, DWORD PTR -4[rbp] movss xmm1, DWORD PTR .LC1[rip] andps xmm0, xmm1 movss xmm1, DWORD PTR -12[rbp] addss xmm0, xmm1 movss DWORD PTR -12[rbp], xmm0 add DWORD PTR -8[rbp], 1 .L4: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L5 cvtsi2ss xmm1, DWORD PTR -28[rbp] movss xmm0, DWORD PTR -12[rbp] divss xmm0, xmm1 pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .section .rodata .align 16 .LC1: .long 2147483647 .long 0 .long 0 .long 0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-32(s0) sw zero,-24(s0) sw zero,-24(s0) j .L2 .L3: lw a5,-24(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa5,0(a5) flw fa4,-32(s0) fadd.s fa5,fa4,fa5 fsw fa5,-32(s0) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 lw a5,-44(s0) fcvt.s.w fa5,a5 flw fa4,-32(s0) fdiv.s fa5,fa4,fa5 fsw fa5,-20(s0) sw zero,-28(s0) sw zero,-24(s0) j .L4 .L5: lw a5,-24(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa4,0(a5) flw fa5,-20(s0) fsub.s fa5,fa4,fa5 fabs.s fa5,fa5 flw fa4,-28(s0) fadd.s fa5,fa4,fa5 fsw fa5,-28(s0) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L4: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 lw a5,-44(s0) fcvt.s.w fa5,a5 flw fa4,-28(s0) fdiv.s fa5,fa4,fa5 fmv.s fa0,fa5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem15/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 56 .cfi_offset 3, -24 mov QWORD PTR -56[rbp], rdi mov QWORD PTR -64[rbp], rsi mov rax, QWORD PTR -56[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -44[rbp], eax mov eax, DWORD PTR -44[rbp] cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov QWORD PTR -32[rbp], rax mov eax, DWORD PTR -44[rbp] add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -40[rbp], rax mov rax, QWORD PTR -40[rbp] mov BYTE PTR [rax], 0 mov DWORD PTR -48[rbp], 0 jmp .L2 .L3: mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov QWORD PTR -24[rbp], rax mov rax, QWORD PTR -24[rbp] lea rdx, 2[rax] mov rax, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call realloc@PLT mov QWORD PTR -40[rbp], rax mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx mov rcx, QWORD PTR -40[rbp] mov rdx, QWORD PTR -24[rbp] add rdx, rcx movzx eax, BYTE PTR [rax] mov BYTE PTR [rdx], al mov rax, QWORD PTR -24[rbp] lea rdx, 1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT add rax, 1 mov edx, DWORD PTR -48[rbp] movsx rdx, edx lea rcx, 0[0+rdx*8] mov rdx, QWORD PTR -32[rbp] lea rbx, [rcx+rdx] mov rdi, rax call malloc@PLT mov QWORD PTR [rbx], rax mov eax, DWORD PTR -48[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdx, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call strcpy@PLT add DWORD PTR -48[rbp], 1 .L2: mov eax, DWORD PTR -48[rbp] cmp eax, DWORD PTR -44[rbp] jl .L3 mov rax, QWORD PTR -40[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -64[rbp] mov edx, DWORD PTR -44[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -32[rbp] add rsp, 56 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) sd s1,56(sp) addi s0,sp,80 sd a0,-72(s0) sd a1,-80(s0) ld a0,-72(s0) call strlen@plt mv a5,a0 sw a5,-60(s0) lw a5,-60(s0) slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-48(s0) lw a5,-60(s0) addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-56(s0) ld a5,-56(s0) sb zero,0(a5) sw zero,-64(s0) j .L2 .L3: ld a0,-56(s0) call strlen@plt sd a0,-40(s0) ld a5,-40(s0) addi a5,a5,2 mv a1,a5 ld a0,-56(s0) call realloc@plt sd a0,-56(s0) lw a5,-64(s0) ld a4,-72(s0) add a4,a4,a5 ld a3,-56(s0) ld a5,-40(s0) add a5,a3,a5 lbu a4,0(a4) sb a4,0(a5) ld a5,-40(s0) addi a5,a5,1 ld a4,-56(s0) add a5,a4,a5 sb zero,0(a5) ld a0,-56(s0) call strlen@plt mv a5,a0 addi a3,a5,1 lw a5,-64(s0) slli a5,a5,3 ld a4,-48(s0) add s1,a4,a5 mv a0,a3 call malloc@plt mv a5,a0 sd a5,0(s1) lw a5,-64(s0) slli a5,a5,3 ld a4,-48(s0) add a5,a4,a5 ld a5,0(a5) ld a1,-56(s0) mv a0,a5 call strcpy@plt lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L2: lw a4,-64(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 ld a0,-56(s0) call free@plt ld a5,-80(s0) lw a4,-60(s0) sw a4,0(a5) ld a5,-48(s0) mv a0,a5 ld ra,72(sp) ld s0,64(sp) ld s1,56(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem41/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -12[rbp], 0 jmp .L2 .L9: mov eax, DWORD PTR -12[rbp] add eax, 1 mov DWORD PTR -8[rbp], eax jmp .L3 .L8: mov eax, DWORD PTR -8[rbp] add eax, 1 mov DWORD PTR -4[rbp], eax jmp .L4 .L7: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -8[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] add edx, eax mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] add eax, edx test eax, eax jne .L5 mov eax, 1 jmp .L6 .L5: add DWORD PTR -4[rbp], 1 .L4: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L8 add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -28[rbp] jl .L9 mov eax, 0 .L6: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-28(s0) j .L2 .L9: lw a5,-28(s0) addiw a5,a5,1 sw a5,-24(s0) j .L3 .L8: lw a5,-24(s0) addiw a5,a5,1 sw a5,-20(s0) j .L4 .L7: lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-24(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) addw a5,a4,a5 sext.w a5,a5 bnez a5,.L5 li a5,1 j .L6 .L5: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L4: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 li a5,0 .L6: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem107/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov DWORD PTR -36[rbp], edi mov eax, DWORD PTR -36[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 1 mov DWORD PTR -12[rbp], 1 jmp .L2 .L5: mov eax, DWORD PTR -12[rbp] add DWORD PTR -20[rbp], eax mov eax, DWORD PTR -16[rbp] imul eax, DWORD PTR -12[rbp] mov DWORD PTR -16[rbp], eax mov eax, DWORD PTR -12[rbp] and eax, 1 test eax, eax jne .L3 mov eax, DWORD PTR -12[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -16[rbp] mov DWORD PTR [rdx], eax jmp .L4 .L3: mov eax, DWORD PTR -12[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -20[rbp] mov DWORD PTR [rdx], eax .L4: add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -36[rbp] jle .L5 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 mv a5,a0 sw a5,-52(s0) lw a5,-52(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-36(s0) li a5,1 sw a5,-32(s0) li a5,1 sw a5,-28(s0) j .L2 .L5: lw a4,-36(s0) lw a5,-28(s0) addw a5,a4,a5 sw a5,-36(s0) lw a4,-32(s0) lw a5,-28(s0) mulw a5,a4,a5 sw a5,-32(s0) lw a5,-28(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L3 lw a5,-28(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-24(s0) add a5,a4,a5 lw a4,-32(s0) sw a4,0(a5) j .L4 .L3: lw a5,-28(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-24(s0) add a5,a4,a5 lw a4,-36(s0) sw a4,0(a5) .L4: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L5 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem110/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 cmp DWORD PTR -28[rbp], 0 jne .L2 mov eax, 1 jmp .L3 .L2: mov DWORD PTR -4[rbp], 1 jmp .L4 .L6: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe sal rax, 2 lea rcx, -4[rax] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jge .L5 add DWORD PTR -8[rbp], 1 .L5: add DWORD PTR -4[rbp], 1 .L4: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L6 mov eax, DWORD PTR -28[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov rax, QWORD PTR -24[rbp] mov eax, DWORD PTR [rax] cmp edx, eax jle .L7 add DWORD PTR -8[rbp], 1 .L7: cmp DWORD PTR -8[rbp], 1 jg .L8 mov eax, 1 jmp .L3 .L8: mov eax, 0 .L3: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) lw a5,-44(s0) sext.w a5,a5 bnez a5,.L2 li a5,1 j .L3 .L2: li a5,1 sw a5,-20(s0) j .L4 .L6: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-20(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bge a4,a5,.L5 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L5: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L4: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a5,-44(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) ld a5,-40(s0) lw a5,0(a5) ble a4,a5,.L7 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L7: lw a5,-24(s0) sext.w a4,a5 li a5,1 bgt a4,a5,.L8 li a5,1 j .L3 .L8: li a5,0 .L3: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem119/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "AEIOUaeiou" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi lea rax, .LC0[rip] mov QWORD PTR -16[rbp], rax mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -8[rbp] sub eax, 2 mov DWORD PTR -20[rbp], eax jmp .L2 .L5: mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -16[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax je .L3 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -16[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax jne .L3 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, -1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -16[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax jne .L3 mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] mov BYTE PTR out.2496[rip], al lea rax, out.2496[rip] jmp .L4 .L3: sub DWORD PTR -20[rbp], 1 .L2: cmp DWORD PTR -20[rbp], 0 jg .L5 mov BYTE PTR out.2496[rip], 0 lea rax, out.2496[rip] .L4: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .local out.2496 .comm out.2496,2,1 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "AEIOUaeiou" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) lla a5,.LC0 sd a5,-32(s0) ld a0,-56(s0) call strlen@plt sd a0,-24(s0) ld a5,-24(s0) sext.w a5,a5 addiw a5,a5,-2 sext.w a5,a5 sw a5,-36(s0) j .L2 .L5: lw a5,-36(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-32(s0) call strchr@plt mv a5,a0 beqz a5,.L3 lw a5,-36(s0) addi a5,a5,1 ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-32(s0) call strchr@plt mv a5,a0 bnez a5,.L3 lw a5,-36(s0) addi a5,a5,-1 ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-32(s0) call strchr@plt mv a5,a0 bnez a5,.L3 lw a5,-36(s0) ld a4,-56(s0) add a5,a4,a5 lbu a4,0(a5) lla a5,out.2084 sb a4,0(a5) lla a5,out.2084 j .L4 .L3: lw a5,-36(s0) addiw a5,a5,-1 sw a5,-36(s0) .L2: lw a5,-36(s0) sext.w a5,a5 bgtz a5,.L5 lla a5,out.2084 sb zero,0(a5) lla a5,out.2084 .L4: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .local out.2084 .comm out.2084,2,8 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem153/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov QWORD PTR -32[rbp], rsi mov QWORD PTR -40[rbp], rdx mov DWORD PTR -44[rbp], ecx mov DWORD PTR -4[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -32[rbp] add rax, rcx mov eax, DWORD PTR [rax] sub edx, eax mov eax, edx mov edx, DWORD PTR -4[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -40[rbp] add rcx, rdx cdq xor eax, edx sub eax, edx mov DWORD PTR [rcx], eax add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -44[rbp] jl .L3 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-40(s0) sd a1,-48(s0) sd a2,-56(s0) mv a5,a3 sw a5,-60(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a3,-48(s0) add a5,a3,a5 lw a5,0(a5) subw a5,a4,a5 sext.w a4,a5 lw a5,-20(s0) slli a5,a5,2 ld a3,-56(s0) add a3,a3,a5 sraiw a5,a4,31 xor a4,a4,a5 subw a5,a4,a5 sext.w a5,a5 sw a5,0(a3) lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 nop nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem136/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], -1 mov DWORD PTR -4[rbp], 1 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe sal rax, 2 lea rcx, -4[rax] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jge .L3 mov eax, DWORD PTR -4[rbp] mov DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L4 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) li a5,-1 sw a5,-24(s0) li a5,1 sw a5,-20(s0) j .L2 .L4: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-20(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bge a4,a5,.L3 lw a5,-20(s0) sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L4 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem151/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov DWORD PTR -24[rbp], esi mov DWORD PTR -28[rbp], edx mov DWORD PTR -8[rbp], 1 cmp DWORD PTR -20[rbp], 1 jg .L2 mov DWORD PTR -8[rbp], 0 .L2: mov DWORD PTR -4[rbp], 2 jmp .L3 .L5: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -4[rbp] mov eax, edx test eax, eax jne .L4 mov DWORD PTR -8[rbp], 0 .L4: add DWORD PTR -4[rbp], 1 .L3: mov eax, DWORD PTR -4[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L5 cmp DWORD PTR -8[rbp], 0 je .L6 mov eax, DWORD PTR -24[rbp] jmp .L7 .L6: mov eax, DWORD PTR -28[rbp] .L7: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 mv a3,a1 mv a4,a2 sw a5,-36(s0) mv a5,a3 sw a5,-40(s0) mv a5,a4 sw a5,-44(s0) li a5,1 sw a5,-24(s0) lw a5,-36(s0) sext.w a4,a5 li a5,1 bgt a4,a5,.L2 sw zero,-24(s0) .L2: li a5,2 sw a5,-20(s0) j .L3 .L5: lw a4,-36(s0) lw a5,-20(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L4 sw zero,-24(s0) .L4: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L3: lw a5,-20(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L5 lw a5,-24(s0) sext.w a5,a5 beqz a5,.L6 lw a5,-40(s0) j .L7 .L6: lw a5,-44(s0) .L7: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem158/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 movss DWORD PTR -4[rbp], xmm0 movss DWORD PTR -8[rbp], xmm1 movss DWORD PTR -12[rbp], xmm2 movss xmm0, DWORD PTR -4[rbp] movaps xmm1, xmm0 mulss xmm1, xmm0 movss xmm0, DWORD PTR -8[rbp] mulss xmm0, xmm0 addss xmm1, xmm0 movss xmm0, DWORD PTR -12[rbp] mulss xmm0, xmm0 subss xmm1, xmm0 movaps xmm0, xmm1 movss xmm1, DWORD PTR .LC0[rip] andps xmm0, xmm1 cvtss2sd xmm1, xmm0 movsd xmm0, QWORD PTR .LC1[rip] comisd xmm0, xmm1 ja .L2 movss xmm0, DWORD PTR -4[rbp] movaps xmm1, xmm0 mulss xmm1, xmm0 movss xmm0, DWORD PTR -12[rbp] mulss xmm0, xmm0 addss xmm1, xmm0 movss xmm0, DWORD PTR -8[rbp] mulss xmm0, xmm0 subss xmm1, xmm0 movaps xmm0, xmm1 movss xmm1, DWORD PTR .LC0[rip] andps xmm0, xmm1 cvtss2sd xmm1, xmm0 movsd xmm0, QWORD PTR .LC1[rip] comisd xmm0, xmm1 ja .L2 movss xmm0, DWORD PTR -8[rbp] movaps xmm1, xmm0 mulss xmm1, xmm0 movss xmm0, DWORD PTR -12[rbp] mulss xmm0, xmm0 addss xmm1, xmm0 movss xmm0, DWORD PTR -4[rbp] mulss xmm0, xmm0 subss xmm1, xmm0 movaps xmm0, xmm1 movss xmm1, DWORD PTR .LC0[rip] andps xmm0, xmm1 cvtss2sd xmm1, xmm0 movsd xmm0, QWORD PTR .LC1[rip] comisd xmm0, xmm1 jbe .L6 .L2: mov eax, 1 jmp .L5 .L6: mov eax, 0 .L5: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .section .rodata .align 16 .LC0: .long 2147483647 .long 0 .long 0 .long 0 .align 8 .LC1: .long 3944497965 .long 1058682594 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 fsw fa0,-20(s0) fsw fa1,-24(s0) fsw fa2,-28(s0) flw fa5,-20(s0) fmul.s fa4,fa5,fa5 flw fa5,-24(s0) fmul.s fa5,fa5,fa5 fadd.s fa4,fa4,fa5 flw fa5,-28(s0) fmul.s fa5,fa5,fa5 fsub.s fa5,fa4,fa5 fabs.s fa5,fa5 fcvt.d.s fa4,fa5 lla a5,.LC0 fld fa5,0(a5) flt.d a5,fa4,fa5 bnez a5,.L2 flw fa5,-20(s0) fmul.s fa4,fa5,fa5 flw fa5,-28(s0) fmul.s fa5,fa5,fa5 fadd.s fa4,fa4,fa5 flw fa5,-24(s0) fmul.s fa5,fa5,fa5 fsub.s fa5,fa4,fa5 fabs.s fa5,fa5 fcvt.d.s fa4,fa5 lla a5,.LC0 fld fa5,0(a5) flt.d a5,fa4,fa5 bnez a5,.L2 flw fa5,-24(s0) fmul.s fa4,fa5,fa5 flw fa5,-28(s0) fmul.s fa5,fa5,fa5 fadd.s fa4,fa4,fa5 flw fa5,-20(s0) fmul.s fa5,fa5,fa5 fsub.s fa5,fa4,fa5 fabs.s fa5,fa5 fcvt.d.s fa4,fa5 lla a5,.LC0 fld fa5,0(a5) flt.d a5,fa4,fa5 beqz a5,.L6 .L2: li a5,1 j .L5 .L6: li a5,0 .L5: mv a0,a5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .section .rodata .align 3 .LC0: .word 3944497965 .word 1058682594 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem6/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -32[rbp], edx mov QWORD PTR -40[rbp], rcx cmp DWORD PTR -28[rbp], 0 jle .L2 mov eax, DWORD PTR -28[rbp] add eax, eax lea edx, -1[rax] jmp .L3 .L2: mov edx, 0 .L3: mov rax, QWORD PTR -40[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -40[rbp] mov eax, DWORD PTR [rax] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax cmp DWORD PTR -28[rbp], 0 jle .L4 mov rax, QWORD PTR -24[rbp] mov edx, DWORD PTR [rax] mov rax, QWORD PTR -8[rbp] mov DWORD PTR [rax], edx .L4: mov DWORD PTR -16[rbp], 1 mov DWORD PTR -12[rbp], 1 jmp .L5 .L6: mov eax, DWORD PTR -12[rbp] lea edx, 1[rax] mov DWORD PTR -12[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -32[rbp] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -12[rbp] lea edx, 1[rax] mov DWORD PTR -12[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax add DWORD PTR -16[rbp], 1 .L5: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -28[rbp] jl .L6 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 mv a4,a2 sd a3,-56(s0) sw a5,-44(s0) mv a5,a4 sw a5,-48(s0) lw a5,-44(s0) sext.w a5,a5 blez a5,.L2 lw a5,-44(s0) slliw a5,a5,1 sext.w a5,a5 addiw a5,a5,-1 sext.w a5,a5 j .L3 .L2: li a5,0 .L3: ld a4,-56(s0) sw a5,0(a4) ld a5,-56(s0) lw a5,0(a5) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) lw a5,-44(s0) sext.w a5,a5 blez a5,.L4 ld a5,-40(s0) lw a4,0(a5) ld a5,-24(s0) sw a4,0(a5) .L4: li a5,1 sw a5,-32(s0) li a5,1 sw a5,-28(s0) j .L5 .L6: lw a5,-28(s0) addiw a4,a5,1 sw a4,-28(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-48(s0) sw a4,0(a5) lw a5,-32(s0) slli a5,a5,2 ld a4,-40(s0) add a4,a4,a5 lw a5,-28(s0) addiw a3,a5,1 sw a3,-28(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L5: lw a4,-32(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem106/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "" .LC1: .string "One" .LC2: .string "Two" .LC3: .string "Three" .LC4: .string "Four" .LC5: .string "Five" .LC6: .string "Six" .LC7: .string "Seven" .LC8: .string "Eight" .LC9: .string "Nine" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 144 mov QWORD PTR -120[rbp], rdi mov DWORD PTR -124[rbp], esi mov QWORD PTR -136[rbp], rdx mov QWORD PTR -144[rbp], rcx mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax lea rax, .LC0[rip] mov QWORD PTR -96[rbp], rax lea rax, .LC1[rip] mov QWORD PTR -88[rbp], rax lea rax, .LC2[rip] mov QWORD PTR -80[rbp], rax lea rax, .LC3[rip] mov QWORD PTR -72[rbp], rax lea rax, .LC4[rip] mov QWORD PTR -64[rbp], rax lea rax, .LC5[rip] mov QWORD PTR -56[rbp], rax lea rax, .LC6[rip] mov QWORD PTR -48[rbp], rax lea rax, .LC7[rip] mov QWORD PTR -40[rbp], rax lea rax, .LC8[rip] mov QWORD PTR -32[rbp], rax lea rax, .LC9[rip] mov QWORD PTR -24[rbp], rax mov DWORD PTR -108[rbp], 0 jmp .L2 .L6: mov DWORD PTR -104[rbp], 0 jmp .L3 .L5: mov eax, DWORD PTR -104[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -104[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L4 mov eax, DWORD PTR -104[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -100[rbp], eax mov eax, DWORD PTR -104[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov edx, DWORD PTR -104[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -120[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -104[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rdx, rax mov eax, DWORD PTR -100[rbp] mov DWORD PTR [rdx], eax .L4: add DWORD PTR -104[rbp], 1 .L3: mov eax, DWORD PTR -124[rbp] sub eax, DWORD PTR -108[rbp] sub eax, 1 cmp DWORD PTR -104[rbp], eax jl .L5 add DWORD PTR -108[rbp], 1 .L2: mov eax, DWORD PTR -124[rbp] sub eax, 1 cmp DWORD PTR -108[rbp], eax jl .L6 mov rax, QWORD PTR -144[rbp] mov DWORD PTR [rax], 0 mov eax, DWORD PTR -124[rbp] sub eax, 1 mov DWORD PTR -108[rbp], eax jmp .L7 .L9: mov eax, DWORD PTR -108[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov eax, DWORD PTR [rax] test eax, eax jle .L8 mov eax, DWORD PTR -108[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp eax, 9 jg .L8 mov rax, QWORD PTR -144[rbp] mov eax, DWORD PTR [rax] lea edx, 1[rax] mov rax, QWORD PTR -144[rbp] mov DWORD PTR [rax], edx .L8: sub DWORD PTR -108[rbp], 1 .L7: cmp DWORD PTR -108[rbp], 0 jns .L9 mov rax, QWORD PTR -144[rbp] mov eax, DWORD PTR [rax] cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov rdx, rax mov rax, QWORD PTR -136[rbp] mov QWORD PTR [rax], rdx mov eax, DWORD PTR -124[rbp] sub eax, 1 mov DWORD PTR -108[rbp], eax mov DWORD PTR -104[rbp], 0 jmp .L10 .L13: mov eax, DWORD PTR -108[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov eax, DWORD PTR [rax] test eax, eax jle .L11 mov eax, DWORD PTR -108[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp eax, 9 jg .L11 mov eax, DWORD PTR -108[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -120[rbp] add rax, rdx mov ecx, DWORD PTR [rax] mov rax, QWORD PTR -136[rbp] mov rsi, QWORD PTR [rax] mov eax, DWORD PTR -104[rbp] lea edx, 1[rax] mov DWORD PTR -104[rbp], edx cdqe sal rax, 3 lea rdx, [rsi+rax] movsx rax, ecx mov rax, QWORD PTR -96[rbp+rax*8] mov QWORD PTR [rdx], rax .L11: sub DWORD PTR -108[rbp], 1 .L10: cmp DWORD PTR -108[rbp], 0 js .L15 mov rax, QWORD PTR -144[rbp] mov eax, DWORD PTR [rax] cmp DWORD PTR -104[rbp], eax jl .L13 .L15: nop mov rax, QWORD PTR -8[rbp] xor rax, QWORD PTR fs:40 je .L14 call __stack_chk_fail@PLT .L14: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .section .rodata .align 3 .LC0: .string "" .align 3 .LC1: .string "One" .align 3 .LC2: .string "Two" .align 3 .LC3: .string "Three" .align 3 .LC4: .string "Four" .align 3 .LC5: .string "Five" .align 3 .LC6: .string "Six" .align 3 .LC7: .string "Seven" .align 3 .LC8: .string "Eight" .align 3 .LC9: .string "Nine" .text .data .align 3 .LC11: .dword .LC0 .dword .LC1 .dword .LC2 .dword .LC3 .dword .LC4 .dword .LC5 .dword .LC6 .dword .LC7 .dword .LC8 .dword .LC9 .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-160 sd ra,152(sp) sd s0,144(sp) addi s0,sp,160 sd a0,-136(s0) mv a5,a1 sd a2,-152(s0) sd a3,-160(s0) sw a5,-140(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) lla a5,.LC11 ld t3,0(a5) ld t1,8(a5) ld a7,16(a5) ld a6,24(a5) ld a0,32(a5) ld a1,40(a5) ld a2,48(a5) ld a3,56(a5) ld a4,64(a5) ld a5,72(a5) sd t3,-104(s0) sd t1,-96(s0) sd a7,-88(s0) sd a6,-80(s0) sd a0,-72(s0) sd a1,-64(s0) sd a2,-56(s0) sd a3,-48(s0) sd a4,-40(s0) sd a5,-32(s0) sw zero,-116(s0) j .L2 .L6: sw zero,-112(s0) j .L3 .L5: lw a5,-112(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-112(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L4 lw a5,-112(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-108(s0) lw a5,-112(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-136(s0) add a4,a4,a5 lw a5,-112(s0) slli a5,a5,2 ld a3,-136(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-112(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a4,-108(s0) sw a4,0(a5) .L4: lw a5,-112(s0) addiw a5,a5,1 sw a5,-112(s0) .L3: lw a4,-140(s0) lw a5,-116(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 lw a5,-112(s0) sext.w a5,a5 blt a5,a4,.L5 lw a5,-116(s0) addiw a5,a5,1 sw a5,-116(s0) .L2: lw a5,-140(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-116(s0) sext.w a5,a5 blt a5,a4,.L6 ld a5,-160(s0) sw zero,0(a5) lw a5,-140(s0) addiw a5,a5,-1 sw a5,-116(s0) j .L7 .L9: lw a5,-116(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) blez a5,.L8 lw a5,-116(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,9 bgt a4,a5,.L8 ld a5,-160(s0) lw a5,0(a5) addiw a5,a5,1 sext.w a4,a5 ld a5,-160(s0) sw a4,0(a5) .L8: lw a5,-116(s0) addiw a5,a5,-1 sw a5,-116(s0) .L7: lw a5,-116(s0) sext.w a5,a5 bgez a5,.L9 ld a5,-160(s0) lw a5,0(a5) slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 mv a4,a5 ld a5,-152(s0) sd a4,0(a5) lw a5,-140(s0) addiw a5,a5,-1 sw a5,-116(s0) sw zero,-112(s0) j .L10 .L13: lw a5,-116(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) blez a5,.L11 lw a5,-116(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,9 bgt a4,a5,.L11 lw a5,-116(s0) slli a5,a5,2 ld a4,-136(s0) add a5,a4,a5 lw a3,0(a5) ld a5,-152(s0) ld a4,0(a5) lw a5,-112(s0) addiw a2,a5,1 sw a2,-112(s0) slli a5,a5,3 add a4,a4,a5 slli a5,a3,3 addi a3,s0,-16 add a5,a3,a5 ld a5,-88(a5) sd a5,0(a4) .L11: lw a5,-116(s0) addiw a5,a5,-1 sw a5,-116(s0) .L10: lw a5,-116(s0) sext.w a5,a5 bltz a5,.L15 ld a5,-160(s0) lw a4,0(a5) lw a5,-112(s0) sext.w a5,a5 blt a5,a4,.L13 .L15: nop la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L14 call __stack_chk_fail@plt .L14: ld ra,152(sp) ld s0,144(sp) addi sp,sp,160 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem47/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 448 mov DWORD PTR -436[rbp], edi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov DWORD PTR -416[rbp], 0 mov DWORD PTR -412[rbp], 0 mov DWORD PTR -408[rbp], 2 mov DWORD PTR -404[rbp], 0 mov DWORD PTR -420[rbp], 4 jmp .L2 .L3: mov eax, DWORD PTR -420[rbp] sub eax, 1 cdqe mov edx, DWORD PTR -416[rbp+rax*4] mov eax, DWORD PTR -420[rbp] sub eax, 2 cdqe mov eax, DWORD PTR -416[rbp+rax*4] add edx, eax mov eax, DWORD PTR -420[rbp] sub eax, 3 cdqe mov eax, DWORD PTR -416[rbp+rax*4] add edx, eax mov eax, DWORD PTR -420[rbp] sub eax, 4 cdqe mov eax, DWORD PTR -416[rbp+rax*4] add edx, eax mov eax, DWORD PTR -420[rbp] cdqe mov DWORD PTR -416[rbp+rax*4], edx add DWORD PTR -420[rbp], 1 .L2: mov eax, DWORD PTR -420[rbp] cmp eax, DWORD PTR -436[rbp] jle .L3 mov eax, DWORD PTR -436[rbp] cdqe mov eax, DWORD PTR -416[rbp+rax*4] mov rcx, QWORD PTR -8[rbp] xor rcx, QWORD PTR fs:40 je .L5 call __stack_chk_fail@PLT .L5: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-448 sd ra,440(sp) sd s0,432(sp) addi s0,sp,448 mv a5,a0 sw a5,-436(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) sw zero,-424(s0) sw zero,-420(s0) li a5,2 sw a5,-416(s0) sw zero,-412(s0) li a5,4 sw a5,-428(s0) j .L2 .L3: lw a5,-428(s0) addiw a5,a5,-1 sext.w a5,a5 slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a4,-408(a5) lw a5,-428(s0) addiw a5,a5,-2 sext.w a5,a5 slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 lw a5,-408(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-428(s0) addiw a5,a5,-3 sext.w a5,a5 slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 lw a5,-408(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-428(s0) addiw a5,a5,-4 sext.w a5,a5 slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 lw a5,-408(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-428(s0) slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 sw a4,-408(a5) lw a5,-428(s0) addiw a5,a5,1 sw a5,-428(s0) .L2: lw a4,-428(s0) lw a5,-436(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L3 lw a5,-436(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a5,-408(a5) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L5 call __stack_chk_fail@plt .L5: mv a0,a3 ld ra,440(sp) ld s0,432(sp) addi sp,sp,448 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem92/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -16[rbp], 1 mov DWORD PTR -12[rbp], 0 mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L9: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -4[rbp] movsx rcx, edx mov rdx, QWORD PTR -24[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movsx rdx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 8192 test eax, eax je .L3 cmp DWORD PTR -12[rbp], 0 je .L3 mov DWORD PTR -12[rbp], 0 add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 73 jne .L4 cmp DWORD PTR -16[rbp], 0 je .L4 mov DWORD PTR -12[rbp], 1 jmp .L5 .L4: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -4[rbp] movsx rcx, edx mov rdx, QWORD PTR -24[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movsx rdx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 8192 test eax, eax jne .L5 mov DWORD PTR -12[rbp], 0 .L5: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -4[rbp] movsx rcx, edx mov rdx, QWORD PTR -24[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movsx rdx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 8192 test eax, eax jne .L6 mov DWORD PTR -16[rbp], 0 .L6: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 46 je .L7 mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 63 je .L7 mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 33 jne .L8 .L7: mov DWORD PTR -16[rbp], 1 .L8: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L9 mov eax, DWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) li a5,1 sw a5,-32(s0) sw zero,-28(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L9: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-20(s0) ld a3,-40(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a4,a5 li a5,8192 and a5,a4,a5 sext.w a5,a5 beqz a5,.L3 lw a5,-28(s0) sext.w a5,a5 beqz a5,.L3 sw zero,-28(s0) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,73 bne a4,a5,.L4 lw a5,-32(s0) sext.w a5,a5 beqz a5,.L4 li a5,1 sw a5,-28(s0) j .L5 .L4: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-20(s0) ld a3,-40(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a4,a5 li a5,8192 and a5,a4,a5 sext.w a5,a5 bnez a5,.L5 sw zero,-28(s0) .L5: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-20(s0) ld a3,-40(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a4,a5 li a5,8192 and a5,a4,a5 sext.w a5,a5 bnez a5,.L6 sw zero,-32(s0) .L6: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,46 beq a4,a5,.L7 lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,63 beq a4,a5,.L7 lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,33 bne a4,a5,.L8 .L7: li a5,1 sw a5,-32(s0) .L8: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L9 lw a5,-24(s0) mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem52/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "AEIOUaeiou" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi lea rax, .LC0[rip] mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -24[rbp] mov QWORD PTR -16[rbp], rax jmp .L2 .L4: mov rax, QWORD PTR -24[rbp] movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -8[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax jne .L3 mov rax, QWORD PTR -16[rbp] lea rdx, 1[rax] mov QWORD PTR -16[rbp], rdx mov rdx, QWORD PTR -24[rbp] movzx edx, BYTE PTR [rdx] mov BYTE PTR [rax], dl .L3: add QWORD PTR -24[rbp], 1 .L2: mov rax, QWORD PTR -24[rbp] movzx eax, BYTE PTR [rax] test al, al jne .L4 mov rax, QWORD PTR -16[rbp] mov BYTE PTR [rax], 0 nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "AEIOUaeiou" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) lla a5,.LC0 sd a5,-24(s0) ld a5,-40(s0) sd a5,-32(s0) j .L2 .L4: ld a5,-40(s0) lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-24(s0) call strchr@plt mv a5,a0 bnez a5,.L3 ld a5,-32(s0) addi a4,a5,1 sd a4,-32(s0) ld a4,-40(s0) lbu a4,0(a4) sb a4,0(a5) .L3: ld a5,-40(s0) addi a5,a5,1 sd a5,-40(s0) .L2: ld a5,-40(s0) lbu a5,0(a5) bnez a5,.L4 ld a5,-32(s0) sb zero,0(a5) nop ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem24/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -4[rbp], 0 jmp .L2 .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L3 mov eax, DWORD PTR -4[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L3 lw a5,-20(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem71/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov QWORD PTR -56[rbp], rdx mov DWORD PTR -24[rbp], 0 jmp .L2 .L6: mov eax, DWORD PTR -24[rbp] add eax, 1 mov DWORD PTR -20[rbp], eax jmp .L3 .L5: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -20[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L4 mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR -24[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -40[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rdx, rax mov eax, DWORD PTR -4[rbp] mov DWORD PTR [rdx], eax .L4: add DWORD PTR -20[rbp], 1 .L3: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -44[rbp] jl .L5 add DWORD PTR -24[rbp], 1 .L2: mov eax, DWORD PTR -44[rbp] sub eax, 1 cmp DWORD PTR -24[rbp], eax jl .L6 mov DWORD PTR -16[rbp], 0 mov eax, DWORD PTR -44[rbp] sub eax, 1 mov DWORD PTR -12[rbp], eax mov DWORD PTR -8[rbp], 0 jmp .L7 .L9: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -12[rbp] jne .L8 mov eax, DWORD PTR -16[rbp] lea edx, 1[rax] mov DWORD PTR -16[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -8[rbp] lea edx, 1[rax] mov DWORD PTR -8[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax jmp .L7 .L8: mov eax, DWORD PTR -16[rbp] lea edx, 1[rax] mov DWORD PTR -16[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -8[rbp] lea edx, 1[rax] mov DWORD PTR -8[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -12[rbp] lea edx, -1[rax] mov DWORD PTR -12[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -8[rbp] lea edx, 1[rax] mov DWORD PTR -8[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax .L7: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -12[rbp] jle .L9 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd s0,72(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 sd a2,-72(s0) sw a5,-60(s0) sw zero,-40(s0) j .L2 .L6: lw a5,-40(s0) addiw a5,a5,1 sw a5,-36(s0) j .L3 .L5: lw a5,-40(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L4 lw a5,-40(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-20(s0) lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-40(s0) slli a5,a5,2 ld a3,-56(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a4,-20(s0) sw a4,0(a5) .L4: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: lw a4,-36(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L2: lw a5,-60(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-40(s0) sext.w a5,a5 blt a5,a4,.L6 sw zero,-32(s0) lw a5,-60(s0) addiw a5,a5,-1 sw a5,-28(s0) sw zero,-24(s0) j .L7 .L9: lw a4,-32(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L8 lw a5,-32(s0) addiw a4,a5,1 sw a4,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-24(s0) addiw a3,a5,1 sw a3,-24(s0) slli a5,a5,2 ld a3,-72(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) j .L7 .L8: lw a5,-32(s0) addiw a4,a5,1 sw a4,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-24(s0) addiw a3,a5,1 sw a3,-24(s0) slli a5,a5,2 ld a3,-72(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-28(s0) addiw a4,a5,-1 sw a4,-28(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-24(s0) addiw a3,a5,1 sw a3,-24(s0) slli a5,a5,2 ld a3,-72(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L7: lw a4,-32(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L9 nop nop ld s0,72(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem27/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 112 mov QWORD PTR -88[rbp], rdi mov DWORD PTR -92[rbp], esi mov QWORD PTR -104[rbp], rdx mov eax, DWORD PTR -92[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -24[rbp], rax mov eax, DWORD PTR -92[rbp] cdqe mov esi, 4 mov rdi, rax call calloc@PLT mov QWORD PTR -16[rbp], rax mov eax, DWORD PTR -92[rbp] cdqe mov esi, 4 mov rdi, rax call calloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -76[rbp], 0 mov DWORD PTR -72[rbp], 0 mov DWORD PTR -68[rbp], 0 mov DWORD PTR -64[rbp], 0 jmp .L2 .L14: mov eax, DWORD PTR -64[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -88[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -28[rbp], eax mov DWORD PTR -60[rbp], 0 mov DWORD PTR -56[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -56[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -28[rbp], eax jne .L4 mov DWORD PTR -60[rbp], 1 jmp .L5 .L4: add DWORD PTR -56[rbp], 1 .L3: mov eax, DWORD PTR -56[rbp] cmp eax, DWORD PTR -72[rbp] jl .L6 .L5: cmp DWORD PTR -60[rbp], 0 jne .L23 mov DWORD PTR -52[rbp], 0 mov DWORD PTR -48[rbp], 0 jmp .L9 .L12: mov eax, DWORD PTR -48[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -28[rbp], eax jne .L10 mov DWORD PTR -52[rbp], 1 jmp .L11 .L10: add DWORD PTR -48[rbp], 1 .L9: mov eax, DWORD PTR -48[rbp] cmp eax, DWORD PTR -76[rbp] jl .L12 .L11: cmp DWORD PTR -52[rbp], 0 je .L13 mov eax, DWORD PTR -72[rbp] lea edx, 1[rax] mov DWORD PTR -72[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -28[rbp] mov DWORD PTR [rdx], eax jmp .L8 .L13: mov eax, DWORD PTR -76[rbp] lea edx, 1[rax] mov DWORD PTR -76[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rdx, rax mov eax, DWORD PTR -28[rbp] mov DWORD PTR [rdx], eax jmp .L8 .L23: nop .L8: add DWORD PTR -64[rbp], 1 .L2: mov eax, DWORD PTR -64[rbp] cmp eax, DWORD PTR -92[rbp] jl .L14 mov DWORD PTR -44[rbp], 0 jmp .L15 .L21: mov eax, DWORD PTR -44[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -88[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -32[rbp], eax mov DWORD PTR -40[rbp], 0 mov DWORD PTR -36[rbp], 0 jmp .L16 .L19: mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -32[rbp], eax jne .L17 mov DWORD PTR -40[rbp], 1 jmp .L18 .L17: add DWORD PTR -36[rbp], 1 .L16: mov eax, DWORD PTR -36[rbp] cmp eax, DWORD PTR -72[rbp] jl .L19 .L18: cmp DWORD PTR -40[rbp], 0 jne .L20 mov eax, DWORD PTR -68[rbp] lea edx, 1[rax] mov DWORD PTR -68[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rdx, rax mov eax, DWORD PTR -32[rbp] mov DWORD PTR [rdx], eax .L20: add DWORD PTR -44[rbp], 1 .L15: mov eax, DWORD PTR -44[rbp] cmp eax, DWORD PTR -92[rbp] jl .L21 mov rax, QWORD PTR -104[rbp] mov edx, DWORD PTR -68[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -16[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -24[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-128 sd ra,120(sp) sd s0,112(sp) addi s0,sp,128 sd a0,-104(s0) mv a5,a1 sd a2,-120(s0) sw a5,-108(s0) lw a5,-108(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-40(s0) lw a5,-108(s0) li a1,4 mv a0,a5 call calloc@plt mv a5,a0 sd a5,-32(s0) lw a5,-108(s0) li a1,4 mv a0,a5 call calloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-92(s0) sw zero,-88(s0) sw zero,-84(s0) sw zero,-80(s0) j .L2 .L14: lw a5,-80(s0) slli a5,a5,2 ld a4,-104(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-44(s0) sw zero,-76(s0) sw zero,-72(s0) j .L3 .L6: lw a5,-72(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-44(s0) sext.w a5,a5 bne a5,a4,.L4 li a5,1 sw a5,-76(s0) j .L5 .L4: lw a5,-72(s0) addiw a5,a5,1 sw a5,-72(s0) .L3: lw a4,-72(s0) lw a5,-88(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 .L5: lw a5,-76(s0) sext.w a5,a5 bnez a5,.L23 sw zero,-68(s0) sw zero,-64(s0) j .L9 .L12: lw a5,-64(s0) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-44(s0) sext.w a5,a5 bne a5,a4,.L10 li a5,1 sw a5,-68(s0) j .L11 .L10: lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L9: lw a4,-64(s0) lw a5,-92(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L12 .L11: lw a5,-68(s0) sext.w a5,a5 beqz a5,.L13 lw a5,-88(s0) addiw a4,a5,1 sw a4,-88(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-44(s0) sw a4,0(a5) j .L8 .L13: lw a5,-92(s0) addiw a4,a5,1 sw a4,-92(s0) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,-44(s0) sw a4,0(a5) j .L8 .L23: nop .L8: lw a5,-80(s0) addiw a5,a5,1 sw a5,-80(s0) .L2: lw a4,-80(s0) lw a5,-108(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L14 sw zero,-60(s0) j .L15 .L21: lw a5,-60(s0) slli a5,a5,2 ld a4,-104(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-48(s0) sw zero,-56(s0) sw zero,-52(s0) j .L16 .L19: lw a5,-52(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-48(s0) sext.w a5,a5 bne a5,a4,.L17 li a5,1 sw a5,-56(s0) j .L18 .L17: lw a5,-52(s0) addiw a5,a5,1 sw a5,-52(s0) .L16: lw a4,-52(s0) lw a5,-88(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L19 .L18: lw a5,-56(s0) sext.w a5,a5 bnez a5,.L20 lw a5,-84(s0) addiw a4,a5,1 sw a4,-84(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,-48(s0) sw a4,0(a5) .L20: lw a5,-60(s0) addiw a5,a5,1 sw a5,-60(s0) .L15: lw a4,-60(s0) lw a5,-108(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L21 ld a5,-120(s0) lw a4,-84(s0) sw a4,0(a5) ld a0,-32(s0) call free@plt ld a0,-24(s0) call free@plt ld a5,-40(s0) mv a0,a5 ld ra,120(sp) ld s0,112(sp) addi sp,sp,128 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem36/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi movss xmm0, DWORD PTR .LC0[rip] movss DWORD PTR -8[rbp], xmm0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] comiss xmm0, DWORD PTR -8[rbp] jbe .L3 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] movss DWORD PTR -8[rbp], xmm0 .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L5 movss xmm0, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .section .rodata .align 4 .LC0: .long 3323740160 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) lla a5,.LC0 flw fa5,0(a5) fsw fa5,-24(s0) sw zero,-20(s0) j .L2 .L5: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa5,0(a5) flw fa4,-24(s0) flt.s a5,fa4,fa5 beqz a5,.L3 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa5,0(a5) fsw fa5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 flw fa5,-24(s0) fmv.s fa0,fa5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .section .rodata .align 2 .LC0: .word 3323740160 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem31/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov eax, DWORD PTR -28[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -40[rbp] mov DWORD PTR [rax], 0 mov DWORD PTR -12[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] pxor xmm1, xmm1 comiss xmm0, xmm1 jbe .L3 mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] lea rsi, [rdx+rax] mov rax, QWORD PTR -40[rbp] mov eax, DWORD PTR [rax] lea ecx, 1[rax] mov rdx, QWORD PTR -40[rbp] mov DWORD PTR [rdx], ecx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm0, DWORD PTR [rsi] movss DWORD PTR [rax], xmm0 .L3: add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -28[rbp] jl .L5 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) sw a5,-44(s0) lw a5,-44(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-56(s0) sw zero,0(a5) sw zero,-28(s0) j .L2 .L5: lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa5,0(a5) fmv.s.x fa4,zero fgt.s a5,fa5,fa4 beqz a5,.L3 lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a4,a4,a5 ld a5,-56(s0) lw a5,0(a5) addiw a3,a5,1 sext.w a2,a3 ld a3,-56(s0) sw a2,0(a3) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 flw fa5,0(a4) fsw fa5,0(a5) .L3: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem86/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] add eax, eax cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] and eax, 1 test eax, eax jne .L3 mov eax, DWORD PTR -4[rbp] add eax, eax cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] add eax, eax add eax, 1 cmp DWORD PTR -28[rbp], eax jg .L4 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L4: lw a5,-20(s0) slliw a5,a5,1 sext.w a5,a5 addi a5,a5,1 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sext.w a5,a5 andi a5,a5,1 sext.w a5,a5 bnez a5,.L3 lw a5,-20(s0) slliw a5,a5,1 sext.w a5,a5 addi a5,a5,1 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) slliw a5,a5,1 sext.w a5,a5 addiw a5,a5,1 sext.w a4,a5 lw a5,-44(s0) sext.w a5,a5 bgt a5,a4,.L4 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem77/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov DWORD PTR -24[rbp], esi mov DWORD PTR -8[rbp], 1 mov DWORD PTR -4[rbp], 0 jmp .L2 .L6: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -20[rbp] jne .L3 mov eax, 1 jmp .L4 .L3: mov eax, DWORD PTR -8[rbp] imul eax, DWORD PTR -24[rbp] mov DWORD PTR -8[rbp], eax add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -20[rbp] jg .L5 cmp DWORD PTR -4[rbp], 99 jle .L6 .L5: mov eax, 0 .L4: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 mv a4,a1 sw a5,-36(s0) mv a5,a4 sw a5,-40(s0) li a5,1 sw a5,-24(s0) sw zero,-20(s0) j .L2 .L6: lw a4,-24(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L3 li a5,1 j .L4 .L3: lw a4,-24(s0) lw a5,-40(s0) mulw a5,a4,a5 sw a5,-24(s0) lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-24(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 bgt a4,a5,.L5 lw a5,-20(s0) sext.w a4,a5 li a5,99 ble a4,a5,.L6 .L5: li a5,0 .L4: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem9/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov DWORD PTR -12[rbp], 0 mov DWORD PTR -8[rbp], 1 mov DWORD PTR -4[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -12[rbp], eax mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov edx, DWORD PTR -8[rbp] imul eax, edx mov DWORD PTR -8[rbp], eax add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L3 mov rax, QWORD PTR -40[rbp] mov edx, DWORD PTR -12[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -40[rbp] lea rdx, 4[rax] mov eax, DWORD PTR -8[rbp] mov DWORD PTR [rdx], eax nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) sw a5,-44(s0) sw zero,-28(s0) li a5,1 sw a5,-24(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-28(s0) addw a5,a4,a5 sw a5,-28(s0) lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) mulw a5,a4,a5 sw a5,-24(s0) lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 ld a5,-56(s0) lw a4,-28(s0) sw a4,0(a5) ld a5,-56(s0) addi a5,a5,4 lw a4,-24(s0) sw a4,0(a5) nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem64/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 448 mov DWORD PTR -436[rbp], edi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax lea rdx, -416[rbp] mov eax, 0 mov ecx, 50 mov rdi, rdx rep stosq mov DWORD PTR -412[rbp], 0 mov DWORD PTR -408[rbp], 1 mov DWORD PTR -420[rbp], 3 jmp .L2 .L3: mov eax, DWORD PTR -420[rbp] sub eax, 1 cdqe mov edx, DWORD PTR -416[rbp+rax*4] mov eax, DWORD PTR -420[rbp] sub eax, 2 cdqe mov eax, DWORD PTR -416[rbp+rax*4] add edx, eax mov eax, DWORD PTR -420[rbp] sub eax, 3 cdqe mov eax, DWORD PTR -416[rbp+rax*4] add edx, eax mov eax, DWORD PTR -420[rbp] cdqe mov DWORD PTR -416[rbp+rax*4], edx add DWORD PTR -420[rbp], 1 .L2: mov eax, DWORD PTR -420[rbp] cmp eax, DWORD PTR -436[rbp] jle .L3 mov eax, DWORD PTR -436[rbp] cdqe mov eax, DWORD PTR -416[rbp+rax*4] mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L5 call __stack_chk_fail@PLT .L5: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-448 sd ra,440(sp) sd s0,432(sp) addi s0,sp,448 mv a5,a0 sw a5,-436(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) addi a5,s0,-424 li a4,400 mv a2,a4 li a1,0 mv a0,a5 call memset@plt sw zero,-420(s0) li a5,1 sw a5,-416(s0) li a5,3 sw a5,-428(s0) j .L2 .L3: lw a5,-428(s0) addiw a5,a5,-1 sext.w a5,a5 slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a4,-408(a5) lw a5,-428(s0) addiw a5,a5,-2 sext.w a5,a5 slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 lw a5,-408(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-428(s0) addiw a5,a5,-3 sext.w a5,a5 slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 lw a5,-408(a5) addw a5,a4,a5 sext.w a4,a5 lw a5,-428(s0) slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 sw a4,-408(a5) lw a5,-428(s0) addiw a5,a5,1 sw a5,-428(s0) .L2: lw a4,-428(s0) lw a5,-436(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L3 lw a5,-436(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a5,-408(a5) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L5 call __stack_chk_fail@plt .L5: mv a0,a3 ld ra,440(sp) ld s0,432(sp) addi sp,sp,448 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem123/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp eax, -99 jl .L3 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp eax, 99 jg .L3 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L4 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L4: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,-99 blt a4,a5,.L3 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,99 bgt a4,a5,.L3 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L4 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem161/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "**" .LC1: .string "*" .LC2: .string "//" .LC3: .string "+" .LC4: .string "-" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 80 mov QWORD PTR -56[rbp], rdi mov QWORD PTR -64[rbp], rsi mov DWORD PTR -68[rbp], edx mov DWORD PTR -72[rbp], ecx mov eax, DWORD PTR -72[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -16[rbp], rax mov eax, DWORD PTR -72[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -36[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -64[rbp] add rax, rdx mov edx, DWORD PTR -36[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -16[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -36[rbp] mov DWORD PTR [rdx], eax add DWORD PTR -36[rbp], 1 .L2: mov eax, DWORD PTR -36[rbp] cmp eax, DWORD PTR -72[rbp] jl .L3 mov DWORD PTR -32[rbp], 0 jmp .L4 .L10: mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC0[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L5 jmp .L6 .L7: mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -32[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L6: mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -32[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L7 jmp .L8 .L9: mov eax, DWORD PTR -32[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -32[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L8: mov eax, DWORD PTR -32[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -32[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L9 mov eax, DWORD PTR -32[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov eax, DWORD PTR [rax] cvtsi2sd xmm1, eax mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov eax, DWORD PTR [rax] cvtsi2sd xmm0, eax call pow@PLT mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rdx, rax cvttsd2si eax, xmm0 mov DWORD PTR [rdx], eax mov eax, DWORD PTR -32[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -32[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L5: add DWORD PTR -32[rbp], 1 .L4: mov eax, DWORD PTR -32[rbp] cmp eax, DWORD PTR -68[rbp] jl .L10 mov DWORD PTR -28[rbp], 0 jmp .L11 .L20: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC1[rip] mov rdi, rax call strcmp@PLT test eax, eax je .L14 mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC2[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L13 jmp .L14 .L15: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -28[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L14: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L15 jmp .L16 .L17: mov eax, DWORD PTR -28[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -28[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L16: mov eax, DWORD PTR -28[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L17 mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC1[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L18 mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov ecx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov edx, DWORD PTR -28[rbp] movsx rdx, edx lea rsi, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rsi mov edx, DWORD PTR [rdx] movsx rdx, edx lea rsi, 0[0+rdx*4] mov rdx, QWORD PTR -16[rbp] add rdx, rsi imul eax, ecx mov DWORD PTR [rdx], eax jmp .L19 .L18: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov edx, DWORD PTR -28[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov edx, DWORD PTR [rdx] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -16[rbp] add rdx, rcx mov edi, DWORD PTR [rdx] mov ecx, DWORD PTR -28[rbp] movsx rcx, ecx lea rsi, 0[0+rcx*4] mov rcx, QWORD PTR -8[rbp] add rcx, rsi mov ecx, DWORD PTR [rcx] movsx rcx, ecx lea rsi, 0[0+rcx*4] mov rcx, QWORD PTR -16[rbp] add rcx, rsi cdq idiv edi mov DWORD PTR [rcx], eax .L19: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -28[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L13: add DWORD PTR -28[rbp], 1 .L11: mov eax, DWORD PTR -28[rbp] cmp eax, DWORD PTR -68[rbp] jl .L20 mov DWORD PTR -24[rbp], 0 jmp .L21 .L30: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC3[rip] mov rdi, rax call strcmp@PLT test eax, eax je .L24 mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC4[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L23 jmp .L24 .L25: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -24[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L24: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L25 jmp .L26 .L27: mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -24[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L26: mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L27 mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rax, QWORD PTR [rax] lea rsi, .LC3[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L28 mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov ecx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe lea rsi, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rsi mov eax, DWORD PTR [rax] cdqe lea rsi, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rsi add edx, ecx mov DWORD PTR [rax], edx jmp .L29 .L28: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov ecx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe lea rsi, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rsi mov eax, DWORD PTR [rax] cdqe lea rsi, 0[0+rax*4] mov rax, QWORD PTR -16[rbp] add rax, rsi sub ecx, edx mov edx, ecx mov DWORD PTR [rax], edx .L29: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -24[rbp] movsx rdx, edx add rdx, 1 lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax .L23: add DWORD PTR -24[rbp], 1 .L21: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -68[rbp] jl .L30 mov rax, QWORD PTR -16[rbp] mov eax, DWORD PTR [rax] mov DWORD PTR -20[rbp], eax mov rax, QWORD PTR -16[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT mov eax, DWORD PTR -20[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "**" .align 3 .LC1: .string "*" .align 3 .LC2: .string "//" .align 3 .LC3: .string "+" .align 3 .LC4: .string "-" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-96 sd ra,88(sp) sd s0,80(sp) addi s0,sp,96 sd a0,-72(s0) sd a1,-80(s0) mv a5,a2 mv a4,a3 sw a5,-84(s0) mv a5,a4 sw a5,-88(s0) lw a5,-88(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-32(s0) lw a5,-88(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-52(s0) j .L2 .L3: lw a5,-52(s0) slli a5,a5,2 ld a4,-80(s0) add a4,a4,a5 lw a5,-52(s0) slli a5,a5,2 ld a3,-32(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-52(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-52(s0) sw a4,0(a5) lw a5,-52(s0) addiw a5,a5,1 sw a5,-52(s0) .L2: lw a4,-52(s0) lw a5,-88(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 sw zero,-48(s0) j .L4 .L10: lw a5,-48(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC0 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L5 j .L6 .L7: lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-48(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L6: lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L7 j .L8 .L9: lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L8: lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L9 lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a5,0(a5) fcvt.d.w fa5,a5 lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a5,0(a5) fcvt.d.w fa4,a5 fmv.d fa1,fa4 fmv.d fa0,fa5 call pow@plt fmv.d fa5,fa0 lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 fcvt.w.d a4,fa5,rtz sext.w a4,a4 sw a4,0(a5) lw a5,-48(s0) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-48(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L5: lw a5,-48(s0) addiw a5,a5,1 sw a5,-48(s0) .L4: lw a4,-48(s0) lw a5,-84(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L10 sw zero,-44(s0) j .L11 .L20: lw a5,-44(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC1 mv a0,a5 call strcmp@plt mv a5,a0 beqz a5,.L14 lw a5,-44(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC2 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L13 j .L14 .L15: lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-44(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L14: lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L15 j .L16 .L17: lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L16: lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L17 lw a5,-44(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC1 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L18 lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-44(s0) slli a5,a5,2 ld a2,-24(s0) add a5,a2,a5 lw a5,0(a5) slli a5,a5,2 ld a2,-32(s0) add a5,a2,a5 mulw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) j .L19 .L18: lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-44(s0) slli a5,a5,2 ld a2,-24(s0) add a5,a2,a5 lw a5,0(a5) slli a5,a5,2 ld a2,-32(s0) add a5,a2,a5 divw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) .L19: lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-44(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L13: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L11: lw a4,-44(s0) lw a5,-84(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L20 sw zero,-40(s0) j .L21 .L30: lw a5,-40(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC3 mv a0,a5 call strcmp@plt mv a5,a0 beqz a5,.L24 lw a5,-40(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC4 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L23 j .L24 .L25: lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-40(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L24: lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L25 j .L26 .L27: lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L26: lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L27 lw a5,-40(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a5,0(a5) lla a1,.LC3 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L28 lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-40(s0) slli a5,a5,2 ld a2,-24(s0) add a5,a2,a5 lw a5,0(a5) slli a5,a5,2 ld a2,-32(s0) add a5,a2,a5 addw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) j .L29 .L28: lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) slli a5,a5,2 ld a4,-32(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-40(s0) slli a5,a5,2 ld a2,-24(s0) add a5,a2,a5 lw a5,0(a5) slli a5,a5,2 ld a2,-32(s0) add a5,a2,a5 subw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) .L29: lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L23: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L21: lw a4,-40(s0) lw a5,-84(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L30 ld a5,-32(s0) lw a5,0(a5) sw a5,-36(s0) ld a0,-32(s0) call free@plt ld a0,-24(s0) call free@plt lw a5,-36(s0) mv a0,a5 ld ra,88(sp) ld s0,80(sp) addi sp,sp,96 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem114/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .align 8 .LC0: .string "the number of odd elements %d in the string %d of the %d input." .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 56 .cfi_offset 3, -24 mov QWORD PTR -56[rbp], rdi mov DWORD PTR -60[rbp], esi mov eax, DWORD PTR -60[rbp] cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov QWORD PTR -24[rbp], rax mov DWORD PTR -36[rbp], 0 jmp .L2 .L6: mov DWORD PTR -32[rbp], 0 mov DWORD PTR -28[rbp], 0 jmp .L3 .L5: mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rdx, QWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 47 jle .L4 mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rdx, QWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 57 jg .L4 mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rdx, QWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, rdx movzx eax, BYTE PTR [rax] movsx eax, al lea edx, -48[rax] mov eax, edx sar eax, 31 shr eax, 31 add edx, eax and edx, 1 sub edx, eax mov eax, edx cmp eax, 1 jne .L4 add DWORD PTR -32[rbp], 1 .L4: add DWORD PTR -28[rbp], 1 .L3: mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -56[rbp] add rax, rdx mov rdx, QWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L5 mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] lea rbx, [rdx+rax] mov edi, 100 call malloc@PLT mov QWORD PTR [rbx], rax mov eax, DWORD PTR -36[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov esi, DWORD PTR -32[rbp] mov ecx, DWORD PTR -32[rbp] mov edx, DWORD PTR -32[rbp] mov r8d, esi lea rsi, .LC0[rip] mov rdi, rax mov eax, 0 call sprintf@PLT add DWORD PTR -36[rbp], 1 .L2: mov eax, DWORD PTR -36[rbp] cmp eax, DWORD PTR -60[rbp] jl .L6 mov rax, QWORD PTR -24[rbp] add rsp, 56 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "the number of odd elements %d in the string %d of the %d input." .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) sd s1,56(sp) addi s0,sp,80 sd a0,-72(s0) mv a5,a1 sw a5,-76(s0) lw a5,-76(s0) slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-40(s0) sw zero,-52(s0) j .L2 .L6: sw zero,-48(s0) sw zero,-44(s0) j .L3 .L5: lw a5,-52(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-44(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,47 bleu a4,a5,.L4 lw a5,-52(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-44(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,57 bgtu a4,a5,.L4 lw a5,-52(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-44(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 addiw a5,a5,-48 sext.w a5,a5 mv a4,a5 sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L4 lw a5,-48(s0) addiw a5,a5,1 sw a5,-48(s0) .L4: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L3: lw a5,-52(s0) slli a5,a5,3 ld a4,-72(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-44(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L5 lw a5,-52(s0) slli a5,a5,3 ld a4,-40(s0) add s1,a4,a5 li a0,100 call malloc@plt mv a5,a0 sd a5,0(s1) lw a5,-52(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a5,0(a5) lw a4,-48(s0) lw a3,-48(s0) lw a2,-48(s0) lla a1,.LC0 mv a0,a5 call sprintf@plt lw a5,-52(s0) addiw a5,a5,1 sw a5,-52(s0) .L2: lw a4,-52(s0) lw a5,-76(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 ld a5,-40(s0) mv a0,a5 ld ra,72(sp) ld s0,64(sp) ld s1,56(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem105/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov QWORD PTR -56[rbp], rdx mov QWORD PTR -64[rbp], rcx mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov rdx, rax mov rax, QWORD PTR -56[rbp] mov QWORD PTR [rax], rdx mov rax, QWORD PTR -64[rbp] mov DWORD PTR [rax], 0 mov DWORD PTR -20[rbp], 0 jmp .L2 .L9: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -16[rbp], eax mov BYTE PTR -21[rbp], 0 cmp DWORD PTR -16[rbp], 0 jne .L4 mov BYTE PTR -21[rbp], 1 jmp .L4 .L7: mov eax, DWORD PTR -16[rbp] and eax, 1 test eax, eax jne .L5 mov BYTE PTR -21[rbp], 1 .L5: mov eax, DWORD PTR -16[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -16[rbp], eax .L4: cmp DWORD PTR -16[rbp], 0 jle .L6 movzx eax, BYTE PTR -21[rbp] xor eax, 1 test al, al jne .L7 .L6: movzx eax, BYTE PTR -21[rbp] xor eax, 1 test al, al je .L8 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov rax, QWORD PTR -56[rbp] mov rdx, QWORD PTR [rax] mov rax, QWORD PTR -64[rbp] mov eax, DWORD PTR [rax] cdqe sal rax, 2 add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax mov rax, QWORD PTR -64[rbp] mov eax, DWORD PTR [rax] lea edx, 1[rax] mov rax, QWORD PTR -64[rbp] mov DWORD PTR [rax], edx .L8: add DWORD PTR -20[rbp], 1 .L2: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -44[rbp] jl .L9 mov DWORD PTR -12[rbp], 0 jmp .L10 .L14: mov DWORD PTR -8[rbp], 0 jmp .L11 .L13: mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov edx, DWORD PTR -8[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov edx, DWORD PTR [rax] mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov ecx, DWORD PTR -8[rbp] movsx rcx, ecx add rcx, 1 sal rcx, 2 add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L12 mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov edx, DWORD PTR -8[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -4[rbp], eax mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov edx, DWORD PTR -8[rbp] movsx rdx, edx add rdx, 1 sal rdx, 2 lea rcx, [rax+rdx] mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov edx, DWORD PTR -8[rbp] movsx rdx, edx sal rdx, 2 add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax mov rax, QWORD PTR -56[rbp] mov rax, QWORD PTR [rax] mov edx, DWORD PTR -8[rbp] movsx rdx, edx add rdx, 1 sal rdx, 2 add rdx, rax mov eax, DWORD PTR -4[rbp] mov DWORD PTR [rdx], eax .L12: add DWORD PTR -8[rbp], 1 .L11: mov rax, QWORD PTR -64[rbp] mov eax, DWORD PTR [rax] sub eax, DWORD PTR -12[rbp] sub eax, 1 cmp DWORD PTR -8[rbp], eax jl .L13 add DWORD PTR -12[rbp], 1 .L10: mov rax, QWORD PTR -64[rbp] mov eax, DWORD PTR [rax] sub eax, 1 cmp DWORD PTR -12[rbp], eax jl .L14 nop nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 sd a2,-72(s0) sd a3,-80(s0) sw a5,-60(s0) lw a5,-60(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 mv a4,a5 ld a5,-72(s0) sd a4,0(a5) ld a5,-80(s0) sw zero,0(a5) sw zero,-36(s0) j .L2 .L9: lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-32(s0) sb zero,-37(s0) lw a5,-32(s0) sext.w a5,a5 bnez a5,.L4 li a5,1 sb a5,-37(s0) j .L4 .L7: lw a5,-32(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L5 li a5,1 sb a5,-37(s0) .L5: lw a4,-32(s0) li a5,10 divw a5,a4,a5 sw a5,-32(s0) .L4: lw a5,-32(s0) sext.w a5,a5 blez a5,.L6 lbu a5,-37(s0) xori a5,a5,1 andi a5,a5,0xff bnez a5,.L7 .L6: lbu a5,-37(s0) xori a5,a5,1 andi a5,a5,0xff beqz a5,.L8 lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 ld a5,-72(s0) ld a3,0(a5) ld a5,-80(s0) lw a5,0(a5) slli a5,a5,2 add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) ld a5,-80(s0) lw a5,0(a5) addiw a5,a5,1 sext.w a4,a5 ld a5,-80(s0) sw a4,0(a5) .L8: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L2: lw a4,-36(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 sw zero,-28(s0) j .L10 .L14: sw zero,-24(s0) j .L11 .L13: ld a5,-72(s0) ld a4,0(a5) lw a5,-24(s0) slli a5,a5,2 add a5,a4,a5 lw a3,0(a5) ld a5,-72(s0) ld a4,0(a5) lw a5,-24(s0) addi a5,a5,1 slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L12 ld a5,-72(s0) ld a4,0(a5) lw a5,-24(s0) slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) sw a5,-20(s0) ld a5,-72(s0) ld a4,0(a5) lw a5,-24(s0) addi a5,a5,1 slli a5,a5,2 add a4,a4,a5 ld a5,-72(s0) ld a3,0(a5) lw a5,-24(s0) slli a5,a5,2 add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) ld a5,-72(s0) ld a4,0(a5) lw a5,-24(s0) addi a5,a5,1 slli a5,a5,2 add a5,a4,a5 lw a4,-20(s0) sw a4,0(a5) .L12: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L11: ld a5,-80(s0) lw a4,0(a5) lw a5,-28(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 lw a5,-24(s0) sext.w a5,a5 blt a5,a4,.L13 lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L10: ld a5,-80(s0) lw a5,0(a5) addiw a5,a5,-1 sext.w a4,a5 lw a5,-28(s0) sext.w a5,a5 blt a5,a4,.L14 nop nop ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem113/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "True" .LC1: .string "False" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 80 mov QWORD PTR -56[rbp], rdi mov QWORD PTR -64[rbp], rsi mov QWORD PTR -72[rbp], rdx mov QWORD PTR -80[rbp], rcx mov rax, QWORD PTR -56[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -24[rbp], eax mov eax, DWORD PTR -24[rbp] add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -36[rbp], 0 mov DWORD PTR -32[rbp], 0 jmp .L2 .L8: mov rax, QWORD PTR -64[rbp] mov QWORD PTR -16[rbp], rax mov BYTE PTR -38[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -32[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov rax, QWORD PTR -16[rbp] movzx eax, BYTE PTR [rax] cmp dl, al jne .L4 mov BYTE PTR -38[rbp], 1 jmp .L5 .L4: add QWORD PTR -16[rbp], 1 .L3: mov rax, QWORD PTR -16[rbp] movzx eax, BYTE PTR [rax] test al, al jne .L6 .L5: movzx eax, BYTE PTR -38[rbp] xor eax, 1 test al, al je .L7 mov eax, DWORD PTR -32[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -36[rbp] lea edx, 1[rax] mov DWORD PTR -36[rbp], edx movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rdx, rax movzx eax, BYTE PTR [rcx] mov BYTE PTR [rdx], al .L7: add DWORD PTR -32[rbp], 1 .L2: mov eax, DWORD PTR -32[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L8 mov eax, DWORD PTR -36[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rax, QWORD PTR -8[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -20[rbp], eax mov BYTE PTR -37[rbp], 1 mov DWORD PTR -28[rbp], 0 jmp .L9 .L12: mov eax, DWORD PTR -28[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -20[rbp] sub eax, 1 sub eax, DWORD PTR -28[rbp] movsx rcx, eax mov rax, QWORD PTR -8[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al je .L10 mov BYTE PTR -37[rbp], 0 jmp .L11 .L10: add DWORD PTR -28[rbp], 1 .L9: mov eax, DWORD PTR -20[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -28[rbp], eax jl .L12 .L11: mov rdx, QWORD PTR -8[rbp] mov rax, QWORD PTR -72[rbp] mov rsi, rdx mov rdi, rax call strcpy@PLT cmp BYTE PTR -37[rbp], 0 je .L13 lea rax, .LC0[rip] jmp .L14 .L13: lea rax, .LC1[rip] .L14: mov rdx, QWORD PTR -80[rbp] mov rsi, rax mov rdi, rdx call strcpy@PLT mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "True" .align 3 .LC1: .string "False" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-96 sd ra,88(sp) sd s0,80(sp) addi s0,sp,96 sd a0,-72(s0) sd a1,-80(s0) sd a2,-88(s0) sd a3,-96(s0) ld a0,-72(s0) call strlen@plt mv a5,a0 sw a5,-40(s0) lw a5,-40(s0) addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-52(s0) sw zero,-48(s0) j .L2 .L8: ld a5,-80(s0) sd a5,-32(s0) sb zero,-54(s0) j .L3 .L6: lw a5,-48(s0) ld a4,-72(s0) add a5,a4,a5 lbu a4,0(a5) ld a5,-32(s0) lbu a5,0(a5) bne a4,a5,.L4 li a5,1 sb a5,-54(s0) j .L5 .L4: ld a5,-32(s0) addi a5,a5,1 sd a5,-32(s0) .L3: ld a5,-32(s0) lbu a5,0(a5) bnez a5,.L6 .L5: lbu a5,-54(s0) xori a5,a5,1 andi a5,a5,0xff beqz a5,.L7 lw a5,-48(s0) ld a4,-72(s0) add a4,a4,a5 lw a5,-52(s0) addiw a3,a5,1 sw a3,-52(s0) mv a3,a5 ld a5,-24(s0) add a5,a5,a3 lbu a4,0(a4) sb a4,0(a5) .L7: lw a5,-48(s0) addiw a5,a5,1 sw a5,-48(s0) .L2: lw a5,-48(s0) ld a4,-72(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L8 lw a5,-52(s0) ld a4,-24(s0) add a5,a4,a5 sb zero,0(a5) ld a0,-24(s0) call strlen@plt mv a5,a0 sw a5,-36(s0) li a5,1 sb a5,-53(s0) sw zero,-44(s0) j .L9 .L12: lw a5,-44(s0) ld a4,-24(s0) add a5,a4,a5 lbu a3,0(a5) lw a5,-36(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-44(s0) subw a5,a4,a5 sext.w a5,a5 mv a4,a5 ld a5,-24(s0) add a5,a5,a4 lbu a5,0(a5) mv a4,a3 beq a4,a5,.L10 sb zero,-53(s0) j .L11 .L10: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L9: lw a5,-36(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-44(s0) sext.w a5,a5 blt a5,a4,.L12 .L11: ld a1,-24(s0) ld a0,-88(s0) call strcpy@plt lbu a5,-53(s0) andi a5,a5,0xff beqz a5,.L13 lla a5,.LC0 j .L14 .L13: lla a5,.LC1 .L14: mv a1,a5 ld a0,-96(s0) call strcpy@plt ld a0,-24(s0) call free@plt nop ld ra,88(sp) ld s0,80(sp) addi sp,sp,96 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem108/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov DWORD PTR -36[rbp], edi mov edi, 8 call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -8[rbp] mov DWORD PTR [rax], 0 mov rax, QWORD PTR -8[rbp] add rax, 4 mov DWORD PTR [rax], 0 mov DWORD PTR -24[rbp], 1 jmp .L2 .L7: mov DWORD PTR -20[rbp], 0 mov eax, DWORD PTR -24[rbp] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -24[rbp] mov DWORD PTR -16[rbp], eax jmp .L3 .L4: mov edx, DWORD PTR -20[rbp] mov eax, edx sal eax, 2 add eax, edx add eax, eax mov esi, eax mov ecx, DWORD PTR -16[rbp] movsx rax, ecx imul rax, rax, 1717986919 shr rax, 32 mov edx, eax sar edx, 2 mov eax, ecx sar eax, 31 sub edx, eax mov eax, edx sal eax, 2 add eax, edx add eax, eax sub ecx, eax mov edx, ecx lea eax, [rsi+rdx] mov DWORD PTR -20[rbp], eax mov eax, DWORD PTR -16[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -16[rbp], eax .L3: cmp DWORD PTR -16[rbp], 0 jne .L4 mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -20[rbp] jne .L5 mov eax, DWORD PTR -12[rbp] and eax, 1 test eax, eax jne .L6 mov rax, QWORD PTR -8[rbp] mov eax, DWORD PTR [rax] lea edx, 1[rax] mov rax, QWORD PTR -8[rbp] mov DWORD PTR [rax], edx jmp .L5 .L6: mov rax, QWORD PTR -8[rbp] add rax, 4 mov edx, DWORD PTR [rax] add edx, 1 mov DWORD PTR [rax], edx .L5: add DWORD PTR -24[rbp], 1 .L2: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -36[rbp] jle .L7 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 mv a5,a0 sw a5,-52(s0) li a0,8 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) sw zero,0(a5) ld a5,-24(s0) addi a5,a5,4 sw zero,0(a5) li a5,1 sw a5,-40(s0) j .L2 .L7: sw zero,-36(s0) lw a5,-40(s0) sw a5,-28(s0) lw a5,-40(s0) sw a5,-32(s0) j .L3 .L4: lw a4,-36(s0) mv a5,a4 slliw a5,a5,2 addw a5,a5,a4 slliw a5,a5,1 sext.w a4,a5 lw a3,-32(s0) li a5,10 remw a5,a3,a5 sext.w a5,a5 addw a5,a4,a5 sw a5,-36(s0) lw a4,-32(s0) li a5,10 divw a5,a4,a5 sw a5,-32(s0) .L3: lw a5,-32(s0) sext.w a5,a5 bnez a5,.L4 lw a4,-28(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L5 lw a5,-28(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L6 ld a5,-24(s0) lw a5,0(a5) addiw a5,a5,1 sext.w a4,a5 ld a5,-24(s0) sw a4,0(a5) j .L5 .L6: ld a5,-24(s0) addi a5,a5,4 lw a4,0(a5) addiw a4,a4,1 sext.w a4,a4 sw a4,0(a5) .L5: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L2: lw a4,-40(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L7 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem83/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi mov rax, QWORD PTR -24[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax cmp DWORD PTR -4[rbp], 1 jg .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -8[rbp], 2 jmp .L4 .L6: mov eax, DWORD PTR -4[rbp] cdq idiv DWORD PTR -8[rbp] mov eax, edx test eax, eax jne .L5 mov eax, 0 jmp .L3 .L5: add DWORD PTR -8[rbp], 1 .L4: mov eax, DWORD PTR -8[rbp] imul eax, eax cmp DWORD PTR -4[rbp], eax jge .L6 mov eax, 1 .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) ld a0,-40(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) lw a5,-20(s0) sext.w a4,a5 li a5,1 bgt a4,a5,.L2 li a5,0 j .L3 .L2: li a5,2 sw a5,-24(s0) j .L4 .L6: lw a4,-20(s0) lw a5,-24(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L5 li a5,0 j .L3 .L5: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L4: lw a5,-24(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-20(s0) sext.w a5,a5 bge a5,a4,.L6 li a5,1 .L3: mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem144/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi mov DWORD PTR -4[rbp], 0 mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 mov DWORD PTR -12[rbp], 0 jmp .L2 .L13: mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 32 je .L3 add DWORD PTR -20[rbp], 1 jmp .L4 .L3: cmp DWORD PTR -20[rbp], 1 jle .L5 mov BYTE PTR -21[rbp], 1 mov DWORD PTR -8[rbp], 2 jmp .L6 .L9: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -8[rbp] mov eax, edx test eax, eax jne .L7 mov BYTE PTR -21[rbp], 0 jmp .L10 .L7: add DWORD PTR -8[rbp], 1 .L6: mov eax, DWORD PTR -8[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L9 jmp .L10 .L5: mov BYTE PTR -21[rbp], 0 .L10: cmp BYTE PTR -21[rbp], 0 je .L11 cmp DWORD PTR -16[rbp], 0 jle .L12 mov eax, DWORD PTR -16[rbp] lea edx, 1[rax] mov DWORD PTR -16[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 32 .L12: mov eax, DWORD PTR -20[rbp] cdqe mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov edx, DWORD PTR -20[rbp] movsx rdx, edx sub rcx, rdx mov rdx, QWORD PTR -40[rbp] lea rsi, [rcx+rdx] mov edx, DWORD PTR -16[rbp] movsx rcx, edx mov rdx, QWORD PTR -48[rbp] add rcx, rdx mov rdx, rax mov rdi, rcx call memcpy@PLT mov eax, DWORD PTR -20[rbp] add DWORD PTR -16[rbp], eax .L11: mov DWORD PTR -20[rbp], 0 .L4: add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L13 cmp DWORD PTR -20[rbp], 1 jle .L14 mov BYTE PTR -21[rbp], 1 mov DWORD PTR -8[rbp], 2 jmp .L15 .L18: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -8[rbp] mov eax, edx test eax, eax jne .L16 mov BYTE PTR -21[rbp], 0 jmp .L19 .L16: add DWORD PTR -8[rbp], 1 .L15: mov eax, DWORD PTR -8[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L18 jmp .L19 .L14: mov BYTE PTR -21[rbp], 0 .L19: cmp BYTE PTR -21[rbp], 0 je .L20 cmp DWORD PTR -16[rbp], 0 jle .L21 mov eax, DWORD PTR -16[rbp] lea edx, 1[rax] mov DWORD PTR -16[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 32 .L21: mov eax, DWORD PTR -20[rbp] cdqe mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov edx, DWORD PTR -20[rbp] movsx rdx, edx sub rcx, rdx mov rdx, QWORD PTR -40[rbp] lea rsi, [rcx+rdx] mov edx, DWORD PTR -16[rbp] movsx rcx, edx mov rdx, QWORD PTR -48[rbp] add rcx, rdx mov rdx, rax mov rdi, rcx call memcpy@PLT mov eax, DWORD PTR -20[rbp] add DWORD PTR -16[rbp], eax .L20: mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 0 nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) sw zero,-20(s0) sw zero,-36(s0) sw zero,-32(s0) sw zero,-28(s0) j .L2 .L13: lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,32 beq a4,a5,.L3 lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) j .L4 .L3: lw a5,-36(s0) sext.w a4,a5 li a5,1 ble a4,a5,.L5 li a5,1 sb a5,-37(s0) li a5,2 sw a5,-24(s0) j .L6 .L9: lw a4,-36(s0) lw a5,-24(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L7 sb zero,-37(s0) j .L10 .L7: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L6: lw a5,-24(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L9 j .L10 .L5: sb zero,-37(s0) .L10: lbu a5,-37(s0) andi a5,a5,0xff beqz a5,.L11 lw a5,-32(s0) sext.w a5,a5 blez a5,.L12 lw a5,-32(s0) addiw a4,a5,1 sw a4,-32(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,32 sb a4,0(a5) .L12: lw a5,-32(s0) ld a4,-64(s0) add a3,a4,a5 lw a4,-28(s0) lw a5,-36(s0) sub a5,a4,a5 ld a4,-56(s0) add a5,a4,a5 lw a4,-36(s0) mv a2,a4 mv a1,a5 mv a0,a3 call memcpy@plt lw a4,-32(s0) lw a5,-36(s0) addw a5,a4,a5 sw a5,-32(s0) .L11: sw zero,-36(s0) .L4: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L13 lw a5,-36(s0) sext.w a4,a5 li a5,1 ble a4,a5,.L14 li a5,1 sb a5,-37(s0) li a5,2 sw a5,-24(s0) j .L15 .L18: lw a4,-36(s0) lw a5,-24(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L16 sb zero,-37(s0) j .L19 .L16: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L15: lw a5,-24(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L18 j .L19 .L14: sb zero,-37(s0) .L19: lbu a5,-37(s0) andi a5,a5,0xff beqz a5,.L20 lw a5,-32(s0) sext.w a5,a5 blez a5,.L21 lw a5,-32(s0) addiw a4,a5,1 sw a4,-32(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,32 sb a4,0(a5) .L21: lw a5,-32(s0) ld a4,-64(s0) add a3,a4,a5 lw a4,-28(s0) lw a5,-36(s0) sub a5,a4,a5 ld a4,-56(s0) add a5,a4,a5 lw a4,-36(s0) mv a2,a4 mv a1,a5 mv a0,a3 call memcpy@plt lw a4,-32(s0) lw a5,-36(s0) addw a5,a4,a5 sw a5,-32(s0) .L20: lw a5,-32(s0) ld a4,-64(s0) add a5,a4,a5 sb zero,0(a5) nop ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem141/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 40 .cfi_offset 3, -24 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi mov DWORD PTR -28[rbp], 0 mov DWORD PTR -24[rbp], 0 mov DWORD PTR -20[rbp], 0 jmp .L2 .L8: mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 32 jne .L3 add DWORD PTR -28[rbp], 1 jmp .L4 .L3: cmp DWORD PTR -28[rbp], 1 jne .L5 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 .L5: cmp DWORD PTR -28[rbp], 2 jne .L6 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 .L6: cmp DWORD PTR -28[rbp], 2 jle .L7 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 45 .L7: mov DWORD PTR -28[rbp], 0 mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rdx, rax movzx eax, BYTE PTR [rcx] mov BYTE PTR [rdx], al .L4: add DWORD PTR -20[rbp], 1 .L2: mov eax, DWORD PTR -20[rbp] movsx rbx, eax mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT cmp rbx, rax jb .L8 cmp DWORD PTR -28[rbp], 1 jne .L9 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 .L9: cmp DWORD PTR -28[rbp], 2 jne .L10 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 95 .L10: cmp DWORD PTR -28[rbp], 2 jle .L11 mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 45 .L11: mov eax, DWORD PTR -24[rbp] movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 0 nop add rsp, 40 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) sd s1,40(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) sw zero,-44(s0) sw zero,-40(s0) sw zero,-36(s0) j .L2 .L8: lw a5,-36(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,32 bne a4,a5,.L3 lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) j .L4 .L3: lw a5,-44(s0) sext.w a4,a5 li a5,1 bne a4,a5,.L5 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) .L5: lw a5,-44(s0) sext.w a4,a5 li a5,2 bne a4,a5,.L6 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) .L6: lw a5,-44(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L7 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,45 sb a4,0(a5) .L7: sw zero,-44(s0) lw a5,-36(s0) ld a4,-56(s0) add a4,a4,a5 lw a5,-40(s0) addiw a3,a5,1 sw a3,-40(s0) mv a3,a5 ld a5,-64(s0) add a5,a5,a3 lbu a4,0(a4) sb a4,0(a5) .L4: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L2: lw s1,-36(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 bltu s1,a5,.L8 lw a5,-44(s0) sext.w a4,a5 li a5,1 bne a4,a5,.L9 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) .L9: lw a5,-44(s0) sext.w a4,a5 li a5,2 bne a4,a5,.L10 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,95 sb a4,0(a5) .L10: lw a5,-44(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L11 lw a5,-40(s0) addiw a4,a5,1 sw a4,-40(s0) mv a4,a5 ld a5,-64(s0) add a5,a5,a4 li a4,45 sb a4,0(a5) .L11: lw a5,-40(s0) ld a4,-64(s0) add a5,a4,a5 sb zero,0(a5) nop ld ra,56(sp) ld s0,48(sp) ld s1,40(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem3/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 movss DWORD PTR -4[rbp], xmm0 movss xmm0, DWORD PTR -4[rbp] cvttss2si eax, xmm0 cvtsi2ss xmm1, eax movss xmm0, DWORD PTR -4[rbp] subss xmm0, xmm1 pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 fsw fa0,-20(s0) flw fa5,-20(s0) fcvt.w.s a5,fa5,rtz sext.w a5,a5 fcvt.s.w fa5,a5 flw fa4,-20(s0) fsub.s fa5,fa4,fa5 fmv.s fa0,fa5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem94/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "aeiouAEIOU" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi lea rax, .LC0[rip] mov QWORD PTR -8[rbp], rax mov DWORD PTR -16[rbp], 0 jmp .L2 .L10: mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] mov BYTE PTR -17[rbp], al call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] movsx rdx, BYTE PTR -17[rbp] add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 512 test eax, eax je .L3 movsx eax, BYTE PTR -17[rbp] mov edi, eax call toupper@PLT mov BYTE PTR -17[rbp], al jmp .L4 .L3: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] movsx rdx, BYTE PTR -17[rbp] add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 256 test eax, eax je .L4 movsx eax, BYTE PTR -17[rbp] mov edi, eax call tolower@PLT mov BYTE PTR -17[rbp], al .L4: mov DWORD PTR -12[rbp], 0 jmp .L5 .L9: mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp BYTE PTR -17[rbp], al jne .L6 cmp DWORD PTR -12[rbp], 9 jg .L11 movzx eax, BYTE PTR -17[rbp] add eax, 2 mov BYTE PTR -17[rbp], al jmp .L11 .L6: add DWORD PTR -12[rbp], 1 .L5: mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L9 jmp .L8 .L11: nop .L8: mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rdx, rax movzx eax, BYTE PTR -17[rbp] mov BYTE PTR [rdx], al add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L10 mov eax, DWORD PTR -16[rbp] movsx rdx, eax mov rax, QWORD PTR -48[rbp] add rax, rdx mov BYTE PTR [rax], 0 nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "aeiouAEIOU" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) lla a5,.LC0 sd a5,-24(s0) sw zero,-32(s0) j .L2 .L10: lw a5,-32(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sb a5,-33(s0) call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lbu a5,-33(s0) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,512 sext.w a5,a5 beqz a5,.L3 lbu a5,-33(s0) sext.w a5,a5 mv a0,a5 call toupper@plt mv a5,a0 sb a5,-33(s0) j .L4 .L3: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lbu a5,-33(s0) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,256 sext.w a5,a5 beqz a5,.L4 lbu a5,-33(s0) sext.w a5,a5 mv a0,a5 call tolower@plt mv a5,a0 sb a5,-33(s0) .L4: sw zero,-28(s0) j .L5 .L9: lw a5,-28(s0) ld a4,-24(s0) add a5,a4,a5 lbu a4,0(a5) lbu a5,-33(s0) andi a5,a5,0xff bne a5,a4,.L6 lw a5,-28(s0) sext.w a4,a5 li a5,9 bgt a4,a5,.L11 lbu a5,-33(s0) addiw a5,a5,2 sb a5,-33(s0) j .L11 .L6: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L5: lw a5,-28(s0) ld a4,-24(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L9 j .L8 .L11: nop .L8: lw a5,-32(s0) ld a4,-64(s0) add a5,a4,a5 lbu a4,-33(s0) sb a4,0(a5) lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a5,-32(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L10 lw a5,-32(s0) ld a4,-64(s0) add a5,a4,a5 sb zero,0(a5) nop ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem130/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov DWORD PTR -48[rbp], edx mov QWORD PTR -56[rbp], rcx mov DWORD PTR -28[rbp], 0 jmp .L2 .L6: mov DWORD PTR -24[rbp], 0 jmp .L3 .L5: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -24[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] cmp eax, 1 jne .L4 mov eax, DWORD PTR -28[rbp] mov DWORD PTR -20[rbp], eax mov eax, DWORD PTR -24[rbp] mov DWORD PTR -16[rbp], eax .L4: add DWORD PTR -24[rbp], 1 .L3: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -44[rbp] jl .L5 add DWORD PTR -28[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] cmp eax, DWORD PTR -44[rbp] jl .L6 mov eax, DWORD PTR -44[rbp] imul eax, eax mov DWORD PTR -12[rbp], eax cmp DWORD PTR -20[rbp], 0 jle .L7 mov eax, DWORD PTR -20[rbp] cdqe sal rax, 3 lea rdx, -8[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jle .L7 mov eax, DWORD PTR -20[rbp] cdqe sal rax, 3 lea rdx, -8[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax .L7: mov eax, DWORD PTR -44[rbp] sub eax, 1 cmp DWORD PTR -20[rbp], eax jge .L8 mov eax, DWORD PTR -20[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jle .L8 mov eax, DWORD PTR -20[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax .L8: cmp DWORD PTR -16[rbp], 0 jle .L9 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 sub rdx, 4 add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jle .L9 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx sal rdx, 2 sub rdx, 4 add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax .L9: mov eax, DWORD PTR -44[rbp] sub eax, 1 cmp DWORD PTR -16[rbp], eax jge .L10 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx add rdx, 1 sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jle .L10 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -16[rbp] movsx rdx, edx add rdx, 1 sal rdx, 2 add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax .L10: mov rax, QWORD PTR -56[rbp] mov edx, DWORD PTR -48[rbp] mov DWORD PTR [rax], edx mov eax, DWORD PTR -48[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -28[rbp], 0 jmp .L11 .L14: mov eax, DWORD PTR -28[rbp] and eax, 1 test eax, eax jne .L12 mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov DWORD PTR [rax], 1 jmp .L13 .L12: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -12[rbp] mov DWORD PTR [rdx], eax .L13: add DWORD PTR -28[rbp], 1 .L11: mov eax, DWORD PTR -28[rbp] cmp eax, DWORD PTR -48[rbp] jl .L14 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 mv a4,a2 sd a3,-72(s0) sw a5,-60(s0) mv a5,a4 sw a5,-64(s0) sw zero,-44(s0) j .L2 .L6: sw zero,-40(s0) j .L3 .L5: lw a5,-44(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-40(s0) slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,1 bne a4,a5,.L4 lw a5,-44(s0) sw a5,-36(s0) lw a5,-40(s0) sw a5,-32(s0) .L4: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L3: lw a4,-40(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L2: lw a4,-44(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a5,-60(s0) mulw a5,a5,a5 sw a5,-28(s0) lw a5,-36(s0) sext.w a5,a5 blez a5,.L7 lw a5,-36(s0) slli a5,a5,3 addi a5,a5,-8 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L7 lw a5,-36(s0) slli a5,a5,3 addi a5,a5,-8 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) .L7: lw a5,-60(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L8 lw a5,-36(s0) addi a5,a5,1 slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L8 lw a5,-36(s0) addi a5,a5,1 slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) .L8: lw a5,-32(s0) sext.w a5,a5 blez a5,.L9 lw a5,-36(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 addi a5,a5,-4 add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L9 lw a5,-36(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) slli a5,a5,2 addi a5,a5,-4 add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) .L9: lw a5,-60(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-32(s0) sext.w a5,a5 bge a5,a4,.L10 lw a5,-36(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) addi a5,a5,1 slli a5,a5,2 add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L10 lw a5,-36(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-32(s0) addi a5,a5,1 slli a5,a5,2 add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) .L10: ld a5,-72(s0) lw a4,-64(s0) sw a4,0(a5) lw a5,-64(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-44(s0) j .L11 .L14: lw a5,-44(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L12 lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 li a4,1 sw a4,0(a5) j .L13 .L12: lw a5,-44(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-28(s0) sw a4,0(a5) .L13: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L11: lw a4,-44(s0) lw a5,-64(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L14 ld a5,-24(s0) mv a0,a5 ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem99/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "AEIOU" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 40 .cfi_offset 3, -24 mov QWORD PTR -40[rbp], rdi lea rax, .LC0[rip] mov QWORD PTR -24[rbp], rax mov DWORD PTR -32[rbp], 0 mov DWORD PTR -28[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -28[rbp] add eax, eax movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -24[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax je .L3 add DWORD PTR -32[rbp], 1 .L3: add DWORD PTR -28[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al je .L4 mov eax, DWORD PTR -28[rbp] add eax, eax movsx rbx, eax mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT cmp rbx, rax jb .L5 .L4: mov eax, DWORD PTR -32[rbp] add rsp, 40 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "AEIOU" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) sd s1,40(sp) addi s0,sp,64 sd a0,-56(s0) lla a5,.LC0 sd a5,-40(s0) sw zero,-48(s0) sw zero,-44(s0) j .L2 .L5: lw a5,-44(s0) slliw a5,a5,1 sext.w a5,a5 mv a4,a5 ld a5,-56(s0) add a5,a5,a4 lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-40(s0) call strchr@plt mv a5,a0 beqz a5,.L3 lw a5,-48(s0) addiw a5,a5,1 sw a5,-48(s0) .L3: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L2: lw a5,-44(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) beqz a5,.L4 lw a5,-44(s0) slliw a5,a5,1 sext.w a5,a5 mv s1,a5 ld a0,-56(s0) call strlen@plt mv a5,a0 bltu s1,a5,.L5 .L4: lw a5,-48(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) ld s1,40(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem12/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -20[rbp], eax mov rax, QWORD PTR -48[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -16[rbp], eax mov eax, DWORD PTR -20[rbp] cmp DWORD PTR -16[rbp], eax cmovle eax, DWORD PTR -16[rbp] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -12[rbp] add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax cmp QWORD PTR -8[rbp], 0 jne .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -24[rbp], 0 jmp .L4 .L7: mov eax, DWORD PTR -24[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -24[rbp] movsx rcx, eax mov rax, QWORD PTR -48[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al jne .L5 mov ecx, 48 jmp .L6 .L5: mov ecx, 49 .L6: mov eax, DWORD PTR -24[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], cl add DWORD PTR -24[rbp], 1 .L4: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -12[rbp] jl .L7 mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rax, QWORD PTR -8[rbp] .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-36(s0) ld a0,-64(s0) call strlen@plt mv a5,a0 sw a5,-32(s0) lw a2,-36(s0) lw a5,-32(s0) sext.w a3,a5 sext.w a4,a2 ble a3,a4,.L2 mv a5,a2 .L2: sw a5,-28(s0) lw a5,-28(s0) addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) bnez a5,.L3 li a5,0 j .L4 .L3: sw zero,-40(s0) j .L5 .L8: lw a5,-40(s0) ld a4,-56(s0) add a5,a4,a5 lbu a3,0(a5) lw a5,-40(s0) ld a4,-64(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a3 bne a4,a5,.L6 li a5,48 j .L7 .L6: li a5,49 .L7: lw a4,-40(s0) ld a3,-24(s0) add a4,a3,a4 sb a5,0(a4) lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L5: lw a4,-40(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 lw a5,-28(s0) ld a4,-24(s0) add a5,a4,a5 sb zero,0(a5) ld a5,-24(s0) .L4: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem155/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov QWORD PTR -48[rbp], rsi mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -16[rbp], eax mov rax, QWORD PTR -48[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -12[rbp] add eax, eax add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -20[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -12[rbp] sub eax, DWORD PTR -20[rbp] movsx rdx, eax mov eax, DWORD PTR -20[rbp] movsx rcx, eax mov rax, QWORD PTR -48[rbp] add rcx, rax mov rax, QWORD PTR -8[rbp] mov rsi, rcx mov rdi, rax call strncpy@PLT mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov eax, DWORD PTR -12[rbp] movsx rcx, eax mov eax, DWORD PTR -20[rbp] cdqe sub rcx, rax mov rax, QWORD PTR -8[rbp] add rcx, rax mov rax, QWORD PTR -48[rbp] mov rsi, rax mov rdi, rcx call strncpy@PLT mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx mov BYTE PTR [rax], 0 mov rdx, QWORD PTR -8[rbp] mov rax, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call strstr@PLT test rax, rax je .L3 mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT mov eax, 1 jmp .L4 .L3: add DWORD PTR -20[rbp], 1 .L2: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -12[rbp] jl .L5 mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT mov eax, 0 .L4: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sd a1,-64(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-32(s0) ld a0,-64(s0) call strlen@plt mv a5,a0 sw a5,-28(s0) lw a5,-28(s0) slliw a5,a5,1 sext.w a5,a5 addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-36(s0) j .L2 .L5: lw a5,-36(s0) ld a4,-64(s0) add a3,a4,a5 lw a4,-28(s0) lw a5,-36(s0) subw a5,a4,a5 sext.w a5,a5 mv a2,a5 mv a1,a3 ld a0,-24(s0) call strncpy@plt lw a4,-28(s0) lw a5,-36(s0) sub a5,a4,a5 ld a4,-24(s0) add a5,a4,a5 lw a4,-36(s0) mv a2,a4 ld a1,-64(s0) mv a0,a5 call strncpy@plt lw a5,-28(s0) ld a4,-24(s0) add a5,a4,a5 sb zero,0(a5) ld a1,-24(s0) ld a0,-56(s0) call strstr@plt mv a5,a0 beqz a5,.L3 ld a0,-24(s0) call free@plt li a5,1 j .L4 .L3: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L2: lw a4,-36(s0) lw a5,-28(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 ld a0,-24(s0) call free@plt li a5,0 .L4: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem67/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 64 jle .L3 mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 90 jg .L3 mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx eax, al add DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L4 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L4: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,64 bleu a4,a5,.L3 lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,90 bgtu a4,a5,.L3 lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L4 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem57/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L7: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 60 jne .L3 add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 62 jne .L4 sub DWORD PTR -8[rbp], 1 .L4: cmp DWORD PTR -8[rbp], 0 jns .L5 mov eax, 0 jmp .L6 .L5: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L7 cmp DWORD PTR -8[rbp], 0 je .L8 mov eax, 0 jmp .L6 .L8: mov eax, 1 .L6: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L7: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,60 bne a4,a5,.L3 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,62 bne a4,a5,.L4 lw a5,-24(s0) addiw a5,a5,-1 sw a5,-24(s0) .L4: lw a5,-24(s0) sext.w a5,a5 bgez a5,.L5 li a5,0 j .L6 .L5: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L7 lw a5,-24(s0) sext.w a5,a5 beqz a5,.L8 li a5,0 j .L6 .L8: li a5,1 .L6: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem101/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov DWORD PTR -20[rbp], edi mov eax, DWORD PTR -20[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -8[rbp] mov edx, DWORD PTR -20[rbp] mov DWORD PTR [rax], edx mov DWORD PTR -12[rbp], 1 jmp .L2 .L3: mov eax, DWORD PTR -12[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -12[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx add edx, 2 mov DWORD PTR [rax], edx add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -20[rbp] jl .L3 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) lw a5,-36(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) lw a4,-36(s0) sw a4,0(a5) li a5,1 sw a5,-28(s0) j .L2 .L3: lw a5,-28(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-24(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 addiw a4,a4,2 sext.w a4,a4 sw a4,0(a5) lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 ld a5,-24(s0) mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem54/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -4[rbp], edi mov DWORD PTR -8[rbp], esi mov edx, DWORD PTR -4[rbp] mov eax, DWORD PTR -8[rbp] add eax, edx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 mv a5,a0 mv a4,a1 sw a5,-20(s0) mv a5,a4 sw a5,-24(s0) lw a4,-20(s0) lw a5,-24(s0) addw a5,a4,a5 sext.w a5,a5 mv a0,a5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem148/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 104 .cfi_offset 3, -24 mov DWORD PTR -100[rbp], edi mov eax, DWORD PTR -100[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -40[rbp], rax mov eax, DWORD PTR -100[rbp] add eax, 1 cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov QWORD PTR -32[rbp], rax mov eax, DWORD PTR -100[rbp] add eax, 1 cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov QWORD PTR -24[rbp], rax mov DWORD PTR -84[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -84[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] lea rbx, [rdx+rax] mov esi, 4 mov edi, 3 call calloc@PLT mov QWORD PTR [rbx], rax mov eax, DWORD PTR -84[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] lea rbx, [rdx+rax] mov esi, 4 mov edi, 3 call calloc@PLT mov QWORD PTR [rbx], rax add DWORD PTR -84[rbp], 1 .L2: mov eax, DWORD PTR -84[rbp] cmp eax, DWORD PTR -100[rbp] jle .L3 mov rax, QWORD PTR -32[rbp] mov rax, QWORD PTR [rax] lea rdx, 8[rax] mov DWORD PTR [rdx], 0 mov rax, QWORD PTR -32[rbp] mov rax, QWORD PTR [rax] add rax, 4 mov edx, DWORD PTR [rdx] mov DWORD PTR [rax], edx mov rdx, QWORD PTR -32[rbp] mov rdx, QWORD PTR [rdx] mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov rax, QWORD PTR -24[rbp] mov rax, QWORD PTR [rax] lea rdx, 8[rax] mov DWORD PTR [rdx], 0 mov rax, QWORD PTR -24[rbp] mov rax, QWORD PTR [rax] add rax, 4 mov edx, DWORD PTR [rdx] mov DWORD PTR [rax], edx mov rdx, QWORD PTR -24[rbp] mov rdx, QWORD PTR [rdx] mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov DWORD PTR -80[rbp], 1 jmp .L4 .L7: mov eax, DWORD PTR -80[rbp] imul eax, eax sub eax, DWORD PTR -80[rbp] lea ecx, 1[rax] mov eax, DWORD PTR -80[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -40[rbp] lea rsi, [rdx+rax] movsx rax, ecx imul rax, rax, 1431655766 shr rax, 32 mov rdx, rax mov eax, ecx sar eax, 31 mov ebx, edx sub ebx, eax mov eax, ebx mov edx, eax add edx, edx add edx, eax mov eax, ecx sub eax, edx mov DWORD PTR [rsi], eax mov DWORD PTR -76[rbp], 0 jmp .L5 .L6: mov eax, DWORD PTR -80[rbp] cdqe sal rax, 3 lea rdx, -8[rax] mov rax, QWORD PTR -32[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -76[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov edx, DWORD PTR -80[rbp] movsx rdx, edx lea rcx, 0[0+rdx*8] mov rdx, QWORD PTR -32[rbp] add rdx, rcx mov rdx, QWORD PTR [rdx] mov ecx, DWORD PTR -76[rbp] movsx rcx, ecx sal rcx, 2 add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax add DWORD PTR -76[rbp], 1 .L5: cmp DWORD PTR -76[rbp], 2 jle .L6 mov eax, DWORD PTR -80[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -80[rbp] movsx rdx, edx sal rdx, 2 lea rcx, -4[rdx] mov rdx, QWORD PTR -40[rbp] add rdx, rcx mov edx, DWORD PTR [rdx] movsx rdx, edx sal rdx, 2 add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -80[rbp] cdqe lea rcx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] add rax, rcx mov rax, QWORD PTR [rax] mov ecx, DWORD PTR -80[rbp] movsx rcx, ecx sal rcx, 2 lea rsi, -4[rcx] mov rcx, QWORD PTR -40[rbp] add rcx, rsi mov ecx, DWORD PTR [rcx] movsx rcx, ecx sal rcx, 2 add rax, rcx add edx, 1 mov DWORD PTR [rax], edx add DWORD PTR -80[rbp], 1 .L4: mov eax, DWORD PTR -80[rbp] cmp eax, DWORD PTR -100[rbp] jle .L7 mov DWORD PTR -72[rbp], 1 jmp .L8 .L20: mov DWORD PTR -68[rbp], 1 jmp .L9 .L15: mov DWORD PTR -64[rbp], 0 jmp .L10 .L11: mov eax, DWORD PTR -68[rbp] cdqe sal rax, 3 lea rdx, -8[rax] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -64[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov edx, DWORD PTR -68[rbp] movsx rdx, edx lea rcx, 0[0+rdx*8] mov rdx, QWORD PTR -24[rbp] add rdx, rcx mov rdx, QWORD PTR [rdx] mov ecx, DWORD PTR -64[rbp] movsx rcx, ecx sal rcx, 2 add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax add DWORD PTR -64[rbp], 1 .L10: cmp DWORD PTR -64[rbp], 2 jle .L11 cmp DWORD PTR -68[rbp], 0 jle .L12 mov DWORD PTR -60[rbp], 0 jmp .L13 .L14: mov eax, DWORD PTR -68[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rsi, QWORD PTR [rax] mov eax, DWORD PTR -68[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -60[rbp] lea ecx, [rdx+rax] movsx rax, ecx imul rax, rax, 1431655766 shr rax, 32 mov rdx, rax mov eax, ecx sar eax, 31 mov ebx, edx sub ebx, eax mov eax, ebx mov edx, eax add edx, edx add edx, eax mov eax, ecx sub eax, edx movsx rdx, eax sal rdx, 2 add rdx, rsi mov ecx, DWORD PTR [rdx] mov edx, DWORD PTR -68[rbp] movsx rdx, edx sal rdx, 3 lea rsi, -8[rdx] mov rdx, QWORD PTR -32[rbp] add rdx, rsi mov rdx, QWORD PTR [rdx] mov esi, DWORD PTR -60[rbp] movsx rsi, esi sal rsi, 2 add rdx, rsi mov edx, DWORD PTR [rdx] mov esi, DWORD PTR -68[rbp] movsx rsi, esi lea rdi, 0[0+rsi*8] mov rsi, QWORD PTR -24[rbp] add rsi, rdi mov rsi, QWORD PTR [rsi] cdqe sal rax, 2 add rax, rsi add edx, ecx mov DWORD PTR [rax], edx add DWORD PTR -60[rbp], 1 .L13: cmp DWORD PTR -60[rbp], 2 jle .L14 .L12: add DWORD PTR -68[rbp], 1 .L9: mov eax, DWORD PTR -68[rbp] cmp eax, DWORD PTR -100[rbp] jle .L15 mov DWORD PTR -56[rbp], 0 jmp .L16 .L19: mov DWORD PTR -52[rbp], 0 jmp .L17 .L18: mov eax, DWORD PTR -56[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -52[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov edx, DWORD PTR -56[rbp] movsx rdx, edx lea rcx, 0[0+rdx*8] mov rdx, QWORD PTR -32[rbp] add rdx, rcx mov rdx, QWORD PTR [rdx] mov ecx, DWORD PTR -52[rbp] movsx rcx, ecx sal rcx, 2 add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -56[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov edx, DWORD PTR -52[rbp] movsx rdx, edx sal rdx, 2 add rax, rdx mov DWORD PTR [rax], 0 add DWORD PTR -52[rbp], 1 .L17: cmp DWORD PTR -52[rbp], 2 jle .L18 add DWORD PTR -56[rbp], 1 .L16: mov eax, DWORD PTR -56[rbp] cmp eax, DWORD PTR -100[rbp] jle .L19 add DWORD PTR -72[rbp], 1 .L8: cmp DWORD PTR -72[rbp], 2 jle .L20 mov eax, DWORD PTR -100[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov eax, DWORD PTR [rax] mov DWORD PTR -44[rbp], eax mov DWORD PTR -48[rbp], 0 jmp .L21 .L22: mov eax, DWORD PTR -48[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -32[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call free@PLT mov eax, DWORD PTR -48[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call free@PLT add DWORD PTR -48[rbp], 1 .L21: mov eax, DWORD PTR -48[rbp] cmp eax, DWORD PTR -100[rbp] jle .L22 mov rax, QWORD PTR -32[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -24[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -40[rbp] mov rdi, rax call free@PLT mov eax, DWORD PTR -44[rbp] add rsp, 104 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-128 sd ra,120(sp) sd s0,112(sp) sd s1,104(sp) addi s0,sp,128 mv a5,a0 sw a5,-116(s0) lw a5,-116(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-56(s0) lw a5,-116(s0) addiw a5,a5,1 sext.w a5,a5 slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-48(s0) lw a5,-116(s0) addiw a5,a5,1 sext.w a5,a5 slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-40(s0) sw zero,-100(s0) j .L2 .L3: lw a5,-100(s0) slli a5,a5,3 ld a4,-48(s0) add s1,a4,a5 li a1,4 li a0,3 call calloc@plt mv a5,a0 sd a5,0(s1) lw a5,-100(s0) slli a5,a5,3 ld a4,-40(s0) add s1,a4,a5 li a1,4 li a0,3 call calloc@plt mv a5,a0 sd a5,0(s1) lw a5,-100(s0) addiw a5,a5,1 sw a5,-100(s0) .L2: lw a4,-100(s0) lw a5,-116(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L3 ld a5,-48(s0) ld a5,0(a5) addi a4,a5,8 sw zero,0(a4) ld a5,-48(s0) ld a5,0(a5) addi a5,a5,4 lw a4,0(a4) sw a4,0(a5) ld a4,-48(s0) ld a4,0(a4) lw a5,0(a5) sw a5,0(a4) ld a5,-40(s0) ld a5,0(a5) addi a4,a5,8 sw zero,0(a4) ld a5,-40(s0) ld a5,0(a5) addi a5,a5,4 lw a4,0(a4) sw a4,0(a5) ld a4,-40(s0) ld a4,0(a4) lw a5,0(a5) sw a5,0(a4) li a5,1 sw a5,-96(s0) j .L4 .L7: lw a5,-96(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-96(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,1 sext.w a3,a5 lw a5,-96(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-56(s0) add a5,a4,a5 li a4,3 remw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) sw zero,-92(s0) j .L5 .L6: lw a5,-96(s0) slli a5,a5,3 addi a5,a5,-8 ld a4,-48(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-92(s0) slli a5,a5,2 add a4,a4,a5 lw a5,-96(s0) slli a5,a5,3 ld a3,-48(s0) add a5,a3,a5 ld a3,0(a5) lw a5,-92(s0) slli a5,a5,2 add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-92(s0) addiw a5,a5,1 sw a5,-92(s0) .L5: lw a5,-92(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L6 lw a5,-96(s0) slli a5,a5,3 ld a4,-48(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-96(s0) slli a5,a5,2 addi a5,a5,-4 ld a3,-56(s0) add a5,a3,a5 lw a5,0(a5) slli a5,a5,2 add a5,a4,a5 lw a4,0(a5) lw a5,-96(s0) slli a5,a5,3 ld a3,-48(s0) add a5,a3,a5 ld a3,0(a5) lw a5,-96(s0) slli a5,a5,2 addi a5,a5,-4 ld a2,-56(s0) add a5,a2,a5 lw a5,0(a5) slli a5,a5,2 add a5,a3,a5 addiw a4,a4,1 sext.w a4,a4 sw a4,0(a5) lw a5,-96(s0) addiw a5,a5,1 sw a5,-96(s0) .L4: lw a4,-96(s0) lw a5,-116(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L7 li a5,1 sw a5,-88(s0) j .L8 .L20: li a5,1 sw a5,-84(s0) j .L9 .L15: sw zero,-80(s0) j .L10 .L11: lw a5,-84(s0) slli a5,a5,3 addi a5,a5,-8 ld a4,-40(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-80(s0) slli a5,a5,2 add a4,a4,a5 lw a5,-84(s0) slli a5,a5,3 ld a3,-40(s0) add a5,a3,a5 ld a3,0(a5) lw a5,-80(s0) slli a5,a5,2 add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-80(s0) addiw a5,a5,1 sw a5,-80(s0) .L10: lw a5,-80(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L11 lw a5,-84(s0) sext.w a5,a5 blez a5,.L12 sw zero,-76(s0) j .L13 .L14: lw a5,-84(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-84(s0) slli a5,a5,2 addi a5,a5,-4 ld a3,-56(s0) add a5,a3,a5 lw a5,0(a5) lw a3,-76(s0) addw a5,a3,a5 sext.w a5,a5 mv a3,a5 li a5,3 remw a5,a3,a5 sext.w a1,a5 mv a5,a1 slli a5,a5,2 add a5,a4,a5 lw a3,0(a5) lw a5,-84(s0) slli a5,a5,3 addi a5,a5,-8 ld a4,-48(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-76(s0) slli a5,a5,2 add a5,a4,a5 lw a4,0(a5) lw a5,-84(s0) slli a5,a5,3 ld a2,-40(s0) add a5,a2,a5 ld a2,0(a5) mv a5,a1 slli a5,a5,2 add a5,a2,a5 addw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) lw a5,-76(s0) addiw a5,a5,1 sw a5,-76(s0) .L13: lw a5,-76(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L14 .L12: lw a5,-84(s0) addiw a5,a5,1 sw a5,-84(s0) .L9: lw a4,-84(s0) lw a5,-116(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L15 sw zero,-72(s0) j .L16 .L19: sw zero,-68(s0) j .L17 .L18: lw a5,-72(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-68(s0) slli a5,a5,2 add a4,a4,a5 lw a5,-72(s0) slli a5,a5,3 ld a3,-48(s0) add a5,a3,a5 ld a3,0(a5) lw a5,-68(s0) slli a5,a5,2 add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-72(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a4,0(a5) lw a5,-68(s0) slli a5,a5,2 add a5,a4,a5 sw zero,0(a5) lw a5,-68(s0) addiw a5,a5,1 sw a5,-68(s0) .L17: lw a5,-68(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L18 lw a5,-72(s0) addiw a5,a5,1 sw a5,-72(s0) .L16: lw a4,-72(s0) lw a5,-116(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L19 lw a5,-88(s0) addiw a5,a5,1 sw a5,-88(s0) .L8: lw a5,-88(s0) sext.w a4,a5 li a5,2 ble a4,a5,.L20 lw a5,-116(s0) slli a5,a5,3 ld a4,-48(s0) add a5,a4,a5 ld a5,0(a5) lw a5,0(a5) sw a5,-60(s0) sw zero,-64(s0) j .L21 .L22: lw a5,-64(s0) slli a5,a5,3 ld a4,-48(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call free@plt lw a5,-64(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call free@plt lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L21: lw a4,-64(s0) lw a5,-116(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L22 ld a0,-48(s0) call free@plt ld a0,-40(s0) call free@plt ld a0,-56(s0) call free@plt lw a5,-60(s0) mv a0,a5 ld ra,120(sp) ld s0,112(sp) ld s1,104(sp) addi sp,sp,128 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem137/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov DWORD PTR -12[rbp], 0 mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L7: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] test eax, eax jns .L3 cmp DWORD PTR -12[rbp], 0 je .L4 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jge .L3 .L4: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax .L3: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] test eax, eax jle .L5 cmp DWORD PTR -8[rbp], 0 je .L6 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -8[rbp], eax jle .L5 .L6: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -8[rbp], eax .L5: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 mov rax, QWORD PTR -40[rbp] mov edx, DWORD PTR -12[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -40[rbp] lea rdx, 4[rax] mov eax, DWORD PTR -8[rbp] mov DWORD PTR [rdx], eax nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) sw a5,-44(s0) sw zero,-28(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L7: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) bgez a5,.L3 lw a5,-28(s0) sext.w a5,a5 beqz a5,.L4 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 bge a5,a4,.L3 .L4: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) .L3: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) blez a5,.L5 lw a5,-24(s0) sext.w a5,a5 beqz a5,.L6 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-24(s0) sext.w a5,a5 ble a5,a4,.L5 .L6: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-24(s0) .L5: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 ld a5,-56(s0) lw a4,-28(s0) sw a4,0(a5) ld a5,-56(s0) addi a5,a5,4 lw a4,-24(s0) sw a4,0(a5) nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem59/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov QWORD PTR -56[rbp], rdx mov DWORD PTR -48[rbp], ecx mov QWORD PTR -64[rbp], r8 mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -32[rbp], 0 mov DWORD PTR -28[rbp], 0 jmp .L2 .L11: mov DWORD PTR -16[rbp], 0 mov DWORD PTR -20[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L4 mov DWORD PTR -16[rbp], 1 jmp .L5 .L4: add DWORD PTR -20[rbp], 1 .L3: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -32[rbp] jl .L6 .L5: cmp DWORD PTR -16[rbp], 0 jne .L7 mov DWORD PTR -24[rbp], 0 jmp .L8 .L10: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L9 mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -32[rbp] lea edx, 1[rax] mov DWORD PTR -32[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax jmp .L7 .L9: add DWORD PTR -24[rbp], 1 .L8: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -48[rbp] jl .L10 .L7: add DWORD PTR -28[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] cmp eax, DWORD PTR -44[rbp] jl .L11 mov DWORD PTR -28[rbp], 0 jmp .L12 .L16: mov DWORD PTR -24[rbp], 0 jmp .L13 .L15: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L14 mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -24[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -24[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -12[rbp] mov DWORD PTR [rdx], eax .L14: add DWORD PTR -24[rbp], 1 .L13: mov eax, DWORD PTR -32[rbp] sub eax, DWORD PTR -28[rbp] sub eax, 1 cmp DWORD PTR -24[rbp], eax jl .L15 add DWORD PTR -28[rbp], 1 .L12: mov eax, DWORD PTR -32[rbp] sub eax, 1 cmp DWORD PTR -28[rbp], eax jl .L16 mov rax, QWORD PTR -64[rbp] mov edx, DWORD PTR -32[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 sd a2,-72(s0) sd a4,-80(s0) sw a5,-60(s0) mv a5,a3 sw a5,-64(s0) lw a5,-60(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-48(s0) sw zero,-44(s0) j .L2 .L11: sw zero,-32(s0) sw zero,-36(s0) j .L3 .L6: lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L4 li a5,1 sw a5,-32(s0) j .L5 .L4: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: lw a4,-36(s0) lw a5,-48(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 .L5: lw a5,-32(s0) sext.w a5,a5 bnez a5,.L7 sw zero,-40(s0) j .L8 .L10: lw a5,-44(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) slli a5,a5,2 ld a4,-72(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L9 lw a5,-44(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-48(s0) addiw a3,a5,1 sw a3,-48(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) j .L7 .L9: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L8: lw a4,-40(s0) lw a5,-64(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L10 .L7: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L2: lw a4,-44(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L11 sw zero,-44(s0) j .L12 .L16: sw zero,-40(s0) j .L13 .L15: lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L14 lw a5,-40(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-40(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-40(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-28(s0) sw a4,0(a5) .L14: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L13: lw a4,-48(s0) lw a5,-44(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 lw a5,-40(s0) sext.w a5,a5 blt a5,a4,.L15 lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L12: lw a5,-48(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-44(s0) sext.w a5,a5 blt a5,a4,.L16 ld a5,-80(s0) lw a4,-48(s0) sw a4,0(a5) ld a5,-24(s0) mv a0,a5 ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem132/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov DWORD PTR -12[rbp], 1 mov DWORD PTR -8[rbp], 0 jmp .L2 .L4: mov edx, DWORD PTR -20[rbp] movsx rax, edx imul rax, rax, 1717986919 shr rax, 32 mov ecx, eax sar ecx, 2 mov eax, edx sar eax, 31 sub ecx, eax mov eax, ecx sal eax, 2 add eax, ecx add eax, eax sub edx, eax mov eax, edx mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -4[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L3 mov DWORD PTR -8[rbp], 1 mov eax, DWORD PTR -12[rbp] imul eax, DWORD PTR -4[rbp] mov DWORD PTR -12[rbp], eax .L3: mov eax, DWORD PTR -20[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -20[rbp], eax .L2: cmp DWORD PTR -20[rbp], 0 jg .L4 cmp DWORD PTR -8[rbp], 0 je .L5 mov eax, DWORD PTR -12[rbp] jmp .L7 .L5: mov eax, 0 .L7: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) li a5,1 sw a5,-28(s0) sw zero,-24(s0) j .L2 .L4: lw a4,-36(s0) li a5,10 remw a5,a4,a5 sw a5,-20(s0) lw a4,-20(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L3 li a5,1 sw a5,-24(s0) lw a4,-28(s0) lw a5,-20(s0) mulw a5,a4,a5 sw a5,-28(s0) .L3: lw a4,-36(s0) li a5,10 divw a5,a4,a5 sw a5,-36(s0) .L2: lw a5,-36(s0) sext.w a5,a5 bgtz a5,.L4 lw a5,-24(s0) sext.w a5,a5 beqz a5,.L5 lw a5,-28(s0) j .L6 .L5: li a5,0 .L6: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem46/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 movss DWORD PTR -4[rbp], xmm0 movss DWORD PTR -8[rbp], xmm1 movss xmm0, DWORD PTR -4[rbp] movaps xmm1, xmm0 mulss xmm1, DWORD PTR -8[rbp] movss xmm0, DWORD PTR .LC0[rip] mulss xmm0, xmm1 pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .section .rodata .align 4 .LC0: .long 1056964608 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 fsw fa0,-20(s0) fsw fa1,-24(s0) flw fa4,-20(s0) flw fa5,-24(s0) fmul.s fa4,fa4,fa5 lla a5,.LC0 flw fa5,0(a5) fmul.s fa5,fa4,fa5 fmv.s fa0,fa5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .section .rodata .align 2 .LC0: .word 1056964608 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem117/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov DWORD PTR -12[rbp], 0 jmp .L2 .L11: mov eax, DWORD PTR -12[rbp] add eax, 1 mov DWORD PTR -8[rbp], eax jmp .L3 .L10: mov DWORD PTR -24[rbp], 0 mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -20[rbp], eax mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -16[rbp], eax jmp .L4 .L5: mov eax, DWORD PTR -20[rbp] and eax, 1 add DWORD PTR -24[rbp], eax sar DWORD PTR -20[rbp] .L4: cmp DWORD PTR -20[rbp], 0 jg .L5 mov eax, DWORD PTR -24[rbp] mov DWORD PTR -20[rbp], eax mov DWORD PTR -24[rbp], 0 jmp .L6 .L7: mov eax, DWORD PTR -16[rbp] and eax, 1 add DWORD PTR -24[rbp], eax sar DWORD PTR -16[rbp] .L6: cmp DWORD PTR -16[rbp], 0 jg .L7 mov eax, DWORD PTR -24[rbp] mov DWORD PTR -16[rbp], eax mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -20[rbp] jl .L8 mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -20[rbp] jne .L9 mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -12[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jge .L9 .L8: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR -12[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -40[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rdx, rax mov eax, DWORD PTR -4[rbp] mov DWORD PTR [rdx], eax .L9: add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -44[rbp] jl .L10 add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -44[rbp] jl .L11 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) sw zero,-28(s0) j .L2 .L11: lw a5,-28(s0) addiw a5,a5,1 sw a5,-24(s0) j .L3 .L10: sw zero,-40(s0) lw a5,-28(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-36(s0) lw a5,-24(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-32(s0) j .L4 .L5: lw a5,-36(s0) andi a5,a5,1 sext.w a5,a5 lw a4,-40(s0) addw a5,a4,a5 sw a5,-40(s0) lw a5,-36(s0) sraiw a5,a5,1 sw a5,-36(s0) .L4: lw a5,-36(s0) sext.w a5,a5 bgtz a5,.L5 lw a5,-40(s0) sw a5,-36(s0) sw zero,-40(s0) j .L6 .L7: lw a5,-32(s0) andi a5,a5,1 sext.w a5,a5 lw a4,-40(s0) addw a5,a4,a5 sw a5,-40(s0) lw a5,-32(s0) sraiw a5,a5,1 sw a5,-32(s0) .L6: lw a5,-32(s0) sext.w a5,a5 bgtz a5,.L7 lw a5,-40(s0) sw a5,-32(s0) lw a4,-32(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 lw a4,-32(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L9 lw a5,-24(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-28(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bge a4,a5,.L9 .L8: lw a5,-28(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-20(s0) lw a5,-24(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-28(s0) slli a5,a5,2 ld a3,-56(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-24(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a4,-20(s0) sw a4,0(a5) .L9: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a4,-24(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L10 lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L11 nop nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem69/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov DWORD PTR -12[rbp], 2147483647 mov DWORD PTR -8[rbp], -1 mov DWORD PTR -4[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] and eax, 1 test eax, eax jne .L3 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jg .L4 cmp DWORD PTR -8[rbp], -1 jne .L3 .L4: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -4[rbp] mov DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L5 cmp DWORD PTR -8[rbp], -1 jne .L6 mov eax, 0 jmp .L7 .L6: mov rax, QWORD PTR -40[rbp] mov edx, DWORD PTR -12[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -40[rbp] lea rdx, 4[rax] mov eax, DWORD PTR -8[rbp] mov DWORD PTR [rdx], eax mov rax, QWORD PTR -40[rbp] .L7: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) sw a5,-44(s0) li a5,-2147483648 xori a5,a5,-1 sw a5,-28(s0) li a5,-1 sw a5,-24(s0) sw zero,-20(s0) j .L2 .L5: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sext.w a5,a5 andi a5,a5,1 sext.w a5,a5 bnez a5,.L3 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 bgt a5,a4,.L4 lw a5,-24(s0) sext.w a4,a5 li a5,-1 bne a4,a5,.L3 .L4: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) lw a5,-20(s0) sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 lw a5,-24(s0) sext.w a4,a5 li a5,-1 bne a4,a5,.L6 li a5,0 j .L7 .L6: ld a5,-56(s0) lw a4,-28(s0) sw a4,0(a5) ld a5,-56(s0) addi a5,a5,4 lw a4,-24(s0) sw a4,0(a5) ld a5,-56(s0) .L7: mv a0,a5 ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem96/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi cmp DWORD PTR -44[rbp], 0 jne .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -24[rbp], 0 mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L4 .L11: mov eax, DWORD PTR -16[rbp] cdqe sal rax, 4 mov rdx, rax mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov QWORD PTR -8[rbp], rax mov DWORD PTR -12[rbp], 0 jmp .L5 .L10: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -8[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 1024 test eax, eax jne .L6 mov eax, 0 jmp .L3 .L6: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -8[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 256 test eax, eax je .L7 mov DWORD PTR -20[rbp], 1 .L7: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -8[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 512 test eax, eax je .L8 mov DWORD PTR -24[rbp], 1 .L8: mov edx, DWORD PTR -20[rbp] mov eax, DWORD PTR -24[rbp] add eax, edx cmp eax, 2 jne .L9 mov eax, 0 jmp .L3 .L9: add DWORD PTR -12[rbp], 1 .L5: mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L10 add DWORD PTR -16[rbp], 1 .L4: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -44[rbp] jl .L11 mov eax, 1 .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) lw a5,-60(s0) sext.w a5,a5 bnez a5,.L2 li a5,0 j .L3 .L2: sw zero,-40(s0) sw zero,-36(s0) sw zero,-32(s0) j .L4 .L11: lw a5,-32(s0) slli a5,a5,4 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) sd a5,-24(s0) sw zero,-28(s0) j .L5 .L10: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-24(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,1024 sext.w a5,a5 bnez a5,.L6 li a5,0 j .L3 .L6: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-24(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,256 sext.w a5,a5 beqz a5,.L7 li a5,1 sw a5,-36(s0) .L7: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-24(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,512 sext.w a5,a5 beqz a5,.L8 li a5,1 sw a5,-40(s0) .L8: lw a4,-36(s0) lw a5,-40(s0) addw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,2 bne a4,a5,.L9 li a5,0 j .L3 .L9: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L5: lw a5,-28(s0) ld a4,-24(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L10 lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L4: lw a4,-32(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L11 li a5,1 .L3: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem49/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi mov rax, QWORD PTR -24[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax mov DWORD PTR -8[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -4[rbp] sub eax, 1 sub eax, DWORD PTR -8[rbp] movsx rcx, eax mov rax, QWORD PTR -24[rbp] add rax, rcx movzx eax, BYTE PTR [rax] cmp dl, al je .L3 mov eax, 0 jmp .L4 .L3: add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -8[rbp], eax jl .L5 mov eax, 1 .L4: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) ld a0,-40(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) sw zero,-24(s0) j .L2 .L5: lw a5,-24(s0) ld a4,-40(s0) add a5,a4,a5 lbu a3,0(a5) lw a5,-20(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-24(s0) subw a5,a4,a5 sext.w a5,a5 mv a4,a5 ld a5,-40(s0) add a5,a5,a4 lbu a5,0(a5) mv a4,a3 beq a4,a5,.L3 li a5,0 j .L4 .L3: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a5,-20(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-24(s0) sext.w a5,a5 blt a5,a4,.L5 li a5,1 .L4: mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem38/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov QWORD PTR -56[rbp], rdx mov eax, DWORD PTR -44[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax add eax, 1 cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -16[rbp], 0 mov DWORD PTR -24[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -16[rbp] lea edx, 1[rax] mov DWORD PTR -16[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm0, DWORD PTR [rcx] movss DWORD PTR [rax], xmm0 add DWORD PTR -24[rbp], 2 .L2: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -44[rbp] jl .L3 mov DWORD PTR -24[rbp], 0 jmp .L4 .L9: mov DWORD PTR -20[rbp], 0 jmp .L5 .L8: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] mov eax, DWORD PTR -20[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm1, DWORD PTR [rax] comiss xmm0, xmm1 jbe .L6 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] movss DWORD PTR -12[rbp], xmm0 mov eax, DWORD PTR -20[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -20[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx movss xmm0, DWORD PTR [rdx] movss DWORD PTR [rax], xmm0 mov eax, DWORD PTR -20[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx movss xmm0, DWORD PTR -12[rbp] movss DWORD PTR [rax], xmm0 .L6: add DWORD PTR -20[rbp], 1 .L5: mov eax, DWORD PTR -16[rbp] sub eax, DWORD PTR -24[rbp] sub eax, 1 cmp DWORD PTR -20[rbp], eax jl .L8 add DWORD PTR -24[rbp], 1 .L4: mov eax, DWORD PTR -16[rbp] sub eax, 1 cmp DWORD PTR -24[rbp], eax jl .L9 mov DWORD PTR -24[rbp], 0 jmp .L10 .L13: mov eax, DWORD PTR -24[rbp] and eax, 1 test eax, eax jne .L11 mov eax, DWORD PTR -24[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -24[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rax, rcx movss xmm0, DWORD PTR [rdx] movss DWORD PTR [rax], xmm0 jmp .L12 .L11: mov eax, DWORD PTR -24[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rdx, rax mov eax, DWORD PTR -24[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -56[rbp] add rax, rcx movss xmm0, DWORD PTR [rdx] movss DWORD PTR [rax], xmm0 .L12: add DWORD PTR -24[rbp], 1 .L10: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -44[rbp] jl .L13 mov rax, QWORD PTR -8[rbp] mov rdi, rax call free@PLT nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 sd a2,-72(s0) sw a5,-60(s0) lw a5,-60(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a5,a5 addiw a5,a5,1 sext.w a5,a5 slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-32(s0) sw zero,-40(s0) j .L2 .L3: lw a5,-40(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-32(s0) addiw a3,a5,1 sw a3,-32(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 flw fa5,0(a4) fsw fa5,0(a5) lw a5,-40(s0) addiw a5,a5,2 sw a5,-40(s0) .L2: lw a4,-40(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 sw zero,-40(s0) j .L4 .L9: sw zero,-36(s0) j .L5 .L8: lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 flw fa4,0(a5) lw a5,-36(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 flw fa5,0(a5) fgt.s a5,fa4,fa5 beqz a5,.L6 lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 flw fa5,0(a5) fsw fa5,-28(s0) lw a5,-36(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-36(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 flw fa5,0(a4) fsw fa5,0(a5) lw a5,-36(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 flw fa5,-28(s0) fsw fa5,0(a5) .L6: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L5: lw a4,-32(s0) lw a5,-40(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 blt a5,a4,.L8 lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L4: lw a5,-32(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-40(s0) sext.w a5,a5 blt a5,a4,.L9 sw zero,-40(s0) j .L10 .L13: lw a5,-40(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L11 lw a5,-40(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a5,a5 slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-40(s0) slli a5,a5,2 ld a3,-72(s0) add a5,a3,a5 flw fa5,0(a4) fsw fa5,0(a5) j .L12 .L11: lw a5,-40(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-40(s0) slli a5,a5,2 ld a3,-72(s0) add a5,a3,a5 flw fa5,0(a4) fsw fa5,0(a5) .L12: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L10: lw a4,-40(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L13 ld a0,-24(s0) call free@plt nop ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem76/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi cmp DWORD PTR -20[rbp], 1 jg .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 2 jmp .L4 .L6: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -4[rbp] mov DWORD PTR -20[rbp], eax add DWORD PTR -8[rbp], 1 .L5: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -4[rbp] mov eax, edx test eax, eax je .L6 add DWORD PTR -4[rbp], 1 .L4: mov eax, DWORD PTR -4[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L5 cmp DWORD PTR -20[rbp], 1 jle .L8 add DWORD PTR -8[rbp], 1 .L8: cmp DWORD PTR -8[rbp], 3 sete al movzx eax, al .L3: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) lw a5,-36(s0) sext.w a4,a5 li a5,1 bgt a4,a5,.L2 li a5,0 j .L3 .L2: sw zero,-24(s0) li a5,2 sw a5,-20(s0) j .L4 .L6: lw a4,-36(s0) lw a5,-20(s0) divw a5,a4,a5 sw a5,-36(s0) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L5: lw a4,-36(s0) lw a5,-20(s0) remw a5,a4,a5 sext.w a5,a5 beqz a5,.L6 lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L4: lw a5,-20(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L5 lw a5,-36(s0) sext.w a4,a5 li a5,1 ble a4,a5,.L8 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L8: lw a5,-24(s0) sext.w a4,a5 li a5,3 sub a5,a4,a5 seqz a5,a5 andi a5,a5,0xff sext.w a5,a5 .L3: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem66/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "%d" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 96 mov DWORD PTR -84[rbp], edi mov DWORD PTR -88[rbp], esi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov eax, DWORD PTR -84[rbp] mov edx, eax lea rsi, .LC0[rip] lea rdi, xs.3014[rip] mov eax, 0 call sprintf@PLT lea rdi, xs.3014[rip] call strlen@PLT mov DWORD PTR -68[rbp], eax mov eax, DWORD PTR -68[rbp] cmp eax, DWORD PTR -88[rbp] jge .L2 mov DWORD PTR -72[rbp], 0 jmp .L3 .L4: mov eax, DWORD PTR -72[rbp] cdqe lea rdx, xs.3014[rip] movzx eax, BYTE PTR [rax+rdx] mov BYTE PTR -73[rbp], al mov eax, DWORD PTR -68[rbp] sub eax, 1 sub eax, DWORD PTR -72[rbp] cdqe lea rdx, xs.3014[rip] movzx edx, BYTE PTR [rax+rdx] mov eax, DWORD PTR -72[rbp] cdqe lea rcx, xs.3014[rip] mov BYTE PTR [rax+rcx], dl mov eax, DWORD PTR -68[rbp] sub eax, 1 sub eax, DWORD PTR -72[rbp] cdqe lea rcx, xs.3014[rip] movzx edx, BYTE PTR -73[rbp] mov BYTE PTR [rax+rcx], dl add DWORD PTR -72[rbp], 1 .L3: mov eax, DWORD PTR -68[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -72[rbp], eax jl .L4 jmp .L5 .L2: mov eax, DWORD PTR -68[rbp] movsx rdx, eax mov eax, DWORD PTR -88[rbp] cdqe sub rdx, rax lea rax, xs.3014[rip] add rdx, rax lea rax, -64[rbp] mov rsi, rdx mov rdi, rax call strcpy@PLT mov eax, DWORD PTR -88[rbp] cdqe mov BYTE PTR -64[rbp+rax], 0 mov eax, DWORD PTR -68[rbp] sub eax, DWORD PTR -88[rbp] movsx rdx, eax lea rax, -64[rbp] lea rsi, xs.3014[rip] mov rdi, rax call strncat@PLT lea rax, -64[rbp] mov rsi, rax lea rdi, xs.3014[rip] call strcpy@PLT .L5: lea rax, xs.3014[rip] mov rcx, QWORD PTR -8[rbp] xor rcx, QWORD PTR fs:40 je .L7 call __stack_chk_fail@PLT .L7: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .local xs.3014 .comm xs.3014,50,32 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "%d" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-112 sd ra,104(sp) sd s0,96(sp) addi s0,sp,112 mv a5,a0 mv a4,a1 sw a5,-100(s0) mv a5,a4 sw a5,-104(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) lw a5,-100(s0) mv a2,a5 lla a1,.LC0 lla a0,xs.2600 call sprintf@plt lla a0,xs.2600 call strlen@plt mv a5,a0 sw a5,-84(s0) lw a4,-84(s0) lw a5,-104(s0) sext.w a4,a4 sext.w a5,a5 bge a4,a5,.L2 sw zero,-88(s0) j .L3 .L4: lla a4,xs.2600 lw a5,-88(s0) add a5,a4,a5 lbu a5,0(a5) sb a5,-89(s0) lw a5,-84(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-88(s0) subw a5,a4,a5 sext.w a5,a5 lla a4,xs.2600 add a5,a4,a5 lbu a4,0(a5) lla a3,xs.2600 lw a5,-88(s0) add a5,a3,a5 sb a4,0(a5) lw a5,-84(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-88(s0) subw a5,a4,a5 sext.w a5,a5 lla a4,xs.2600 add a5,a4,a5 lbu a4,-89(s0) sb a4,0(a5) lw a5,-88(s0) addiw a5,a5,1 sw a5,-88(s0) .L3: lw a5,-84(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-88(s0) sext.w a5,a5 blt a5,a4,.L4 j .L5 .L2: lw a4,-84(s0) lw a5,-104(s0) sub a4,a4,a5 lla a5,xs.2600 add a4,a4,a5 addi a5,s0,-80 mv a1,a4 mv a0,a5 call strcpy@plt lw a5,-104(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-64(a5) lw a4,-84(s0) lw a5,-104(s0) subw a5,a4,a5 sext.w a5,a5 mv a4,a5 addi a5,s0,-80 mv a2,a4 lla a1,xs.2600 mv a0,a5 call strncat@plt addi a5,s0,-80 mv a1,a5 lla a0,xs.2600 call strcpy@plt .L5: lla a5,xs.2600 mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L7 call __stack_chk_fail@plt .L7: mv a0,a3 ld ra,104(sp) ld s0,96(sp) addi sp,sp,112 jr ra .size func0, .-func0 .local xs.2600 .comm xs.2600,50,8 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem147/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L2 .L6: mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp eax, 10 jle .L3 mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] movsx rax, edx imul rax, rax, 1717986919 shr rax, 32 mov ecx, eax sar ecx, 2 mov eax, edx sar eax, 31 sub ecx, eax mov eax, ecx mov DWORD PTR -8[rbp], eax mov ecx, DWORD PTR -8[rbp] mov eax, ecx sal eax, 2 add eax, ecx add eax, eax sub edx, eax mov eax, edx mov DWORD PTR -8[rbp], eax mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax jmp .L4 .L5: mov eax, DWORD PTR -12[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -12[rbp], eax .L4: cmp DWORD PTR -12[rbp], 9 jg .L5 mov eax, DWORD PTR -12[rbp] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -4[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L3 mov eax, DWORD PTR -8[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L3 add DWORD PTR -20[rbp], 1 .L3: add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -44[rbp] jl .L6 mov eax, DWORD PTR -20[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) sw zero,-36(s0) sw zero,-32(s0) j .L2 .L6: lw a5,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,10 ble a4,a5,.L3 lw a5,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 li a5,10 remw a5,a4,a5 sw a5,-24(s0) lw a5,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) j .L4 .L5: lw a4,-28(s0) li a5,10 divw a5,a4,a5 sw a5,-28(s0) .L4: lw a5,-28(s0) sext.w a4,a5 li a5,9 bgt a4,a5,.L5 lw a5,-28(s0) sw a5,-20(s0) lw a4,-20(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L3 lw a4,-24(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L3 lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a4,-32(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a5,-36(s0) mv a0,a5 ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem79/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "2357BD" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 40 .cfi_offset 3, -24 mov QWORD PTR -40[rbp], rdi lea rax, .LC0[rip] mov QWORD PTR -24[rbp], rax mov DWORD PTR -32[rbp], 0 mov DWORD PTR -28[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -28[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx edx, al mov rax, QWORD PTR -24[rbp] mov esi, edx mov rdi, rax call strchr@PLT test rax, rax je .L3 add DWORD PTR -32[rbp], 1 .L3: add DWORD PTR -28[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] movsx rbx, eax mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT cmp rbx, rax jb .L4 mov eax, DWORD PTR -32[rbp] add rsp, 40 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "2357BD" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) sd s1,40(sp) addi s0,sp,64 sd a0,-56(s0) lla a5,.LC0 sd a5,-40(s0) sw zero,-48(s0) sw zero,-44(s0) j .L2 .L4: lw a5,-44(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a1,a5 ld a0,-40(s0) call strchr@plt mv a5,a0 beqz a5,.L3 lw a5,-48(s0) addiw a5,a5,1 sw a5,-48(s0) .L3: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L2: lw s1,-44(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 bltu s1,a5,.L4 lw a5,-48(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) ld s1,40(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem149/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "Mercury" .LC1: .string "Venus" .LC2: .string "Earth" .LC3: .string "Mars" .LC4: .string "Jupiter" .LC5: .string "Saturn" .LC6: .string "Uranus" .LC7: .string "Neptune" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 144 mov QWORD PTR -120[rbp], rdi mov QWORD PTR -128[rbp], rsi mov QWORD PTR -136[rbp], rdx mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax lea rax, .LC0[rip] mov QWORD PTR -80[rbp], rax lea rax, .LC1[rip] mov QWORD PTR -72[rbp], rax lea rax, .LC2[rip] mov QWORD PTR -64[rbp], rax lea rax, .LC3[rip] mov QWORD PTR -56[rbp], rax lea rax, .LC4[rip] mov QWORD PTR -48[rbp], rax lea rax, .LC5[rip] mov QWORD PTR -40[rbp], rax lea rax, .LC6[rip] mov QWORD PTR -32[rbp], rax lea rax, .LC7[rip] mov QWORD PTR -24[rbp], rax mov DWORD PTR -104[rbp], -1 mov DWORD PTR -100[rbp], -1 mov DWORD PTR -96[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -96[rbp] cdqe mov rax, QWORD PTR -80[rbp+rax*8] mov rdx, QWORD PTR -120[rbp] mov rsi, rdx mov rdi, rax call strcmp@PLT test eax, eax jne .L3 mov eax, DWORD PTR -96[rbp] mov DWORD PTR -104[rbp], eax .L3: mov eax, DWORD PTR -96[rbp] cdqe mov rax, QWORD PTR -80[rbp+rax*8] mov rdx, QWORD PTR -128[rbp] mov rsi, rdx mov rdi, rax call strcmp@PLT test eax, eax jne .L4 mov eax, DWORD PTR -96[rbp] mov DWORD PTR -100[rbp], eax .L4: add DWORD PTR -96[rbp], 1 .L2: cmp DWORD PTR -96[rbp], 7 jle .L5 cmp DWORD PTR -104[rbp], -1 je .L6 cmp DWORD PTR -100[rbp], -1 je .L6 mov eax, DWORD PTR -104[rbp] cmp eax, DWORD PTR -100[rbp] jne .L7 .L6: mov rax, QWORD PTR -136[rbp] mov DWORD PTR [rax], 0 mov eax, 0 jmp .L13 .L7: mov eax, DWORD PTR -104[rbp] cmp eax, DWORD PTR -100[rbp] jle .L9 mov eax, DWORD PTR -104[rbp] mov DWORD PTR -92[rbp], eax mov eax, DWORD PTR -100[rbp] mov DWORD PTR -104[rbp], eax mov eax, DWORD PTR -92[rbp] mov DWORD PTR -100[rbp], eax .L9: mov eax, DWORD PTR -100[rbp] sub eax, DWORD PTR -104[rbp] lea edx, -1[rax] mov rax, QWORD PTR -136[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -136[rbp] mov eax, DWORD PTR [rax] test eax, eax jg .L10 mov rax, QWORD PTR -136[rbp] mov DWORD PTR [rax], 0 mov eax, 0 jmp .L13 .L10: mov rax, QWORD PTR -136[rbp] mov eax, DWORD PTR [rax] cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov QWORD PTR -88[rbp], rax mov eax, DWORD PTR -104[rbp] add eax, 1 mov DWORD PTR -96[rbp], eax jmp .L11 .L12: mov eax, DWORD PTR -96[rbp] sub eax, DWORD PTR -104[rbp] cdqe sal rax, 3 lea rdx, -8[rax] mov rax, QWORD PTR -88[rbp] add rdx, rax mov eax, DWORD PTR -96[rbp] cdqe mov rax, QWORD PTR -80[rbp+rax*8] mov QWORD PTR [rdx], rax add DWORD PTR -96[rbp], 1 .L11: mov eax, DWORD PTR -96[rbp] cmp eax, DWORD PTR -100[rbp] jl .L12 mov rax, QWORD PTR -88[rbp] .L13: mov rcx, QWORD PTR -8[rbp] xor rcx, QWORD PTR fs:40 je .L14 call __stack_chk_fail@PLT .L14: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .section .rodata .align 3 .LC0: .string "Mercury" .align 3 .LC1: .string "Venus" .align 3 .LC2: .string "Earth" .align 3 .LC3: .string "Mars" .align 3 .LC4: .string "Jupiter" .align 3 .LC5: .string "Saturn" .align 3 .LC6: .string "Uranus" .align 3 .LC7: .string "Neptune" .text .data .align 3 .LC9: .dword .LC0 .dword .LC1 .dword .LC2 .dword .LC3 .dword .LC4 .dword .LC5 .dword .LC6 .dword .LC7 .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-144 sd ra,136(sp) sd s0,128(sp) addi s0,sp,144 sd a0,-120(s0) sd a1,-128(s0) sd a2,-136(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) lla a5,.LC9 ld a7,0(a5) ld a6,8(a5) ld a0,16(a5) ld a1,24(a5) ld a2,32(a5) ld a3,40(a5) ld a4,48(a5) ld a5,56(a5) sd a7,-88(s0) sd a6,-80(s0) sd a0,-72(s0) sd a1,-64(s0) sd a2,-56(s0) sd a3,-48(s0) sd a4,-40(s0) sd a5,-32(s0) li a5,-1 sw a5,-112(s0) li a5,-1 sw a5,-108(s0) sw zero,-104(s0) j .L2 .L5: lw a5,-104(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a5,-72(a5) ld a1,-120(s0) mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L3 lw a5,-104(s0) sw a5,-112(s0) .L3: lw a5,-104(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a5,-72(a5) ld a1,-128(s0) mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L4 lw a5,-104(s0) sw a5,-108(s0) .L4: lw a5,-104(s0) addiw a5,a5,1 sw a5,-104(s0) .L2: lw a5,-104(s0) sext.w a4,a5 li a5,7 ble a4,a5,.L5 lw a5,-112(s0) sext.w a4,a5 li a5,-1 beq a4,a5,.L6 lw a5,-108(s0) sext.w a4,a5 li a5,-1 beq a4,a5,.L6 lw a4,-112(s0) lw a5,-108(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L7 .L6: ld a5,-136(s0) sw zero,0(a5) li a5,0 j .L13 .L7: lw a4,-112(s0) lw a5,-108(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L9 lw a5,-112(s0) sw a5,-100(s0) lw a5,-108(s0) sw a5,-112(s0) lw a5,-100(s0) sw a5,-108(s0) .L9: lw a4,-108(s0) lw a5,-112(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 ld a5,-136(s0) sw a4,0(a5) ld a5,-136(s0) lw a5,0(a5) bgtz a5,.L10 ld a5,-136(s0) sw zero,0(a5) li a5,0 j .L13 .L10: ld a5,-136(s0) lw a5,0(a5) slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-96(s0) lw a5,-112(s0) addiw a5,a5,1 sw a5,-104(s0) j .L11 .L12: lw a4,-104(s0) lw a5,-112(s0) subw a5,a4,a5 sext.w a5,a5 slli a5,a5,3 addi a5,a5,-8 ld a4,-96(s0) add a4,a4,a5 lw a5,-104(s0) slli a5,a5,3 addi a3,s0,-16 add a5,a3,a5 ld a5,-72(a5) sd a5,0(a4) lw a5,-104(s0) addiw a5,a5,1 sw a5,-104(s0) .L11: lw a4,-104(s0) lw a5,-108(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L12 ld a5,-96(s0) .L13: mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L14 call __stack_chk_fail@plt .L14: mv a0,a3 ld ra,136(sp) ld s0,128(sp) addi sp,sp,144 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem73/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -32[rbp], edx mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L5: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] sub eax, 1 sub eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax je .L3 mov eax, 0 jmp .L4 .L3: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -28[rbp] sub eax, 1 sub eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] add eax, edx add DWORD PTR -8[rbp], eax add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -4[rbp], eax jl .L5 mov eax, DWORD PTR -28[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L6 mov eax, DWORD PTR -28[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -8[rbp], eax .L6: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -32[rbp] setle al .L4: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 mv a4,a2 sw a5,-44(s0) mv a5,a4 sw a5,-48(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L5: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-44(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-20(s0) subw a5,a4,a5 sext.w a5,a5 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 beq a4,a5,.L3 li a5,0 j .L4 .L3: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-44(s0) addiw a5,a5,-1 sext.w a3,a5 lw a5,-20(s0) subw a5,a3,a5 sext.w a5,a5 slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) addw a5,a4,a5 sext.w a5,a5 lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-44(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-20(s0) sext.w a5,a5 blt a5,a4,.L5 lw a4,-44(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L6 lw a5,-44(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a5,a5 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L6: lw a4,-24(s0) lw a5,-48(s0) sext.w a4,a4 sext.w a5,a5 sgt a5,a4,a5 xori a5,a5,1 andi a5,a5,0xff .L4: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem156/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov QWORD PTR -32[rbp], rsi mov DWORD PTR -12[rbp], 0 mov DWORD PTR -8[rbp], 0 mov eax, DWORD PTR -20[rbp] sar eax, 31 xor DWORD PTR -20[rbp], eax sub DWORD PTR -20[rbp], eax .L4: mov edx, DWORD PTR -20[rbp] movsx rax, edx imul rax, rax, 1717986919 shr rax, 32 mov ecx, eax sar ecx, 2 mov eax, edx sar eax, 31 sub ecx, eax mov eax, ecx sal eax, 2 add eax, ecx add eax, eax sub edx, eax mov eax, edx mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -4[rbp] and eax, 1 test eax, eax jne .L2 add DWORD PTR -12[rbp], 1 jmp .L3 .L2: add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -20[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -20[rbp], eax cmp DWORD PTR -20[rbp], 0 jg .L4 mov rax, QWORD PTR -32[rbp] mov edx, DWORD PTR -12[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -32[rbp] lea rdx, 4[rax] mov eax, DWORD PTR -8[rbp] mov DWORD PTR [rdx], eax nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sd a1,-48(s0) sw a5,-36(s0) sw zero,-28(s0) sw zero,-24(s0) lw a5,-36(s0) sraiw a5,a5,31 lw a4,-36(s0) xor a4,a5,a4 subw a5,a4,a5 sw a5,-36(s0) .L4: lw a4,-36(s0) li a5,10 remw a5,a4,a5 sw a5,-20(s0) lw a5,-20(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L2 lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) j .L3 .L2: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a4,-36(s0) li a5,10 divw a5,a4,a5 sw a5,-36(s0) lw a5,-36(s0) sext.w a5,a5 bgtz a5,.L4 ld a5,-48(s0) lw a4,-28(s0) sw a4,0(a5) ld a5,-48(s0) addi a5,a5,4 lw a4,-24(s0) sw a4,0(a5) nop ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem162/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -16[rbp], 0 mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax mov DWORD PTR -12[rbp], 0 jmp .L2 .L6: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -40[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 1024 test eax, eax je .L3 call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -40[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 256 test eax, eax je .L4 mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movzx eax, al mov edi, eax call tolower@PLT mov ecx, eax mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, ecx mov BYTE PTR [rax], dl jmp .L5 .L4: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -12[rbp] movsx rcx, edx mov rdx, QWORD PTR -40[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 512 test eax, eax je .L5 mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movzx eax, al mov edi, eax call toupper@PLT mov ecx, eax mov eax, DWORD PTR -12[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, ecx mov BYTE PTR [rax], dl jmp .L5 .L3: add DWORD PTR -16[rbp], 1 .L5: add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -4[rbp] jl .L6 mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -4[rbp] jne .L7 mov DWORD PTR -8[rbp], 0 jmp .L8 .L9: mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -40[rbp] add rax, rdx movzx eax, BYTE PTR [rax] mov BYTE PTR -17[rbp], al mov eax, DWORD PTR -4[rbp] sub eax, DWORD PTR -8[rbp] cdqe lea rdx, -1[rax] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR -8[rbp] movsx rcx, edx mov rdx, QWORD PTR -40[rbp] add rdx, rcx movzx eax, BYTE PTR [rax] mov BYTE PTR [rdx], al mov eax, DWORD PTR -4[rbp] sub eax, DWORD PTR -8[rbp] cdqe lea rdx, -1[rax] mov rax, QWORD PTR -40[rbp] add rdx, rax movzx eax, BYTE PTR -17[rbp] mov BYTE PTR [rdx], al add DWORD PTR -8[rbp], 1 .L8: mov eax, DWORD PTR -4[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax cmp DWORD PTR -8[rbp], eax jl .L9 .L7: mov rax, QWORD PTR -40[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) sw zero,-32(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) sw zero,-28(s0) j .L2 .L6: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-56(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,1024 sext.w a5,a5 beqz a5,.L3 call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-56(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,256 sext.w a5,a5 beqz a5,.L4 lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a0,a5 call tolower@plt mv a5,a0 mv a3,a5 lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 andi a4,a3,0xff sb a4,0(a5) j .L5 .L4: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-28(s0) ld a3,-56(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,512 sext.w a5,a5 beqz a5,.L5 lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a0,a5 call toupper@plt mv a5,a0 mv a3,a5 lw a5,-28(s0) ld a4,-56(s0) add a5,a4,a5 andi a4,a3,0xff sb a4,0(a5) j .L5 .L3: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L5: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a4,-32(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L7 sw zero,-24(s0) j .L8 .L9: lw a5,-24(s0) ld a4,-56(s0) add a5,a4,a5 lbu a5,0(a5) sb a5,-33(s0) lw a4,-20(s0) lw a5,-24(s0) subw a5,a4,a5 sext.w a5,a5 addi a5,a5,-1 ld a4,-56(s0) add a4,a4,a5 lw a5,-24(s0) ld a3,-56(s0) add a5,a3,a5 lbu a4,0(a4) sb a4,0(a5) lw a4,-20(s0) lw a5,-24(s0) subw a5,a4,a5 sext.w a5,a5 addi a5,a5,-1 ld a4,-56(s0) add a5,a4,a5 lbu a4,-33(s0) sb a4,0(a5) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L8: lw a5,-20(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-24(s0) sext.w a5,a5 blt a5,a4,.L9 .L7: ld a5,-56(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem68/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 push rbx sub rsp, 72 .cfi_offset 3, -24 mov QWORD PTR -72[rbp], rdi mov DWORD PTR -76[rbp], esi mov rax, QWORD PTR fs:40 mov QWORD PTR -24[rbp], rax xor eax, eax mov QWORD PTR -44[rbp], 0 mov WORD PTR -36[rbp], 0 mov QWORD PTR -34[rbp], 0 mov WORD PTR -26[rbp], 0 mov DWORD PTR -56[rbp], 0 mov DWORD PTR -52[rbp], 0 mov DWORD PTR -48[rbp], 0 jmp .L2 .L6: call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] mov edx, DWORD PTR -48[rbp] movsx rcx, edx mov rdx, QWORD PTR -72[rbp] add rdx, rcx movzx edx, BYTE PTR [rdx] movsx rdx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 2048 test eax, eax je .L3 cmp DWORD PTR -56[rbp], 0 jne .L4 mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -72[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -52[rbp] lea edx, 1[rax] mov DWORD PTR -52[rbp], edx movzx edx, BYTE PTR [rcx] cdqe mov BYTE PTR -44[rbp+rax], dl jmp .L5 .L4: mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -72[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -52[rbp] lea edx, 1[rax] mov DWORD PTR -52[rbp], edx movzx edx, BYTE PTR [rcx] cdqe mov BYTE PTR -34[rbp+rax], dl jmp .L5 .L3: cmp DWORD PTR -56[rbp], 0 jne .L5 cmp DWORD PTR -52[rbp], 0 jle .L5 mov DWORD PTR -56[rbp], 1 mov DWORD PTR -52[rbp], 0 .L5: add DWORD PTR -48[rbp], 1 .L2: mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -72[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L6 lea rax, -44[rbp] mov rdi, rax call atoi@PLT mov edx, DWORD PTR -76[rbp] mov ebx, edx sub ebx, eax lea rax, -34[rbp] mov rdi, rax call atoi@PLT sub ebx, eax mov eax, ebx mov rsi, QWORD PTR -24[rbp] xor rsi, QWORD PTR fs:40 je .L8 call __stack_chk_fail@PLT .L8: add rsp, 72 pop rbx pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-112 sd ra,104(sp) sd s0,96(sp) sd s1,88(sp) addi s0,sp,112 sd a0,-104(s0) mv a5,a1 sw a5,-108(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-40(s0) sd zero,-72(s0) sh zero,-64(s0) sd zero,-56(s0) sh zero,-48(s0) sw zero,-84(s0) sw zero,-80(s0) sw zero,-76(s0) j .L2 .L6: call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lw a5,-76(s0) ld a3,-104(s0) add a5,a3,a5 lbu a5,0(a5) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a4,a5 li a5,4096 addi a5,a5,-2048 and a5,a4,a5 sext.w a5,a5 beqz a5,.L3 lw a5,-84(s0) sext.w a5,a5 bnez a5,.L4 lw a5,-76(s0) ld a4,-104(s0) add a4,a4,a5 lw a5,-80(s0) addiw a3,a5,1 sw a3,-80(s0) lbu a4,0(a4) addi a3,s0,-32 add a5,a3,a5 sb a4,-40(a5) j .L5 .L4: lw a5,-76(s0) ld a4,-104(s0) add a4,a4,a5 lw a5,-80(s0) addiw a3,a5,1 sw a3,-80(s0) lbu a4,0(a4) addi a3,s0,-32 add a5,a3,a5 sb a4,-24(a5) j .L5 .L3: lw a5,-84(s0) sext.w a5,a5 bnez a5,.L5 lw a5,-80(s0) sext.w a5,a5 blez a5,.L5 li a5,1 sw a5,-84(s0) sw zero,-80(s0) .L5: lw a5,-76(s0) addiw a5,a5,1 sw a5,-76(s0) .L2: lw a5,-76(s0) ld a4,-104(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L6 addi a5,s0,-72 mv a0,a5 call atoi@plt mv a5,a0 mv a4,a5 lw a5,-108(s0) subw a5,a5,a4 sext.w s1,a5 addi a5,s0,-56 mv a0,a5 call atoi@plt mv a5,a0 subw a5,s1,a5 sext.w a5,a5 mv a3,a5 la a5,__stack_chk_guard ld a4,-40(s0) ld a5,0(a5) beq a4,a5,.L8 call __stack_chk_fail@plt .L8: mv a0,a3 ld ra,104(sp) ld s0,96(sp) ld s1,88(sp) addi sp,sp,112 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem72/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 movss DWORD PTR -20[rbp], xmm0 movss DWORD PTR -24[rbp], xmm1 movss DWORD PTR -28[rbp], xmm2 movss xmm0, DWORD PTR -20[rbp] movaps xmm1, xmm0 addss xmm1, DWORD PTR -24[rbp] movss xmm0, DWORD PTR -28[rbp] comiss xmm0, xmm1 jnb .L2 movss xmm0, DWORD PTR -20[rbp] movaps xmm1, xmm0 addss xmm1, DWORD PTR -28[rbp] movss xmm0, DWORD PTR -24[rbp] comiss xmm0, xmm1 jnb .L2 movss xmm0, DWORD PTR -24[rbp] movaps xmm1, xmm0 addss xmm1, DWORD PTR -28[rbp] movss xmm0, DWORD PTR -20[rbp] comiss xmm0, xmm1 jb .L6 .L2: movss xmm0, DWORD PTR .LC0[rip] jmp .L5 .L6: movss xmm0, DWORD PTR -20[rbp] addss xmm0, DWORD PTR -24[rbp] addss xmm0, DWORD PTR -28[rbp] movss xmm1, DWORD PTR .LC1[rip] divss xmm0, xmm1 movss DWORD PTR -8[rbp], xmm0 movss xmm0, DWORD PTR -8[rbp] subss xmm0, DWORD PTR -20[rbp] movaps xmm1, xmm0 mulss xmm1, DWORD PTR -8[rbp] movss xmm0, DWORD PTR -8[rbp] subss xmm0, DWORD PTR -24[rbp] mulss xmm1, xmm0 movss xmm0, DWORD PTR -8[rbp] subss xmm0, DWORD PTR -28[rbp] mulss xmm0, xmm1 call sqrtf@PLT movd eax, xmm0 mov DWORD PTR -4[rbp], eax movss xmm1, DWORD PTR -4[rbp] movss xmm0, DWORD PTR .LC2[rip] mulss xmm0, xmm1 call roundf@PLT movss xmm1, DWORD PTR .LC2[rip] divss xmm0, xmm1 .L5: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .section .rodata .align 4 .LC0: .long 3212836864 .align 4 .LC1: .long 1073741824 .align 4 .LC2: .long 1120403456 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 fsw fa0,-36(s0) fsw fa1,-40(s0) fsw fa2,-44(s0) flw fa4,-36(s0) flw fa5,-40(s0) fadd.s fa5,fa4,fa5 flw fa4,-44(s0) fge.s a5,fa4,fa5 bnez a5,.L2 flw fa4,-36(s0) flw fa5,-44(s0) fadd.s fa5,fa4,fa5 flw fa4,-40(s0) fge.s a5,fa4,fa5 bnez a5,.L2 flw fa4,-40(s0) flw fa5,-44(s0) fadd.s fa5,fa4,fa5 flw fa4,-36(s0) fge.s a5,fa4,fa5 beqz a5,.L6 .L2: lla a5,.LC0 flw fa5,0(a5) j .L5 .L6: flw fa4,-36(s0) flw fa5,-40(s0) fadd.s fa4,fa4,fa5 flw fa5,-44(s0) fadd.s fa4,fa4,fa5 lla a5,.LC1 flw fa5,0(a5) fdiv.s fa5,fa4,fa5 fsw fa5,-24(s0) flw fa4,-24(s0) flw fa5,-36(s0) fsub.s fa4,fa4,fa5 flw fa5,-24(s0) fmul.s fa4,fa4,fa5 flw fa3,-24(s0) flw fa5,-40(s0) fsub.s fa5,fa3,fa5 fmul.s fa4,fa4,fa5 flw fa3,-24(s0) flw fa5,-44(s0) fsub.s fa5,fa3,fa5 fmul.s fa5,fa4,fa5 fmv.s fa0,fa5 call sqrtf@plt fsw fa0,-20(s0) flw fa4,-20(s0) lla a5,.LC2 flw fa5,0(a5) fmul.s fa5,fa4,fa5 fmv.s fa0,fa5 call roundf@plt fmv.s fa4,fa0 lla a5,.LC2 flw fa5,0(a5) fdiv.s fa5,fa4,fa5 .L5: fmv.s fa0,fa5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .section .rodata .align 2 .LC0: .word 3212836864 .align 2 .LC1: .word 1073741824 .align 2 .LC2: .word 1120403456 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem18/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "o" .LC1: .string "o|" .LC2: .string ".|" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 80 mov QWORD PTR -72[rbp], rdi mov QWORD PTR -80[rbp], rsi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov QWORD PTR -40[rbp], 0 mov DWORD PTR -56[rbp], 0 mov DWORD PTR -52[rbp], 0 mov WORD PTR -11[rbp], 0 mov BYTE PTR -9[rbp], 0 mov rax, QWORD PTR -72[rbp] mov rdi, rax call strlen@PLT add eax, 1 mov DWORD PTR -44[rbp], eax mov eax, DWORD PTR -44[rbp] add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -32[rbp], rax mov rdx, QWORD PTR -72[rbp] mov rax, QWORD PTR -32[rbp] mov rsi, rdx mov rdi, rax call strcpy@PLT mov rax, QWORD PTR -32[rbp] mov rcx, -1 mov rdx, rax mov eax, 0 mov rdi, rdx repnz scasb mov rax, rcx not rax lea rdx, -1[rax] mov rax, QWORD PTR -32[rbp] add rax, rdx mov WORD PTR [rax], 32 mov DWORD PTR -48[rbp], 0 jmp .L2 .L17: mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -32[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 32 jne .L3 lea rax, -11[rbp] lea rsi, .LC0[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L4 mov eax, DWORD PTR -56[rbp] cmp eax, DWORD PTR -52[rbp] jne .L5 cmp DWORD PTR -52[rbp], 0 jle .L6 mov eax, DWORD PTR -52[rbp] add eax, eax jmp .L7 .L6: mov eax, 4 .L7: mov DWORD PTR -52[rbp], eax mov eax, DWORD PTR -52[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call realloc@PLT mov QWORD PTR -40[rbp], rax .L5: mov eax, DWORD PTR -56[rbp] lea edx, 1[rax] mov DWORD PTR -56[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov DWORD PTR [rax], 4 .L4: lea rax, -11[rbp] lea rsi, .LC1[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L8 mov eax, DWORD PTR -56[rbp] cmp eax, DWORD PTR -52[rbp] jne .L9 cmp DWORD PTR -52[rbp], 0 jle .L10 mov eax, DWORD PTR -52[rbp] add eax, eax jmp .L11 .L10: mov eax, 4 .L11: mov DWORD PTR -52[rbp], eax mov eax, DWORD PTR -52[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call realloc@PLT mov QWORD PTR -40[rbp], rax .L9: mov eax, DWORD PTR -56[rbp] lea edx, 1[rax] mov DWORD PTR -56[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov DWORD PTR [rax], 2 .L8: lea rax, -11[rbp] lea rsi, .LC2[rip] mov rdi, rax call strcmp@PLT test eax, eax jne .L12 mov eax, DWORD PTR -56[rbp] cmp eax, DWORD PTR -52[rbp] jne .L13 cmp DWORD PTR -52[rbp], 0 jle .L14 mov eax, DWORD PTR -52[rbp] add eax, eax jmp .L15 .L14: mov eax, 4 .L15: mov DWORD PTR -52[rbp], eax mov eax, DWORD PTR -52[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] mov rsi, rdx mov rdi, rax call realloc@PLT mov QWORD PTR -40[rbp], rax .L13: mov eax, DWORD PTR -56[rbp] lea edx, 1[rax] mov DWORD PTR -56[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov DWORD PTR [rax], 1 .L12: mov BYTE PTR -11[rbp], 0 jmp .L16 .L3: lea rax, -11[rbp] mov rdi, rax call strlen@PLT mov QWORD PTR -24[rbp], rax cmp QWORD PTR -24[rbp], 1 ja .L16 mov eax, DWORD PTR -48[rbp] movsx rdx, eax mov rax, QWORD PTR -32[rbp] add rax, rdx movzx eax, BYTE PTR [rax] lea rcx, -11[rbp] mov rdx, QWORD PTR -24[rbp] add rdx, rcx mov BYTE PTR [rdx], al mov rax, QWORD PTR -24[rbp] add rax, 1 mov BYTE PTR -11[rbp+rax], 0 .L16: add DWORD PTR -48[rbp], 1 .L2: mov eax, DWORD PTR -48[rbp] cmp eax, DWORD PTR -44[rbp] jl .L17 mov rax, QWORD PTR -32[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -80[rbp] mov edx, DWORD PTR -56[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -40[rbp] mov rcx, QWORD PTR -8[rbp] xor rcx, QWORD PTR fs:40 je .L19 call __stack_chk_fail@PLT .L19: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "o" .align 3 .LC1: .string "o|" .align 3 .LC2: .string ".|" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-96 sd ra,88(sp) sd s0,80(sp) addi s0,sp,96 sd a0,-88(s0) sd a1,-96(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) sd zero,-56(s0) sw zero,-72(s0) sw zero,-68(s0) sh zero,-32(s0) sb zero,-30(s0) ld a0,-88(s0) call strlen@plt mv a5,a0 sext.w a5,a5 addiw a5,a5,1 sext.w a5,a5 sw a5,-60(s0) lw a5,-60(s0) addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-48(s0) ld a1,-88(s0) ld a0,-48(s0) call strcpy@plt ld a0,-48(s0) call strlen@plt mv a5,a0 mv a4,a5 ld a5,-48(s0) add a5,a5,a4 li a4,32 sb a4,0(a5) sb zero,1(a5) sw zero,-64(s0) j .L2 .L17: lw a5,-64(s0) ld a4,-48(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,32 bne a4,a5,.L3 addi a5,s0,-32 lla a1,.LC0 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L4 lw a4,-72(s0) lw a5,-68(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L5 lw a5,-68(s0) sext.w a5,a5 blez a5,.L6 lw a5,-68(s0) slliw a5,a5,1 sext.w a5,a5 j .L7 .L6: li a5,4 .L7: sw a5,-68(s0) lw a5,-68(s0) slli a5,a5,2 mv a1,a5 ld a0,-56(s0) call realloc@plt sd a0,-56(s0) .L5: lw a5,-72(s0) addiw a4,a5,1 sw a4,-72(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 li a4,4 sw a4,0(a5) .L4: addi a5,s0,-32 lla a1,.LC1 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L8 lw a4,-72(s0) lw a5,-68(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L9 lw a5,-68(s0) sext.w a5,a5 blez a5,.L10 lw a5,-68(s0) slliw a5,a5,1 sext.w a5,a5 j .L11 .L10: li a5,4 .L11: sw a5,-68(s0) lw a5,-68(s0) slli a5,a5,2 mv a1,a5 ld a0,-56(s0) call realloc@plt sd a0,-56(s0) .L9: lw a5,-72(s0) addiw a4,a5,1 sw a4,-72(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 li a4,2 sw a4,0(a5) .L8: addi a5,s0,-32 lla a1,.LC2 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L12 lw a4,-72(s0) lw a5,-68(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L13 lw a5,-68(s0) sext.w a5,a5 blez a5,.L14 lw a5,-68(s0) slliw a5,a5,1 sext.w a5,a5 j .L15 .L14: li a5,4 .L15: sw a5,-68(s0) lw a5,-68(s0) slli a5,a5,2 mv a1,a5 ld a0,-56(s0) call realloc@plt sd a0,-56(s0) .L13: lw a5,-72(s0) addiw a4,a5,1 sw a4,-72(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 li a4,1 sw a4,0(a5) .L12: sb zero,-32(s0) j .L16 .L3: addi a5,s0,-32 mv a0,a5 call strlen@plt sd a0,-40(s0) ld a4,-40(s0) li a5,1 bgtu a4,a5,.L16 lw a5,-64(s0) ld a4,-48(s0) add a5,a4,a5 lbu a4,0(a5) ld a5,-40(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-16(a5) ld a5,-40(s0) addi a5,a5,1 addi a4,s0,-16 add a5,a4,a5 sb zero,-16(a5) .L16: lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L2: lw a4,-64(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L17 ld a0,-48(s0) call free@plt ld a5,-96(s0) lw a4,-72(s0) sw a4,0(a5) ld a5,-56(s0) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L19 call __stack_chk_fail@plt .L19: mv a0,a3 ld ra,88(sp) ld s0,80(sp) addi sp,sp,96 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem17/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 1072 mov QWORD PTR -1064[rbp], rdi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov DWORD PTR -1048[rbp], 0 lea rdx, -1040[rbp] mov eax, 0 mov ecx, 128 mov rdi, rdx rep stosq mov DWORD PTR -1044[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -1044[rbp] movsx rdx, eax mov rax, QWORD PTR -1064[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movzx eax, al mov edi, eax call tolower@PLT mov BYTE PTR -1049[rbp], al movsx eax, BYTE PTR -1049[rbp] cdqe mov eax, DWORD PTR -1040[rbp+rax*4] test eax, eax jne .L3 call __ctype_b_loc@PLT mov rax, QWORD PTR [rax] movzx edx, BYTE PTR -1049[rbp] movzx edx, dl add rdx, rdx add rax, rdx movzx eax, WORD PTR [rax] movzx eax, ax and eax, 1024 test eax, eax je .L3 movsx eax, BYTE PTR -1049[rbp] cdqe mov DWORD PTR -1040[rbp+rax*4], 1 add DWORD PTR -1048[rbp], 1 .L3: add DWORD PTR -1044[rbp], 1 .L2: mov eax, DWORD PTR -1044[rbp] movsx rdx, eax mov rax, QWORD PTR -1064[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L4 mov eax, DWORD PTR -1048[rbp] mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L6 call __stack_chk_fail@PLT .L6: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-1088 sd ra,1080(sp) sd s0,1072(sp) addi s0,sp,1088 sd a0,-1080(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) sw zero,-1056(s0) addi a5,s0,-1048 li a4,1024 mv a2,a4 li a1,0 mv a0,a5 call memset@plt sw zero,-1052(s0) j .L2 .L4: lw a5,-1052(s0) ld a4,-1080(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 mv a0,a5 call tolower@plt mv a5,a0 sb a5,-1057(s0) lbu a5,-1057(s0) sext.w a5,a5 slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a5,-1032(a5) bnez a5,.L3 call __ctype_b_loc@plt mv a5,a0 ld a4,0(a5) lbu a5,-1057(s0) slli a5,a5,1 add a5,a4,a5 lhu a5,0(a5) sext.w a5,a5 andi a5,a5,1024 sext.w a5,a5 beqz a5,.L3 lbu a5,-1057(s0) sext.w a5,a5 slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 li a4,1 sw a4,-1032(a5) lw a5,-1056(s0) addiw a5,a5,1 sw a5,-1056(s0) .L3: lw a5,-1052(s0) addiw a5,a5,1 sw a5,-1052(s0) .L2: lw a5,-1052(s0) ld a4,-1080(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L4 lw a5,-1056(s0) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L6 call __stack_chk_fail@plt .L6: mv a0,a3 ld ra,1080(sp) ld s0,1072(sp) addi sp,sp,1088 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem125/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -56[rbp], rdi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov rax, QWORD PTR -56[rbp] mov rdi, rax call strlen@PLT cmp rax, 10 je .L2 mov eax, 0 jmp .L18 .L2: mov DWORD PTR -36[rbp], 0 jmp .L4 .L10: cmp DWORD PTR -36[rbp], 2 je .L5 cmp DWORD PTR -36[rbp], 5 jne .L6 .L5: mov eax, DWORD PTR -36[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 45 je .L8 mov eax, 0 jmp .L18 .L6: mov eax, DWORD PTR -36[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 47 jle .L9 mov eax, DWORD PTR -36[rbp] movsx rdx, eax mov rax, QWORD PTR -56[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 57 jle .L8 .L9: mov eax, 0 jmp .L18 .L8: add DWORD PTR -36[rbp], 1 .L4: cmp DWORD PTR -36[rbp], 9 jle .L10 mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR [rax] mov BYTE PTR -19[rbp], al mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 1[rax] mov BYTE PTR -18[rbp], al mov BYTE PTR -17[rbp], 0 mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 3[rax] mov BYTE PTR -16[rbp], al mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 4[rax] mov BYTE PTR -15[rbp], al mov BYTE PTR -14[rbp], 0 mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 6[rax] mov BYTE PTR -13[rbp], al mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 7[rax] mov BYTE PTR -12[rbp], al mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 8[rax] mov BYTE PTR -11[rbp], al mov rax, QWORD PTR -56[rbp] movzx eax, BYTE PTR 9[rax] mov BYTE PTR -10[rbp], al mov BYTE PTR -9[rbp], 0 lea rax, -19[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -32[rbp], eax lea rax, -16[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -28[rbp], eax lea rax, -13[rbp] mov rdi, rax call atoi@PLT mov DWORD PTR -24[rbp], eax cmp DWORD PTR -32[rbp], 0 jle .L11 cmp DWORD PTR -32[rbp], 12 jle .L12 .L11: mov eax, 0 jmp .L18 .L12: cmp DWORD PTR -28[rbp], 0 jle .L13 cmp DWORD PTR -28[rbp], 31 jle .L14 .L13: mov eax, 0 jmp .L18 .L14: cmp DWORD PTR -32[rbp], 4 je .L15 cmp DWORD PTR -32[rbp], 6 je .L15 cmp DWORD PTR -32[rbp], 9 je .L15 cmp DWORD PTR -32[rbp], 11 jne .L16 .L15: cmp DWORD PTR -28[rbp], 31 jne .L16 mov eax, 0 jmp .L18 .L16: cmp DWORD PTR -32[rbp], 2 jne .L17 cmp DWORD PTR -28[rbp], 29 jle .L17 mov eax, 0 jmp .L18 .L17: mov eax, 1 .L18: mov rcx, QWORD PTR -8[rbp] xor rcx, QWORD PTR fs:40 je .L19 call __stack_chk_fail@PLT .L19: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-72(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) ld a0,-72(s0) call strlen@plt mv a4,a0 li a5,10 beq a4,a5,.L2 li a5,0 j .L18 .L2: sw zero,-64(s0) j .L4 .L10: lw a5,-64(s0) sext.w a4,a5 li a5,2 beq a4,a5,.L5 lw a5,-64(s0) sext.w a4,a5 li a5,5 bne a4,a5,.L6 .L5: lw a5,-64(s0) ld a4,-72(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,45 beq a4,a5,.L8 li a5,0 j .L18 .L6: lw a5,-64(s0) ld a4,-72(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,47 bleu a4,a5,.L9 lw a5,-64(s0) ld a4,-72(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,57 bleu a4,a5,.L8 .L9: li a5,0 j .L18 .L8: lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L4: lw a5,-64(s0) sext.w a4,a5 li a5,9 ble a4,a5,.L10 ld a5,-72(s0) lbu a5,0(a5) sb a5,-48(s0) ld a5,-72(s0) lbu a5,1(a5) sb a5,-47(s0) sb zero,-46(s0) ld a5,-72(s0) lbu a5,3(a5) sb a5,-40(s0) ld a5,-72(s0) lbu a5,4(a5) sb a5,-39(s0) sb zero,-38(s0) ld a5,-72(s0) lbu a5,6(a5) sb a5,-32(s0) ld a5,-72(s0) lbu a5,7(a5) sb a5,-31(s0) ld a5,-72(s0) lbu a5,8(a5) sb a5,-30(s0) ld a5,-72(s0) lbu a5,9(a5) sb a5,-29(s0) sb zero,-28(s0) addi a5,s0,-48 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-60(s0) addi a5,s0,-40 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-56(s0) addi a5,s0,-32 mv a0,a5 call atoi@plt mv a5,a0 sw a5,-52(s0) lw a5,-60(s0) sext.w a5,a5 blez a5,.L11 lw a5,-60(s0) sext.w a4,a5 li a5,12 ble a4,a5,.L12 .L11: li a5,0 j .L18 .L12: lw a5,-56(s0) sext.w a5,a5 blez a5,.L13 lw a5,-56(s0) sext.w a4,a5 li a5,31 ble a4,a5,.L14 .L13: li a5,0 j .L18 .L14: lw a5,-60(s0) sext.w a4,a5 li a5,4 beq a4,a5,.L15 lw a5,-60(s0) sext.w a4,a5 li a5,6 beq a4,a5,.L15 lw a5,-60(s0) sext.w a4,a5 li a5,9 beq a4,a5,.L15 lw a5,-60(s0) sext.w a4,a5 li a5,11 bne a4,a5,.L16 .L15: lw a5,-56(s0) sext.w a4,a5 li a5,31 bne a4,a5,.L16 li a5,0 j .L18 .L16: lw a5,-60(s0) sext.w a4,a5 li a5,2 bne a4,a5,.L17 lw a5,-56(s0) sext.w a4,a5 li a5,29 ble a4,a5,.L17 li a5,0 j .L18 .L17: li a5,1 .L18: mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L19 call __stack_chk_fail@plt .L19: mv a0,a3 ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem35/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 64 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov QWORD PTR -56[rbp], rdx mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov DWORD PTR -24[rbp], 0 mov DWORD PTR -20[rbp], 0 jmp .L2 .L8: mov DWORD PTR -28[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -16[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jne .L4 mov DWORD PTR -28[rbp], 1 jmp .L5 .L4: add DWORD PTR -16[rbp], 1 .L3: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -24[rbp] jl .L6 .L5: cmp DWORD PTR -28[rbp], 0 jne .L7 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] lea rcx, [rdx+rax] mov eax, DWORD PTR -24[rbp] lea edx, 1[rax] mov DWORD PTR -24[rbp], edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR [rcx] mov DWORD PTR [rdx], eax .L7: add DWORD PTR -20[rbp], 1 .L2: mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -44[rbp] jl .L8 mov DWORD PTR -20[rbp], 0 jmp .L9 .L13: mov eax, DWORD PTR -20[rbp] add eax, 1 mov DWORD PTR -16[rbp], eax jmp .L10 .L12: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -16[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L11 mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR -20[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -8[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -12[rbp] mov DWORD PTR [rdx], eax .L11: add DWORD PTR -16[rbp], 1 .L10: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -24[rbp] jl .L12 add DWORD PTR -20[rbp], 1 .L9: mov eax, DWORD PTR -24[rbp] sub eax, 1 cmp DWORD PTR -20[rbp], eax jl .L13 mov rax, QWORD PTR -56[rbp] mov edx, DWORD PTR -24[rbp] mov DWORD PTR [rax], edx mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-80 sd ra,72(sp) sd s0,64(sp) addi s0,sp,80 sd a0,-56(s0) mv a5,a1 sd a2,-72(s0) sw a5,-60(s0) lw a5,-60(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) sw zero,-40(s0) sw zero,-36(s0) j .L2 .L8: sw zero,-44(s0) sw zero,-32(s0) j .L3 .L6: lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-32(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 bne a4,a5,.L4 li a5,1 sw a5,-44(s0) j .L5 .L4: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L3: lw a4,-32(s0) lw a5,-40(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 .L5: lw a5,-44(s0) sext.w a5,a5 bnez a5,.L7 lw a5,-36(s0) slli a5,a5,2 ld a4,-56(s0) add a4,a4,a5 lw a5,-40(s0) addiw a3,a5,1 sw a3,-40(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) .L7: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L2: lw a4,-36(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 sw zero,-36(s0) j .L9 .L13: lw a5,-36(s0) addiw a5,a5,1 sw a5,-32(s0) j .L10 .L12: lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-32(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L11 lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) lw a5,-32(s0) slli a5,a5,2 ld a4,-24(s0) add a4,a4,a5 lw a5,-36(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-32(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-28(s0) sw a4,0(a5) .L11: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L10: lw a4,-32(s0) lw a5,-40(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L12 lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L9: lw a5,-40(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 blt a5,a4,.L13 ld a5,-72(s0) lw a4,-40(s0) sw a4,0(a5) ld a5,-24(s0) mv a0,a5 ld ra,72(sp) ld s0,64(sp) addi sp,sp,80 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem75/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov DWORD PTR -32[rbp], ecx mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 mov DWORD PTR -12[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call strlen@PLT mov edx, eax mov eax, DWORD PTR -8[rbp] add eax, edx mov DWORD PTR -8[rbp], eax add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -28[rbp] jl .L3 mov DWORD PTR -12[rbp], 0 jmp .L4 .L5: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call strlen@PLT mov edx, eax mov eax, DWORD PTR -4[rbp] add eax, edx mov DWORD PTR -4[rbp], eax add DWORD PTR -12[rbp], 1 .L4: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -32[rbp] jl .L5 mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -4[rbp] jge .L6 mov rax, QWORD PTR -24[rbp] jmp .L7 .L6: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -4[rbp] jle .L8 mov rax, QWORD PTR -40[rbp] jmp .L7 .L8: mov rax, QWORD PTR -24[rbp] .L7: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) mv a4,a3 sw a5,-44(s0) mv a5,a4 sw a5,-48(s0) sw zero,-24(s0) sw zero,-20(s0) sw zero,-28(s0) j .L2 .L3: lw a5,-28(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call strlen@plt mv a5,a0 sext.w a4,a5 lw a5,-24(s0) addw a5,a4,a5 sext.w a5,a5 sw a5,-24(s0) lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a4,-28(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 sw zero,-28(s0) j .L4 .L5: lw a5,-28(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call strlen@plt mv a5,a0 sext.w a4,a5 lw a5,-20(s0) addw a5,a4,a5 sext.w a5,a5 sw a5,-20(s0) lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L4: lw a4,-28(s0) lw a5,-48(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L5 lw a4,-24(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 bge a4,a5,.L6 ld a5,-40(s0) j .L7 .L6: lw a4,-24(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L8 ld a5,-56(s0) j .L7 .L8: ld a5,-40(s0) .L7: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem93/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 16 movss DWORD PTR -4[rbp], xmm0 movss DWORD PTR -8[rbp], xmm1 movss DWORD PTR -12[rbp], xmm2 mov eax, DWORD PTR -4[rbp] movd xmm0, eax call roundf@PLT ucomiss xmm0, DWORD PTR -4[rbp] jp .L14 ucomiss xmm0, DWORD PTR -4[rbp] je .L19 .L14: mov eax, 0 jmp .L4 .L19: mov eax, DWORD PTR -8[rbp] movd xmm0, eax call roundf@PLT ucomiss xmm0, DWORD PTR -8[rbp] jp .L15 ucomiss xmm0, DWORD PTR -8[rbp] je .L20 .L15: mov eax, 0 jmp .L4 .L20: mov eax, DWORD PTR -12[rbp] movd xmm0, eax call roundf@PLT ucomiss xmm0, DWORD PTR -12[rbp] jp .L16 ucomiss xmm0, DWORD PTR -12[rbp] je .L21 .L16: mov eax, 0 jmp .L4 .L21: movss xmm0, DWORD PTR -4[rbp] addss xmm0, DWORD PTR -8[rbp] ucomiss xmm0, DWORD PTR -12[rbp] jp .L17 ucomiss xmm0, DWORD PTR -12[rbp] je .L9 .L17: movss xmm0, DWORD PTR -4[rbp] addss xmm0, DWORD PTR -12[rbp] ucomiss xmm0, DWORD PTR -8[rbp] jp .L18 ucomiss xmm0, DWORD PTR -8[rbp] je .L9 .L18: movss xmm0, DWORD PTR -8[rbp] addss xmm0, DWORD PTR -12[rbp] ucomiss xmm0, DWORD PTR -4[rbp] jp .L12 ucomiss xmm0, DWORD PTR -4[rbp] jne .L12 .L9: mov eax, 1 jmp .L4 .L12: mov eax, 0 .L4: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd ra,24(sp) sd s0,16(sp) addi s0,sp,32 fsw fa0,-20(s0) fsw fa1,-24(s0) fsw fa2,-28(s0) flw fa0,-20(s0) call roundf@plt fmv.s fa4,fa0 flw fa5,-20(s0) feq.s a5,fa5,fa4 bnez a5,.L2 li a5,0 j .L3 .L2: flw fa0,-24(s0) call roundf@plt fmv.s fa4,fa0 flw fa5,-24(s0) feq.s a5,fa5,fa4 bnez a5,.L4 li a5,0 j .L3 .L4: flw fa0,-28(s0) call roundf@plt fmv.s fa4,fa0 flw fa5,-28(s0) feq.s a5,fa5,fa4 bnez a5,.L5 li a5,0 j .L3 .L5: flw fa4,-20(s0) flw fa5,-24(s0) fadd.s fa5,fa4,fa5 flw fa4,-28(s0) feq.s a5,fa4,fa5 bnez a5,.L6 flw fa4,-20(s0) flw fa5,-28(s0) fadd.s fa5,fa4,fa5 flw fa4,-24(s0) feq.s a5,fa4,fa5 bnez a5,.L6 flw fa4,-24(s0) flw fa5,-28(s0) fadd.s fa5,fa4,fa5 flw fa4,-20(s0) feq.s a5,fa4,fa5 beqz a5,.L7 .L6: li a5,1 j .L3 .L7: li a5,0 .L3: mv a0,a5 ld ra,24(sp) ld s0,16(sp) addi sp,sp,32 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem1/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi movss DWORD PTR -32[rbp], xmm0 mov DWORD PTR -8[rbp], 0 jmp .L2 .L8: mov eax, DWORD PTR -8[rbp] add eax, 1 mov DWORD PTR -4[rbp], eax jmp .L3 .L7: mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm0, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx movss xmm1, DWORD PTR [rax] subss xmm0, xmm1 movss xmm1, DWORD PTR .LC0[rip] andps xmm1, xmm0 movss xmm0, DWORD PTR -32[rbp] comiss xmm0, xmm1 jbe .L10 mov eax, 1 jmp .L6 .L10: add DWORD PTR -4[rbp], 1 .L3: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L8 mov eax, 10 .L6: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .section .rodata .align 16 .LC0: .long 2147483647 .long 0 .long 0 .long 0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 fsw fa0,-48(s0) sw a5,-44(s0) sw zero,-24(s0) j .L2 .L8: lw a5,-24(s0) addiw a5,a5,1 sw a5,-20(s0) j .L3 .L7: lw a5,-24(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 flw fa5,0(a5) fsub.s fa5,fa4,fa5 fabs.s fa5,fa5 flw fa4,-48(s0) fgt.s a5,fa4,fa5 beqz a5,.L10 li a5,1 j .L6 .L10: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L3: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 li a5,10 .L6: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem97/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov DWORD PTR -36[rbp], edi mov QWORD PTR -48[rbp], rsi mov eax, DWORD PTR -36[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -48[rbp] mov DWORD PTR [rax], 0 mov DWORD PTR -24[rbp], 2 jmp .L2 .L9: mov DWORD PTR -16[rbp], 1 mov DWORD PTR -20[rbp], 0 jmp .L3 .L7: mov eax, DWORD PTR -20[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -12[rbp] imul eax, eax cmp DWORD PTR -24[rbp], eax jl .L11 mov eax, DWORD PTR -24[rbp] cdq idiv DWORD PTR -12[rbp] mov eax, edx test eax, eax jne .L6 mov DWORD PTR -16[rbp], 0 jmp .L5 .L6: add DWORD PTR -20[rbp], 1 .L3: mov rax, QWORD PTR -48[rbp] mov eax, DWORD PTR [rax] cmp DWORD PTR -20[rbp], eax jl .L7 jmp .L5 .L11: nop .L5: cmp DWORD PTR -16[rbp], 0 je .L8 mov rax, QWORD PTR -48[rbp] mov eax, DWORD PTR [rax] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -24[rbp] mov DWORD PTR [rdx], eax mov rax, QWORD PTR -48[rbp] mov eax, DWORD PTR [rax] lea edx, 1[rax] mov rax, QWORD PTR -48[rbp] mov DWORD PTR [rax], edx .L8: add DWORD PTR -24[rbp], 1 .L2: mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -36[rbp] jl .L9 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 mv a5,a0 sd a1,-64(s0) sw a5,-52(s0) lw a5,-52(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-64(s0) sw zero,0(a5) li a5,2 sw a5,-40(s0) j .L2 .L9: li a5,1 sw a5,-32(s0) sw zero,-36(s0) j .L3 .L7: lw a5,-36(s0) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) lw a5,-28(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-40(s0) sext.w a5,a5 blt a5,a4,.L11 lw a4,-40(s0) lw a5,-28(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L6 sw zero,-32(s0) j .L5 .L6: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: ld a5,-64(s0) lw a4,0(a5) lw a5,-36(s0) sext.w a5,a5 blt a5,a4,.L7 j .L5 .L11: nop .L5: lw a5,-32(s0) sext.w a5,a5 beqz a5,.L8 ld a5,-64(s0) lw a5,0(a5) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-40(s0) sw a4,0(a5) ld a5,-64(s0) lw a5,0(a5) addiw a5,a5,1 sext.w a4,a5 ld a5,-64(s0) sw a4,0(a5) .L8: lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L2: lw a4,-40(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem32/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi cmp QWORD PTR -24[rbp], 1 jg .L2 mov eax, 0 jmp .L3 .L2: mov QWORD PTR -8[rbp], 2 jmp .L4 .L6: mov rax, QWORD PTR -24[rbp] cqo idiv QWORD PTR -8[rbp] mov rax, rdx test rax, rax jne .L5 mov eax, 0 jmp .L3 .L5: add QWORD PTR -8[rbp], 1 .L4: mov rax, QWORD PTR -8[rbp] imul rax, rax cmp QWORD PTR -24[rbp], rax jge .L6 mov eax, 1 .L3: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) ld a4,-40(s0) li a5,1 bgt a4,a5,.L2 li a5,0 j .L3 .L2: li a5,2 sd a5,-24(s0) j .L4 .L6: ld a4,-40(s0) ld a5,-24(s0) rem a5,a4,a5 bnez a5,.L5 li a5,0 j .L3 .L5: ld a5,-24(s0) addi a5,a5,1 sd a5,-24(s0) .L4: ld a5,-24(s0) mul a5,a5,a5 ld a4,-40(s0) bge a4,a5,.L6 li a5,1 .L3: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem143/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L6: mov ecx, DWORD PTR -4[rbp] movsx rax, ecx imul rax, rax, 1431655766 shr rax, 32 mov rdx, rax mov eax, ecx sar eax, 31 mov esi, edx sub esi, eax mov eax, esi mov edx, eax add edx, edx add edx, eax mov eax, ecx sub eax, edx test eax, eax jne .L3 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] imul eax, edx add DWORD PTR -8[rbp], eax jmp .L4 .L3: mov eax, DWORD PTR -4[rbp] and eax, 3 test eax, eax jne .L5 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] imul edx, eax mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] imul eax, edx add DWORD PTR -8[rbp], eax jmp .L4 .L5: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -8[rbp], eax .L4: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L6 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L6: lw a4,-20(s0) li a5,3 remw a5,a4,a5 sext.w a5,a5 bnez a5,.L3 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) mulw a5,a4,a5 sext.w a5,a5 lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) j .L4 .L3: lw a5,-20(s0) andi a5,a5,3 sext.w a5,a5 bnez a5,.L5 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) mulw a5,a4,a5 sext.w a4,a5 lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a5,0(a5) mulw a5,a4,a5 sext.w a5,a5 lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) j .L4 .L5: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L4: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L6 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem29/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call strlen@PLT mov edx, eax mov eax, DWORD PTR -20[rbp] add eax, edx mov DWORD PTR -20[rbp], eax add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -44[rbp] jl .L3 mov eax, DWORD PTR -20[rbp] add eax, 1 cdqe mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax cmp QWORD PTR -8[rbp], 0 jne .L4 mov eax, 0 jmp .L5 .L4: mov rax, QWORD PTR -8[rbp] mov BYTE PTR [rax], 0 mov DWORD PTR -12[rbp], 0 jmp .L6 .L7: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rdx, QWORD PTR [rax] mov rax, QWORD PTR -8[rbp] mov rsi, rdx mov rdi, rax call strcat@PLT add DWORD PTR -12[rbp], 1 .L6: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -44[rbp] jl .L7 mov rax, QWORD PTR -8[rbp] .L5: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) sw zero,-36(s0) sw zero,-32(s0) j .L2 .L3: lw a5,-32(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call strlen@plt mv a5,a0 sext.w a4,a5 lw a5,-36(s0) addw a5,a4,a5 sext.w a5,a5 sw a5,-36(s0) lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a4,-32(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 lw a5,-36(s0) addiw a5,a5,1 sext.w a5,a5 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) bnez a5,.L4 li a5,0 j .L5 .L4: ld a5,-24(s0) sb zero,0(a5) sw zero,-28(s0) j .L6 .L7: lw a5,-28(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) mv a1,a5 ld a0,-24(s0) call strcat@plt lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L6: lw a4,-28(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 ld a5,-24(s0) .L5: mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem154/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "%s.%s" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 80 mov QWORD PTR -56[rbp], rdi mov QWORD PTR -64[rbp], rsi mov DWORD PTR -68[rbp], edx mov QWORD PTR -80[rbp], rcx mov DWORD PTR -32[rbp], -1000 mov QWORD PTR -16[rbp], 0 mov DWORD PTR -28[rbp], 0 jmp .L2 .L8: mov eax, DWORD PTR -28[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -64[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov QWORD PTR -8[rbp], rax mov DWORD PTR -24[rbp], 0 mov DWORD PTR -20[rbp], 0 jmp .L3 .L6: mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx eax, BYTE PTR [rax] mov BYTE PTR -33[rbp], al cmp BYTE PTR -33[rbp], 64 jle .L4 cmp BYTE PTR -33[rbp], 90 jg .L4 add DWORD PTR -24[rbp], 1 .L4: cmp BYTE PTR -33[rbp], 96 jle .L5 cmp BYTE PTR -33[rbp], 122 jg .L5 sub DWORD PTR -24[rbp], 1 .L5: add DWORD PTR -20[rbp], 1 .L3: mov eax, DWORD PTR -20[rbp] movsx rdx, eax mov rax, QWORD PTR -8[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L6 mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -32[rbp] jle .L7 mov eax, DWORD PTR -24[rbp] mov DWORD PTR -32[rbp], eax mov rax, QWORD PTR -8[rbp] mov QWORD PTR -16[rbp], rax .L7: add DWORD PTR -28[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] cmp eax, DWORD PTR -68[rbp] jl .L8 mov rcx, QWORD PTR -16[rbp] mov rdx, QWORD PTR -56[rbp] mov rax, QWORD PTR -80[rbp] lea rsi, .LC0[rip] mov rdi, rax mov eax, 0 call sprintf@PLT nop leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "%s.%s" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-96 sd ra,88(sp) sd s0,80(sp) addi s0,sp,96 sd a0,-72(s0) sd a1,-80(s0) mv a5,a2 sd a3,-96(s0) sw a5,-84(s0) li a5,-1000 sw a5,-48(s0) sd zero,-32(s0) sw zero,-44(s0) j .L2 .L8: lw a5,-44(s0) slli a5,a5,3 ld a4,-80(s0) add a5,a4,a5 ld a5,0(a5) sd a5,-24(s0) sw zero,-40(s0) sw zero,-36(s0) j .L3 .L6: lw a5,-36(s0) ld a4,-24(s0) add a5,a4,a5 lbu a5,0(a5) sb a5,-49(s0) lbu a5,-49(s0) andi a4,a5,0xff li a5,64 bleu a4,a5,.L4 lbu a5,-49(s0) andi a4,a5,0xff li a5,90 bgtu a4,a5,.L4 lw a5,-40(s0) addiw a5,a5,1 sw a5,-40(s0) .L4: lbu a5,-49(s0) andi a4,a5,0xff li a5,96 bleu a4,a5,.L5 lbu a5,-49(s0) andi a4,a5,0xff li a5,122 bgtu a4,a5,.L5 lw a5,-40(s0) addiw a5,a5,-1 sw a5,-40(s0) .L5: lw a5,-36(s0) addiw a5,a5,1 sw a5,-36(s0) .L3: lw a5,-36(s0) ld a4,-24(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L6 lw a4,-40(s0) lw a5,-48(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L7 lw a5,-40(s0) sw a5,-48(s0) ld a5,-24(s0) sd a5,-32(s0) .L7: lw a5,-44(s0) addiw a5,a5,1 sw a5,-44(s0) .L2: lw a4,-44(s0) lw a5,-84(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 ld a3,-32(s0) ld a2,-72(s0) lla a1,.LC0 ld a0,-96(s0) call sprintf@plt nop ld ra,88(sp) ld s0,80(sp) addi sp,sp,96 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem43/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -4[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -4[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx add edx, 1 mov DWORD PTR [rax], edx add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L3 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-20(s0) j .L2 .L3: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-20(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 addiw a4,a4,1 sext.w a4,a4 sw a4,0(a5) lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L3 nop nop ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem26/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov DWORD PTR -20[rbp], edi mov QWORD PTR -32[rbp], rsi mov edi, 256 call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -32[rbp] mov DWORD PTR [rax], 0 mov DWORD PTR -12[rbp], 2 jmp .L2 .L4: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -12[rbp] mov DWORD PTR -20[rbp], eax mov rax, QWORD PTR -32[rbp] mov eax, DWORD PTR [rax] lea ecx, 1[rax] mov rdx, QWORD PTR -32[rbp] mov DWORD PTR [rdx], ecx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -12[rbp] mov DWORD PTR [rdx], eax .L3: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -12[rbp] mov eax, edx test eax, eax je .L4 add DWORD PTR -12[rbp], 1 .L2: mov eax, DWORD PTR -12[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L3 cmp DWORD PTR -20[rbp], 1 jle .L6 mov rax, QWORD PTR -32[rbp] mov eax, DWORD PTR [rax] lea ecx, 1[rax] mov rdx, QWORD PTR -32[rbp] mov DWORD PTR [rdx], ecx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rdx, rax mov eax, DWORD PTR -20[rbp] mov DWORD PTR [rdx], eax .L6: mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 mv a5,a0 sd a1,-48(s0) sw a5,-36(s0) li a0,256 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-48(s0) sw zero,0(a5) li a5,2 sw a5,-28(s0) j .L2 .L4: lw a4,-36(s0) lw a5,-28(s0) divw a5,a4,a5 sw a5,-36(s0) ld a5,-48(s0) lw a5,0(a5) addiw a4,a5,1 sext.w a3,a4 ld a4,-48(s0) sw a3,0(a4) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-28(s0) sw a4,0(a5) .L3: lw a4,-36(s0) lw a5,-28(s0) remw a5,a4,a5 sext.w a5,a5 beqz a5,.L4 lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L2: lw a5,-28(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L3 lw a5,-36(s0) sext.w a4,a5 li a5,1 ble a4,a5,.L6 ld a5,-48(s0) lw a5,0(a5) addiw a4,a5,1 sext.w a3,a4 ld a4,-48(s0) sw a3,0(a4) slli a5,a5,2 ld a4,-24(s0) add a5,a4,a5 lw a4,-36(s0) sw a4,0(a5) .L6: ld a5,-24(s0) mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem131/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov DWORD PTR -20[rbp], edi mov eax, DWORD PTR -20[rbp] add eax, 1 cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -8[rbp], rax mov rax, QWORD PTR -8[rbp] mov DWORD PTR [rax], 1 cmp DWORD PTR -20[rbp], 0 jne .L2 mov rax, QWORD PTR -8[rbp] jmp .L3 .L2: mov rax, QWORD PTR -8[rbp] add rax, 4 mov DWORD PTR [rax], 3 mov DWORD PTR -12[rbp], 2 jmp .L4 .L7: mov eax, DWORD PTR -12[rbp] and eax, 1 test eax, eax jne .L5 mov eax, DWORD PTR -12[rbp] mov edx, eax shr edx, 31 add eax, edx sar eax mov ecx, eax mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rdx lea edx, 1[rcx] mov DWORD PTR [rax], edx jmp .L6 .L5: mov eax, DWORD PTR -12[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -8[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -12[rbp] cdqe sal rax, 2 lea rcx, -8[rax] mov rax, QWORD PTR -8[rbp] add rax, rcx mov eax, DWORD PTR [rax] add eax, edx lea edx, 1[rax] mov eax, DWORD PTR -12[rbp] add eax, 1 mov ecx, eax shr ecx, 31 add eax, ecx sar eax mov esi, eax mov eax, DWORD PTR -12[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -8[rbp] add rax, rcx add edx, esi mov DWORD PTR [rax], edx .L6: add DWORD PTR -12[rbp], 1 .L4: mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -20[rbp] jle .L7 mov rax, QWORD PTR -8[rbp] .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) lw a5,-36(s0) addiw a5,a5,1 sext.w a5,a5 slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-24(s0) ld a5,-24(s0) li a4,1 sw a4,0(a5) lw a5,-36(s0) sext.w a5,a5 bnez a5,.L2 ld a5,-24(s0) j .L3 .L2: ld a5,-24(s0) addi a5,a5,4 li a4,3 sw a4,0(a5) li a5,2 sw a5,-28(s0) j .L4 .L7: lw a5,-28(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L5 lw a5,-28(s0) srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-28(s0) slli a5,a5,2 ld a3,-24(s0) add a5,a3,a5 addiw a4,a4,1 sext.w a4,a4 sw a4,0(a5) j .L6 .L5: lw a5,-28(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-24(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) slli a5,a5,2 addi a5,a5,-8 ld a3,-24(s0) add a5,a3,a5 lw a5,0(a5) addw a5,a4,a5 sext.w a5,a5 addiw a5,a5,1 sext.w a3,a5 lw a5,-28(s0) addiw a5,a5,1 sext.w a5,a5 srliw a4,a5,31 addw a5,a4,a5 sraiw a5,a5,1 sext.w a4,a5 lw a5,-28(s0) slli a5,a5,2 ld a2,-24(s0) add a5,a2,a5 addw a4,a3,a4 sext.w a4,a4 sw a4,0(a5) .L6: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L4: lw a4,-28(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L7 ld a5,-24(s0) .L3: mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem90/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov QWORD PTR -32[rbp], rsi mov DWORD PTR -8[rbp], 0 jmp .L2 .L3: mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] movsx eax, al lea edx, -93[rax] movsx rax, edx imul rax, rax, 1321528399 shr rax, 32 mov ecx, eax sar ecx, 3 mov eax, edx sar eax, 31 sub ecx, eax mov eax, ecx imul eax, eax, 26 sub edx, eax mov eax, edx add eax, 97 mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -32[rbp] add rax, rdx mov edx, DWORD PTR -4[rbp] mov BYTE PTR [rax], dl add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -24[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L3 mov eax, DWORD PTR -8[rbp] movsx rdx, eax mov rax, QWORD PTR -32[rbp] add rax, rdx mov BYTE PTR [rax], 0 nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) sd a1,-48(s0) sw zero,-24(s0) j .L2 .L3: lw a5,-24(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) sext.w a5,a5 addiw a5,a5,-93 sext.w a5,a5 mv a4,a5 li a5,26 remw a5,a4,a5 sext.w a5,a5 addiw a5,a5,97 sw a5,-20(s0) lw a5,-24(s0) ld a4,-48(s0) add a5,a4,a5 lw a4,-20(s0) andi a4,a4,0xff sb a4,0(a5) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a5,-24(s0) ld a4,-40(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L3 lw a5,-24(s0) ld a4,-48(s0) add a5,a4,a5 sb zero,0(a5) nop ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem30/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov QWORD PTR -40[rbp], rdx mov QWORD PTR -48[rbp], rcx mov rax, QWORD PTR -40[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -28[rbp] cdqe sal rax, 3 mov rdi, rax call malloc@PLT mov rdx, rax mov rax, QWORD PTR -48[rbp] mov QWORD PTR [rax], rdx mov DWORD PTR -12[rbp], 0 mov DWORD PTR -8[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov eax, DWORD PTR -8[rbp] cdqe lea rcx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] add rax, rcx mov rax, QWORD PTR [rax] mov rcx, QWORD PTR -40[rbp] mov rsi, rcx mov rdi, rax call strncmp@PLT test eax, eax jne .L3 mov eax, DWORD PTR -8[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -24[rbp] lea rcx, [rdx+rax] mov rax, QWORD PTR -48[rbp] mov rsi, QWORD PTR [rax] mov eax, DWORD PTR -12[rbp] lea edx, 1[rax] mov DWORD PTR -12[rbp], edx cdqe sal rax, 3 lea rdx, [rsi+rax] mov rax, QWORD PTR [rcx] mov QWORD PTR [rdx], rax .L3: add DWORD PTR -8[rbp], 1 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -28[rbp] jl .L4 mov eax, DWORD PTR -12[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 sd a2,-56(s0) sd a3,-64(s0) sw a5,-44(s0) ld a0,-56(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) lw a5,-44(s0) slli a5,a5,3 mv a0,a5 call malloc@plt mv a5,a0 mv a4,a5 ld a5,-64(s0) sd a4,0(a5) sw zero,-28(s0) sw zero,-24(s0) j .L2 .L4: lw a5,-24(s0) slli a5,a5,3 ld a4,-40(s0) add a5,a4,a5 ld a5,0(a5) lw a4,-20(s0) mv a2,a4 ld a1,-56(s0) mv a0,a5 call strncmp@plt mv a5,a0 bnez a5,.L3 lw a5,-24(s0) slli a5,a5,3 ld a4,-40(s0) add a4,a4,a5 ld a5,-64(s0) ld a3,0(a5) lw a5,-28(s0) addiw a2,a5,1 sw a2,-28(s0) slli a5,a5,3 add a5,a3,a5 ld a4,0(a4) sd a4,0(a5) .L3: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L2: lw a4,-24(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L4 lw a5,-28(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem164/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov DWORD PTR -24[rbp], esi mov QWORD PTR -32[rbp], rdx mov QWORD PTR -40[rbp], rcx mov rax, QWORD PTR -40[rbp] mov DWORD PTR [rax], 0 mov eax, DWORD PTR -24[rbp] cmp eax, DWORD PTR -20[rbp] jge .L2 mov eax, DWORD PTR -20[rbp] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -24[rbp] mov DWORD PTR -20[rbp], eax mov eax, DWORD PTR -4[rbp] mov DWORD PTR -24[rbp], eax .L2: mov eax, DWORD PTR -20[rbp] mov DWORD PTR -8[rbp], eax jmp .L3 .L5: cmp DWORD PTR -8[rbp], 9 jg .L4 mov eax, DWORD PTR -8[rbp] and eax, 1 test eax, eax jne .L4 mov rax, QWORD PTR -40[rbp] mov eax, DWORD PTR [rax] lea ecx, 1[rax] mov rdx, QWORD PTR -40[rbp] mov DWORD PTR [rdx], ecx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -32[rbp] add rdx, rax mov eax, DWORD PTR -8[rbp] mov DWORD PTR [rdx], eax .L4: add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -24[rbp] jle .L5 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 mv a5,a0 mv a4,a1 sd a2,-48(s0) sd a3,-56(s0) sw a5,-36(s0) mv a5,a4 sw a5,-40(s0) ld a5,-56(s0) sw zero,0(a5) lw a4,-40(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 bge a4,a5,.L2 lw a5,-36(s0) sw a5,-20(s0) lw a5,-40(s0) sw a5,-36(s0) lw a5,-20(s0) sw a5,-40(s0) .L2: lw a5,-36(s0) sw a5,-24(s0) j .L3 .L5: lw a5,-24(s0) sext.w a4,a5 li a5,9 bgt a4,a5,.L4 lw a5,-24(s0) andi a5,a5,1 sext.w a5,a5 bnez a5,.L4 ld a5,-56(s0) lw a5,0(a5) addiw a4,a5,1 sext.w a3,a4 ld a4,-56(s0) sw a3,0(a4) slli a5,a5,2 ld a4,-48(s0) add a5,a4,a5 lw a4,-24(s0) sw a4,0(a5) .L4: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a4,-24(s0) lw a5,-40(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L5 nop nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem95/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi mov DWORD PTR -24[rbp], 0 mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L2 .L8: mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -40[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -4[rbp], eax cmp DWORD PTR -4[rbp], 1 jle .L3 mov DWORD PTR -12[rbp], 1 mov DWORD PTR -8[rbp], 2 jmp .L4 .L7: mov eax, DWORD PTR -4[rbp] cdq idiv DWORD PTR -8[rbp] mov eax, edx test eax, eax jne .L5 mov DWORD PTR -12[rbp], 0 jmp .L6 .L5: add DWORD PTR -8[rbp], 1 .L4: mov eax, DWORD PTR -8[rbp] imul eax, eax cmp DWORD PTR -4[rbp], eax jge .L7 .L6: cmp DWORD PTR -12[rbp], 0 je .L3 mov eax, DWORD PTR -4[rbp] cmp DWORD PTR -24[rbp], eax cmovge eax, DWORD PTR -24[rbp] mov DWORD PTR -24[rbp], eax .L3: add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -44[rbp] jl .L8 jmp .L9 .L10: mov ecx, DWORD PTR -24[rbp] movsx rax, ecx imul rax, rax, 1717986919 shr rax, 32 mov edx, eax sar edx, 2 mov eax, ecx sar eax, 31 sub edx, eax mov eax, edx sal eax, 2 add eax, edx add eax, eax sub ecx, eax mov edx, ecx add DWORD PTR -20[rbp], edx mov eax, DWORD PTR -24[rbp] movsx rdx, eax imul rdx, rdx, 1717986919 shr rdx, 32 sar edx, 2 sar eax, 31 sub edx, eax mov eax, edx mov DWORD PTR -24[rbp], eax .L9: cmp DWORD PTR -24[rbp], 0 jg .L10 mov eax, DWORD PTR -20[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) sw zero,-40(s0) sw zero,-36(s0) sw zero,-32(s0) j .L2 .L9: lw a5,-32(s0) slli a5,a5,2 ld a4,-56(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-20(s0) lw a5,-20(s0) sext.w a4,a5 li a5,1 ble a4,a5,.L3 li a5,1 sw a5,-28(s0) li a5,2 sw a5,-24(s0) j .L4 .L7: lw a4,-20(s0) lw a5,-24(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L5 sw zero,-28(s0) j .L6 .L5: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L4: lw a5,-24(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-20(s0) sext.w a5,a5 bge a5,a4,.L7 .L6: lw a5,-28(s0) sext.w a5,a5 beqz a5,.L3 lw a2,-20(s0) lw a5,-40(s0) sext.w a3,a5 sext.w a4,a2 bge a3,a4,.L8 mv a5,a2 .L8: sw a5,-40(s0) .L3: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a4,-32(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 j .L10 .L11: lw a4,-40(s0) li a5,10 remw a5,a4,a5 sext.w a5,a5 lw a4,-36(s0) addw a5,a4,a5 sw a5,-36(s0) lw a4,-40(s0) li a5,10 divw a5,a4,a5 sw a5,-40(s0) .L10: lw a5,-40(s0) sext.w a5,a5 bgtz a5,.L11 lw a5,-36(s0) mv a0,a5 ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem103/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -4[rbp], edi mov DWORD PTR -8[rbp], esi mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -4[rbp] jge .L2 mov eax, -1 jmp .L3 .L2: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -4[rbp] jne .L4 mov eax, DWORD PTR -8[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L4 mov eax, -1 jmp .L3 .L4: mov eax, DWORD PTR -8[rbp] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L5 mov eax, DWORD PTR -8[rbp] sub eax, 1 jmp .L3 .L5: mov eax, DWORD PTR -8[rbp] .L3: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-32 sd s0,24(sp) addi s0,sp,32 mv a5,a0 mv a4,a1 sw a5,-20(s0) mv a5,a4 sw a5,-24(s0) lw a4,-24(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 bge a4,a5,.L2 li a5,-1 j .L3 .L2: lw a4,-24(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L4 lw a4,-24(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L4 li a5,-1 j .L3 .L4: lw a4,-24(s0) sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L5 lw a5,-24(s0) addiw a5,a5,-1 sext.w a5,a5 j .L3 .L5: lw a5,-24(s0) .L3: mv a0,a5 ld s0,24(sp) addi sp,sp,32 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem40/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -36[rbp], edi mov DWORD PTR -24[rbp], 1 mov DWORD PTR -20[rbp], 2 mov DWORD PTR -16[rbp], 0 jmp .L2 .L9: mov eax, DWORD PTR -20[rbp] add DWORD PTR -24[rbp], eax mov eax, DWORD PTR -24[rbp] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -20[rbp] mov DWORD PTR -24[rbp], eax mov eax, DWORD PTR -4[rbp] mov DWORD PTR -20[rbp], eax mov DWORD PTR -12[rbp], 1 mov DWORD PTR -8[rbp], 2 jmp .L3 .L6: mov eax, DWORD PTR -24[rbp] cdq idiv DWORD PTR -8[rbp] mov eax, edx test eax, eax jne .L4 mov DWORD PTR -12[rbp], 0 jmp .L5 .L4: add DWORD PTR -8[rbp], 1 .L3: mov eax, DWORD PTR -8[rbp] imul eax, eax cmp DWORD PTR -24[rbp], eax jge .L6 .L5: cmp DWORD PTR -12[rbp], 0 je .L7 add DWORD PTR -16[rbp], 1 .L7: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -36[rbp] jne .L2 mov eax, DWORD PTR -24[rbp] jmp .L8 .L2: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -36[rbp] jl .L9 mov eax, 0 .L8: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 mv a5,a0 sw a5,-52(s0) li a5,1 sw a5,-40(s0) li a5,2 sw a5,-36(s0) sw zero,-32(s0) j .L2 .L9: lw a4,-40(s0) lw a5,-36(s0) addw a5,a4,a5 sw a5,-40(s0) lw a5,-40(s0) sw a5,-20(s0) lw a5,-36(s0) sw a5,-40(s0) lw a5,-20(s0) sw a5,-36(s0) li a5,1 sw a5,-28(s0) li a5,2 sw a5,-24(s0) j .L3 .L6: lw a4,-40(s0) lw a5,-24(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L4 sw zero,-28(s0) j .L5 .L4: lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L3: lw a5,-24(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-40(s0) sext.w a5,a5 bge a5,a4,.L6 .L5: lw a5,-28(s0) sext.w a5,a5 beqz a5,.L7 lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L7: lw a4,-32(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 bne a4,a5,.L2 lw a5,-40(s0) j .L8 .L2: lw a4,-32(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L9 li a5,0 .L8: mv a0,a5 ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem60/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov DWORD PTR -20[rbp], edi mov DWORD PTR -4[rbp], 2 jmp .L2 .L5: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -4[rbp] mov DWORD PTR -20[rbp], eax .L3: mov eax, DWORD PTR -20[rbp] cdq idiv DWORD PTR -4[rbp] mov eax, edx test eax, eax jne .L4 mov eax, DWORD PTR -20[rbp] cmp eax, DWORD PTR -4[rbp] jg .L5 .L4: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] imul eax, eax cmp DWORD PTR -20[rbp], eax jge .L3 mov eax, DWORD PTR -20[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 mv a5,a0 sw a5,-36(s0) li a5,2 sw a5,-20(s0) j .L2 .L5: lw a4,-36(s0) lw a5,-20(s0) divw a5,a4,a5 sw a5,-36(s0) .L3: lw a4,-36(s0) lw a5,-20(s0) remw a5,a4,a5 sext.w a5,a5 bnez a5,.L4 lw a4,-36(s0) lw a5,-20(s0) sext.w a4,a4 sext.w a5,a5 bgt a4,a5,.L5 .L4: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) mulw a5,a5,a5 sext.w a4,a5 lw a5,-36(s0) sext.w a5,a5 bge a5,a4,.L3 lw a5,-36(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem122/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -8[rbp], 0 mov DWORD PTR -4[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -4[rbp] add eax, eax cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdq shr edx, 31 add eax, edx and eax, 1 sub eax, edx cmp eax, 1 jne .L3 mov eax, DWORD PTR -4[rbp] add eax, eax cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] add DWORD PTR -8[rbp], eax .L3: add DWORD PTR -4[rbp], 1 .L2: mov eax, DWORD PTR -4[rbp] add eax, eax cmp DWORD PTR -28[rbp], eax jg .L4 mov eax, DWORD PTR -8[rbp] pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) sw zero,-24(s0) sw zero,-20(s0) j .L2 .L4: lw a5,-20(s0) slliw a5,a5,1 sext.w a5,a5 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a5 sraiw a5,a4,31 srliw a5,a5,31 addw a4,a4,a5 andi a4,a4,1 subw a5,a4,a5 sext.w a5,a5 mv a4,a5 li a5,1 bne a4,a5,.L3 lw a5,-20(s0) slliw a5,a5,1 sext.w a5,a5 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) lw a4,-24(s0) addw a5,a4,a5 sw a5,-24(s0) .L3: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L2: lw a5,-20(s0) slliw a5,a5,1 sext.w a4,a5 lw a5,-44(s0) sext.w a5,a5 bgt a5,a4,.L4 lw a5,-24(s0) mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem146/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "%d" .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 80 mov QWORD PTR -72[rbp], rdi mov DWORD PTR -76[rbp], esi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov eax, DWORD PTR -76[rbp] cdqe sal rax, 2 mov rdi, rax call malloc@PLT mov QWORD PTR -32[rbp], rax mov DWORD PTR -60[rbp], 0 jmp .L2 .L7: mov eax, DWORD PTR -60[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -72[rbp] add rax, rdx mov eax, DWORD PTR [rax] cdq xor eax, edx sub eax, edx lea rcx, -20[rbp] mov edx, eax lea rsi, .LC0[rip] mov rdi, rcx mov eax, 0 call sprintf@PLT mov DWORD PTR -56[rbp], 0 lea rax, -20[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -36[rbp], eax mov DWORD PTR -52[rbp], 1 jmp .L3 .L4: mov eax, DWORD PTR -52[rbp] cdqe movzx eax, BYTE PTR -20[rbp+rax] movsx eax, al sub eax, 48 add DWORD PTR -56[rbp], eax add DWORD PTR -52[rbp], 1 .L3: mov eax, DWORD PTR -52[rbp] cmp eax, DWORD PTR -36[rbp] jl .L4 mov eax, DWORD PTR -60[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -72[rbp] add rax, rdx mov eax, DWORD PTR [rax] test eax, eax jle .L5 movzx eax, BYTE PTR -20[rbp] movsx eax, al sub eax, 48 add DWORD PTR -56[rbp], eax jmp .L6 .L5: movzx eax, BYTE PTR -20[rbp] movsx eax, al sub eax, 48 sub DWORD PTR -56[rbp], eax .L6: mov eax, DWORD PTR -60[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -32[rbp] add rdx, rax mov eax, DWORD PTR -56[rbp] mov DWORD PTR [rdx], eax add DWORD PTR -60[rbp], 1 .L2: mov eax, DWORD PTR -60[rbp] cmp eax, DWORD PTR -76[rbp] jl .L7 mov DWORD PTR -48[rbp], 0 jmp .L8 .L12: mov DWORD PTR -44[rbp], 1 jmp .L9 .L11: mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -32[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -44[rbp] cdqe lea rcx, 0[0+rax*4] mov rax, QWORD PTR -32[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L10 mov eax, DWORD PTR -44[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -32[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -40[rbp], eax mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -32[rbp] add rax, rdx mov edx, DWORD PTR -44[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -32[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -32[rbp] add rdx, rax mov eax, DWORD PTR -40[rbp] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -44[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -72[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -40[rbp], eax mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -72[rbp] add rax, rdx mov edx, DWORD PTR -44[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -72[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -44[rbp] cdqe sal rax, 2 lea rdx, -4[rax] mov rax, QWORD PTR -72[rbp] add rdx, rax mov eax, DWORD PTR -40[rbp] mov DWORD PTR [rdx], eax .L10: add DWORD PTR -44[rbp], 1 .L9: mov eax, DWORD PTR -44[rbp] cmp eax, DWORD PTR -76[rbp] jl .L11 add DWORD PTR -48[rbp], 1 .L8: mov eax, DWORD PTR -48[rbp] cmp eax, DWORD PTR -76[rbp] jl .L12 mov rax, QWORD PTR -32[rbp] mov rdi, rax call free@PLT mov rax, QWORD PTR -72[rbp] mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L14 call __stack_chk_fail@PLT .L14: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "%d" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-96 sd ra,88(sp) sd s0,80(sp) addi s0,sp,96 sd a0,-88(s0) mv a5,a1 sw a5,-92(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) lw a5,-92(s0) slli a5,a5,2 mv a0,a5 call malloc@plt mv a5,a0 sd a5,-48(s0) sw zero,-76(s0) j .L2 .L7: lw a5,-76(s0) slli a5,a5,2 ld a4,-88(s0) add a5,a4,a5 lw a4,0(a5) sraiw a5,a4,31 xor a4,a4,a5 subw a5,a4,a5 sext.w a4,a5 addi a5,s0,-40 mv a2,a4 lla a1,.LC0 mv a0,a5 call sprintf@plt sw zero,-72(s0) addi a5,s0,-40 mv a0,a5 call strlen@plt mv a5,a0 sw a5,-52(s0) li a5,1 sw a5,-68(s0) j .L3 .L4: lw a5,-68(s0) addi a4,s0,-16 add a5,a4,a5 lbu a5,-24(a5) sext.w a5,a5 addiw a5,a5,-48 sext.w a5,a5 lw a4,-72(s0) addw a5,a4,a5 sw a5,-72(s0) lw a5,-68(s0) addiw a5,a5,1 sw a5,-68(s0) .L3: lw a4,-68(s0) lw a5,-52(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L4 lw a5,-76(s0) slli a5,a5,2 ld a4,-88(s0) add a5,a4,a5 lw a5,0(a5) blez a5,.L5 lbu a5,-40(s0) sext.w a5,a5 addiw a5,a5,-48 sext.w a5,a5 lw a4,-72(s0) addw a5,a4,a5 sw a5,-72(s0) j .L6 .L5: lbu a5,-40(s0) sext.w a5,a5 addiw a5,a5,-48 sext.w a5,a5 lw a4,-72(s0) subw a5,a4,a5 sw a5,-72(s0) .L6: lw a5,-76(s0) slli a5,a5,2 ld a4,-48(s0) add a5,a4,a5 lw a4,-72(s0) sw a4,0(a5) lw a5,-76(s0) addiw a5,a5,1 sw a5,-76(s0) .L2: lw a4,-76(s0) lw a5,-92(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 sw zero,-64(s0) j .L8 .L12: li a5,1 sw a5,-60(s0) j .L9 .L11: lw a5,-60(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-48(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-60(s0) slli a5,a5,2 ld a4,-48(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L10 lw a5,-60(s0) slli a5,a5,2 ld a4,-48(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-56(s0) lw a5,-60(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-48(s0) add a4,a4,a5 lw a5,-60(s0) slli a5,a5,2 ld a3,-48(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-60(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-48(s0) add a5,a4,a5 lw a4,-56(s0) sw a4,0(a5) lw a5,-60(s0) slli a5,a5,2 ld a4,-88(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-56(s0) lw a5,-60(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-88(s0) add a4,a4,a5 lw a5,-60(s0) slli a5,a5,2 ld a3,-88(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-60(s0) slli a5,a5,2 addi a5,a5,-4 ld a4,-88(s0) add a5,a4,a5 lw a4,-56(s0) sw a4,0(a5) .L10: lw a5,-60(s0) addiw a5,a5,1 sw a5,-60(s0) .L9: lw a4,-60(s0) lw a5,-92(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L11 lw a5,-64(s0) addiw a5,a5,1 sw a5,-64(s0) .L8: lw a4,-64(s0) lw a5,-92(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L12 ld a0,-48(s0) call free@plt ld a5,-88(s0) mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L14 call __stack_chk_fail@plt .L14: mv a0,a3 ld ra,88(sp) ld s0,80(sp) addi sp,sp,96 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem157/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "m" .LC1: .string "cm" .LC2: .string "d" .LC3: .string "cd" .LC4: .string "c" .LC5: .string "xc" .LC6: .string "l" .LC7: .string "xl" .LC8: .string "x" .LC9: .string "ix" .LC10: .string "v" .LC11: .string "iv" .LC12: .string "i" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 208 mov DWORD PTR -196[rbp], edi mov QWORD PTR -208[rbp], rsi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax lea rax, .LC0[rip] mov QWORD PTR -112[rbp], rax lea rax, .LC1[rip] mov QWORD PTR -104[rbp], rax lea rax, .LC2[rip] mov QWORD PTR -96[rbp], rax lea rax, .LC3[rip] mov QWORD PTR -88[rbp], rax lea rax, .LC4[rip] mov QWORD PTR -80[rbp], rax lea rax, .LC5[rip] mov QWORD PTR -72[rbp], rax lea rax, .LC6[rip] mov QWORD PTR -64[rbp], rax lea rax, .LC7[rip] mov QWORD PTR -56[rbp], rax lea rax, .LC8[rip] mov QWORD PTR -48[rbp], rax lea rax, .LC9[rip] mov QWORD PTR -40[rbp], rax lea rax, .LC10[rip] mov QWORD PTR -32[rbp], rax lea rax, .LC11[rip] mov QWORD PTR -24[rbp], rax lea rax, .LC12[rip] mov QWORD PTR -16[rbp], rax mov DWORD PTR -176[rbp], 1000 mov DWORD PTR -172[rbp], 900 mov DWORD PTR -168[rbp], 500 mov DWORD PTR -164[rbp], 400 mov DWORD PTR -160[rbp], 100 mov DWORD PTR -156[rbp], 90 mov DWORD PTR -152[rbp], 50 mov DWORD PTR -148[rbp], 40 mov DWORD PTR -144[rbp], 10 mov DWORD PTR -140[rbp], 9 mov DWORD PTR -136[rbp], 5 mov DWORD PTR -132[rbp], 4 mov DWORD PTR -128[rbp], 1 mov DWORD PTR -180[rbp], 0 mov rax, QWORD PTR -208[rbp] mov BYTE PTR [rax], 0 jmp .L2 .L4: mov eax, DWORD PTR -180[rbp] cdqe mov rdx, QWORD PTR -112[rbp+rax*8] mov rax, QWORD PTR -208[rbp] mov rsi, rdx mov rdi, rax call strcat@PLT mov eax, DWORD PTR -180[rbp] cdqe mov eax, DWORD PTR -176[rbp+rax*4] sub DWORD PTR -196[rbp], eax .L3: mov eax, DWORD PTR -180[rbp] cdqe mov eax, DWORD PTR -176[rbp+rax*4] cmp DWORD PTR -196[rbp], eax jge .L4 cmp DWORD PTR -196[rbp], 0 jle .L2 add DWORD PTR -180[rbp], 1 .L2: cmp DWORD PTR -196[rbp], 0 jg .L3 nop mov rax, QWORD PTR -8[rbp] xor rax, QWORD PTR fs:40 je .L6 call __stack_chk_fail@PLT .L6: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .section .rodata .align 3 .LC0: .string "m" .align 3 .LC1: .string "cm" .align 3 .LC2: .string "d" .align 3 .LC3: .string "cd" .align 3 .LC4: .string "c" .align 3 .LC5: .string "xc" .align 3 .LC6: .string "l" .align 3 .LC7: .string "xl" .align 3 .LC8: .string "x" .align 3 .LC9: .string "ix" .align 3 .LC10: .string "v" .align 3 .LC11: .string "iv" .align 3 .LC12: .string "i" .text .data .align 3 .LC15: .dword .LC0 .dword .LC1 .dword .LC2 .dword .LC3 .dword .LC4 .dword .LC5 .dword .LC6 .dword .LC7 .dword .LC8 .dword .LC9 .dword .LC10 .dword .LC11 .dword .LC12 .section .rodata .align 3 .LC14: .word 1000 .word 900 .word 500 .word 400 .word 100 .word 90 .word 50 .word 40 .word 10 .word 9 .word 5 .word 4 .word 1 .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-208 sd ra,200(sp) sd s0,192(sp) addi s0,sp,208 mv a5,a0 sd a1,-208(s0) sw a5,-196(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) lla a4,.LC15 addi a5,s0,-128 mv a3,a4 li a4,104 mv a2,a4 mv a1,a3 mv a0,a5 call memcpy@plt lla a5,.LC14 ld a6,0(a5) ld a0,8(a5) ld a1,16(a5) ld a2,24(a5) ld a3,32(a5) ld a4,40(a5) sd a6,-184(s0) sd a0,-176(s0) sd a1,-168(s0) sd a2,-160(s0) sd a3,-152(s0) sd a4,-144(s0) lw a5,48(a5) sw a5,-136(s0) sw zero,-188(s0) ld a5,-208(s0) sb zero,0(a5) j .L2 .L4: lw a5,-188(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a5,-112(a5) mv a1,a5 ld a0,-208(s0) call strcat@plt lw a5,-188(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a5,-168(a5) lw a4,-196(s0) subw a5,a4,a5 sw a5,-196(s0) .L3: lw a5,-188(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a4,-168(a5) lw a5,-196(s0) sext.w a5,a5 bge a5,a4,.L4 lw a5,-196(s0) sext.w a5,a5 blez a5,.L2 lw a5,-188(s0) addiw a5,a5,1 sw a5,-188(s0) .L2: lw a5,-196(s0) sext.w a5,a5 bgtz a5,.L3 nop la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L6 call __stack_chk_fail@plt .L6: ld ra,200(sp) ld s0,192(sp) addi sp,sp,208 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem91/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi cmp DWORD PTR -28[rbp], 1 jg .L2 mov eax, -1 jmp .L3 .L2: mov DWORD PTR -12[rbp], 2147483647 mov DWORD PTR -8[rbp], 2147483647 mov DWORD PTR -4[rbp], 0 jmp .L4 .L7: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax jle .L5 mov eax, DWORD PTR -12[rbp] mov DWORD PTR -8[rbp], eax mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -12[rbp], eax jmp .L6 .L5: mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -8[rbp], eax jle .L6 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] cmp DWORD PTR -12[rbp], eax je .L6 mov eax, DWORD PTR -4[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -8[rbp], eax .L6: add DWORD PTR -4[rbp], 1 .L4: mov eax, DWORD PTR -4[rbp] cmp eax, DWORD PTR -28[rbp] jl .L7 cmp DWORD PTR -8[rbp], 2147483647 jne .L8 mov eax, -1 jmp .L3 .L8: mov eax, DWORD PTR -8[rbp] .L3: pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd s0,40(sp) addi s0,sp,48 sd a0,-40(s0) mv a5,a1 sw a5,-44(s0) lw a5,-44(s0) sext.w a4,a5 li a5,1 bgt a4,a5,.L2 li a5,-1 j .L3 .L2: li a5,-2147483648 xori a5,a5,-1 sw a5,-28(s0) li a5,-2147483648 xori a5,a5,-1 sw a5,-24(s0) sw zero,-20(s0) j .L4 .L7: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L5 lw a5,-28(s0) sw a5,-24(s0) lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-28(s0) j .L6 .L5: lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-24(s0) sext.w a5,a5 ble a5,a4,.L6 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,0(a5) lw a5,-28(s0) sext.w a5,a5 beq a5,a4,.L6 lw a5,-20(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-24(s0) .L6: lw a5,-20(s0) addiw a5,a5,1 sw a5,-20(s0) .L4: lw a4,-20(s0) lw a5,-44(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L7 lw a5,-24(s0) sext.w a4,a5 li a5,-2147483648 xori a5,a5,-1 bne a4,a5,.L8 li a5,-1 j .L3 .L8: lw a5,-24(s0) .L3: mv a0,a5 ld s0,40(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem19/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 32 mov QWORD PTR -24[rbp], rdi mov QWORD PTR -32[rbp], rsi mov DWORD PTR -16[rbp], 0 mov rax, QWORD PTR -24[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -8[rbp], eax mov rax, QWORD PTR -32[rbp] mov rdi, rax call strlen@PLT mov DWORD PTR -4[rbp], eax cmp DWORD PTR -8[rbp], 0 jne .L2 mov eax, 0 jmp .L3 .L2: mov DWORD PTR -12[rbp], 0 jmp .L4 .L6: mov eax, DWORD PTR -4[rbp] movsx rdx, eax mov eax, DWORD PTR -12[rbp] movsx rcx, eax mov rax, QWORD PTR -24[rbp] add rcx, rax mov rax, QWORD PTR -32[rbp] mov rsi, rax mov rdi, rcx call strncmp@PLT test eax, eax jne .L5 add DWORD PTR -16[rbp], 1 .L5: add DWORD PTR -12[rbp], 1 .L4: mov eax, DWORD PTR -8[rbp] sub eax, DWORD PTR -4[rbp] cmp DWORD PTR -12[rbp], eax jle .L6 mov eax, DWORD PTR -16[rbp] .L3: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-48 sd ra,40(sp) sd s0,32(sp) addi s0,sp,48 sd a0,-40(s0) sd a1,-48(s0) sw zero,-32(s0) ld a0,-40(s0) call strlen@plt mv a5,a0 sw a5,-24(s0) ld a0,-48(s0) call strlen@plt mv a5,a0 sw a5,-20(s0) lw a5,-24(s0) sext.w a5,a5 bnez a5,.L2 li a5,0 j .L3 .L2: sw zero,-28(s0) j .L4 .L6: lw a5,-28(s0) ld a4,-40(s0) add a5,a4,a5 lw a4,-20(s0) mv a2,a4 ld a1,-48(s0) mv a0,a5 call strncmp@plt mv a5,a0 bnez a5,.L5 lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L5: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L4: lw a4,-24(s0) lw a5,-20(s0) subw a5,a4,a5 sext.w a4,a5 lw a5,-28(s0) sext.w a5,a5 ble a5,a4,.L6 lw a5,-32(s0) .L3: mv a0,a5 ld ra,40(sp) ld s0,32(sp) addi sp,sp,48 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem13/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 48 mov QWORD PTR -40[rbp], rdi mov DWORD PTR -44[rbp], esi lea rax, .LC0[rip] mov QWORD PTR -8[rbp], rax mov DWORD PTR -20[rbp], 0 mov DWORD PTR -16[rbp], 0 jmp .L2 .L4: mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov rdi, rax call strlen@PLT mov DWORD PTR -12[rbp], eax mov eax, DWORD PTR -12[rbp] cmp eax, DWORD PTR -20[rbp] jle .L3 mov eax, DWORD PTR -16[rbp] cdqe lea rdx, 0[0+rax*8] mov rax, QWORD PTR -40[rbp] add rax, rdx mov rax, QWORD PTR [rax] mov QWORD PTR -8[rbp], rax mov eax, DWORD PTR -12[rbp] mov DWORD PTR -20[rbp], eax .L3: add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -16[rbp] cmp eax, DWORD PTR -44[rbp] jl .L4 mov rax, QWORD PTR -8[rbp] leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .section .rodata .align 3 .LC0: .string "" .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd ra,56(sp) sd s0,48(sp) addi s0,sp,64 sd a0,-56(s0) mv a5,a1 sw a5,-60(s0) lla a5,.LC0 sd a5,-24(s0) sw zero,-36(s0) sw zero,-32(s0) j .L2 .L4: lw a5,-32(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) mv a0,a5 call strlen@plt mv a5,a0 sw a5,-28(s0) lw a4,-28(s0) lw a5,-36(s0) sext.w a4,a4 sext.w a5,a5 ble a4,a5,.L3 lw a5,-32(s0) slli a5,a5,3 ld a4,-56(s0) add a5,a4,a5 ld a5,0(a5) sd a5,-24(s0) lw a5,-28(s0) sw a5,-36(s0) .L3: lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a4,-32(s0) lw a5,-60(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L4 ld a5,-24(s0) mv a0,a5 ld ra,56(sp) ld s0,48(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem121/code.c
.file "code.c" .intel_syntax noprefix .text .globl func0 .type func0, @function func0: .LFB6: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 mov QWORD PTR -24[rbp], rdi mov DWORD PTR -28[rbp], esi mov DWORD PTR -32[rbp], edx mov QWORD PTR -40[rbp], rcx mov DWORD PTR -16[rbp], 0 jmp .L2 .L6: mov DWORD PTR -12[rbp], 0 jmp .L3 .L5: mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR [rax] mov eax, DWORD PTR -12[rbp] cdqe add rax, 1 lea rcx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rcx mov eax, DWORD PTR [rax] cmp edx, eax jle .L4 mov eax, DWORD PTR -12[rbp] cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov eax, DWORD PTR [rax] mov DWORD PTR -4[rbp], eax mov eax, DWORD PTR -12[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR -12[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -24[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax mov eax, DWORD PTR -12[rbp] cdqe add rax, 1 lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rdx, rax mov eax, DWORD PTR -4[rbp] mov DWORD PTR [rdx], eax .L4: add DWORD PTR -12[rbp], 1 .L3: mov eax, DWORD PTR -28[rbp] sub eax, DWORD PTR -16[rbp] sub eax, 1 cmp DWORD PTR -12[rbp], eax jl .L5 add DWORD PTR -16[rbp], 1 .L2: mov eax, DWORD PTR -28[rbp] sub eax, 1 cmp DWORD PTR -16[rbp], eax jl .L6 mov DWORD PTR -8[rbp], 0 jmp .L7 .L8: mov eax, DWORD PTR -28[rbp] sub eax, DWORD PTR -32[rbp] mov edx, eax mov eax, DWORD PTR -8[rbp] add eax, edx cdqe lea rdx, 0[0+rax*4] mov rax, QWORD PTR -24[rbp] add rax, rdx mov edx, DWORD PTR -8[rbp] movsx rdx, edx lea rcx, 0[0+rdx*4] mov rdx, QWORD PTR -40[rbp] add rdx, rcx mov eax, DWORD PTR [rax] mov DWORD PTR [rdx], eax add DWORD PTR -8[rbp], 1 .L7: mov eax, DWORD PTR -8[rbp] cmp eax, DWORD PTR -32[rbp] jl .L8 nop nop pop rbp .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE6: .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-64 sd s0,56(sp) addi s0,sp,64 sd a0,-40(s0) mv a5,a1 mv a4,a2 sd a3,-56(s0) sw a5,-44(s0) mv a5,a4 sw a5,-48(s0) sw zero,-32(s0) j .L2 .L6: sw zero,-28(s0) j .L3 .L5: lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a3,0(a5) lw a5,-28(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) mv a4,a3 ble a4,a5,.L4 lw a5,-28(s0) slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a5,0(a5) sw a5,-20(s0) lw a5,-28(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-40(s0) add a4,a4,a5 lw a5,-28(s0) slli a5,a5,2 ld a3,-40(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-28(s0) addi a5,a5,1 slli a5,a5,2 ld a4,-40(s0) add a5,a4,a5 lw a4,-20(s0) sw a4,0(a5) .L4: lw a5,-28(s0) addiw a5,a5,1 sw a5,-28(s0) .L3: lw a4,-44(s0) lw a5,-32(s0) subw a5,a4,a5 sext.w a5,a5 addiw a5,a5,-1 sext.w a4,a5 lw a5,-28(s0) sext.w a5,a5 blt a5,a4,.L5 lw a5,-32(s0) addiw a5,a5,1 sw a5,-32(s0) .L2: lw a5,-44(s0) addiw a5,a5,-1 sext.w a4,a5 lw a5,-32(s0) sext.w a5,a5 blt a5,a4,.L6 sw zero,-24(s0) j .L7 .L8: lw a4,-44(s0) lw a5,-48(s0) subw a5,a4,a5 sext.w a5,a5 lw a4,-24(s0) addw a5,a4,a5 sext.w a5,a5 slli a5,a5,2 ld a4,-40(s0) add a4,a4,a5 lw a5,-24(s0) slli a5,a5,2 ld a3,-56(s0) add a5,a3,a5 lw a4,0(a4) sw a4,0(a5) lw a5,-24(s0) addiw a5,a5,1 sw a5,-24(s0) .L7: lw a4,-24(s0) lw a5,-48(s0) sext.w a4,a4 sext.w a5,a5 blt a4,a5,.L8 nop nop ld s0,56(sp) addi sp,sp,64 jr ra .size func0, .-func0 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits
eval/problem20/code.c
.file "code.c" .intel_syntax noprefix .text .section .rodata .LC0: .string "zero" .LC1: .string "one" .LC2: .string "two" .LC3: .string "three" .LC4: .string "four" .LC5: .string "five" .LC6: .string "six" .LC7: .string "seven" .LC8: .string "eight" .LC9: .string "nine" .text .globl func0 .type func0, @function func0: .LFB0: .cfi_startproc endbr64 push rbp .cfi_def_cfa_offset 16 .cfi_offset 6, -16 mov rbp, rsp .cfi_def_cfa_register 6 sub rsp, 176 mov QWORD PTR -168[rbp], rdi mov rax, QWORD PTR fs:40 mov QWORD PTR -8[rbp], rax xor eax, eax mov QWORD PTR -144[rbp], 0 mov QWORD PTR -136[rbp], 0 mov QWORD PTR -128[rbp], 0 mov QWORD PTR -120[rbp], 0 mov QWORD PTR -112[rbp], 0 lea rax, .LC0[rip] mov QWORD PTR -96[rbp], rax lea rax, .LC1[rip] mov QWORD PTR -88[rbp], rax lea rax, .LC2[rip] mov QWORD PTR -80[rbp], rax lea rax, .LC3[rip] mov QWORD PTR -72[rbp], rax lea rax, .LC4[rip] mov QWORD PTR -64[rbp], rax lea rax, .LC5[rip] mov QWORD PTR -56[rbp], rax lea rax, .LC6[rip] mov QWORD PTR -48[rbp], rax lea rax, .LC7[rip] mov QWORD PTR -40[rbp], rax lea rax, .LC8[rip] mov QWORD PTR -32[rbp], rax lea rax, .LC9[rip] mov QWORD PTR -24[rbp], rax mov DWORD PTR -160[rbp], 0 mov rax, QWORD PTR -168[rbp] movzx eax, BYTE PTR [rax] test al, al je .L2 .L10: mov DWORD PTR -156[rbp], 0 jmp .L3 .L5: mov eax, DWORD PTR -156[rbp] movsx rdx, eax mov rax, QWORD PTR -168[rbp] add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -156[rbp] cdqe mov BYTE PTR -14[rbp+rax], dl add DWORD PTR -156[rbp], 1 .L3: mov eax, DWORD PTR -156[rbp] movsx rdx, eax mov rax, QWORD PTR -168[rbp] add rax, rdx movzx eax, BYTE PTR [rax] cmp al, 32 je .L4 mov eax, DWORD PTR -156[rbp] movsx rdx, eax mov rax, QWORD PTR -168[rbp] add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L5 .L4: mov eax, DWORD PTR -156[rbp] cdqe mov BYTE PTR -14[rbp+rax], 0 mov DWORD PTR -152[rbp], 0 jmp .L6 .L9: mov eax, DWORD PTR -152[rbp] cdqe mov rdx, QWORD PTR -96[rbp+rax*8] lea rax, -14[rbp] mov rsi, rdx mov rdi, rax call strcmp@PLT test eax, eax jne .L7 mov eax, DWORD PTR -152[rbp] cdqe mov eax, DWORD PTR -144[rbp+rax*4] lea edx, 1[rax] mov eax, DWORD PTR -152[rbp] cdqe mov DWORD PTR -144[rbp+rax*4], edx jmp .L8 .L7: add DWORD PTR -152[rbp], 1 .L6: cmp DWORD PTR -152[rbp], 9 jle .L9 .L8: mov eax, DWORD PTR -156[rbp] cdqe add rax, 1 add QWORD PTR -168[rbp], rax mov rax, QWORD PTR -168[rbp] sub rax, 1 movzx eax, BYTE PTR [rax] test al, al jne .L10 .L2: mov DWORD PTR -156[rbp], 0 jmp .L11 .L16: mov DWORD PTR -152[rbp], 0 jmp .L12 .L15: mov DWORD PTR -148[rbp], 0 jmp .L13 .L14: mov eax, DWORD PTR -156[rbp] cdqe mov rdx, QWORD PTR -96[rbp+rax*8] mov eax, DWORD PTR -148[rbp] cdqe add rax, rdx movzx edx, BYTE PTR [rax] mov eax, DWORD PTR -160[rbp] cdqe lea rcx, out.2502[rip] mov BYTE PTR [rax+rcx], dl add DWORD PTR -148[rbp], 1 add DWORD PTR -160[rbp], 1 .L13: mov eax, DWORD PTR -156[rbp] cdqe mov rdx, QWORD PTR -96[rbp+rax*8] mov eax, DWORD PTR -148[rbp] cdqe add rax, rdx movzx eax, BYTE PTR [rax] test al, al jne .L14 mov eax, DWORD PTR -160[rbp] lea edx, 1[rax] mov DWORD PTR -160[rbp], edx cdqe lea rdx, out.2502[rip] mov BYTE PTR [rax+rdx], 32 add DWORD PTR -152[rbp], 1 .L12: mov eax, DWORD PTR -156[rbp] cdqe mov eax, DWORD PTR -144[rbp+rax*4] cmp DWORD PTR -152[rbp], eax jl .L15 add DWORD PTR -156[rbp], 1 .L11: cmp DWORD PTR -156[rbp], 9 jle .L16 cmp DWORD PTR -160[rbp], 0 jle .L17 mov eax, DWORD PTR -160[rbp] sub eax, 1 cdqe lea rdx, out.2502[rip] mov BYTE PTR [rax+rdx], 0 jmp .L18 .L17: mov BYTE PTR out.2502[rip], 0 .L18: lea rax, out.2502[rip] mov rsi, QWORD PTR -8[rbp] xor rsi, QWORD PTR fs:40 je .L20 call __stack_chk_fail@PLT .L20: leave .cfi_def_cfa 7, 8 ret .cfi_endproc .LFE0: .size func0, .-func0 .local out.2502 .comm out.2502,1000,32 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0" .section .note.GNU-stack,"",@progbits .section .note.gnu.property,"a" .align 8 .long 1f - 0f .long 4f - 1f .long 5 0: .string "GNU" 1: .align 8 .long 0xc0000002 .long 3f - 2f 2: .long 0x3 3: .align 8 4:
.file "code.c" .option pic .section .rodata .align 3 .LC0: .string "zero" .align 3 .LC1: .string "one" .align 3 .LC2: .string "two" .align 3 .LC3: .string "three" .align 3 .LC4: .string "four" .align 3 .LC5: .string "five" .align 3 .LC6: .string "six" .align 3 .LC7: .string "seven" .align 3 .LC8: .string "eight" .align 3 .LC9: .string "nine" .text .data .align 3 .LC11: .dword .LC0 .dword .LC1 .dword .LC2 .dword .LC3 .dword .LC4 .dword .LC5 .dword .LC6 .dword .LC7 .dword .LC8 .dword .LC9 .text .align 1 .globl func0 .type func0, @function func0: addi sp,sp,-192 sd ra,184(sp) sd s0,176(sp) addi s0,sp,192 sd a0,-184(s0) la a5,__stack_chk_guard ld a5,0(a5) sd a5,-24(s0) sd zero,-152(s0) sd zero,-144(s0) sd zero,-136(s0) sd zero,-128(s0) sd zero,-120(s0) lla a5,.LC11 ld t3,0(a5) ld t1,8(a5) ld a7,16(a5) ld a6,24(a5) ld a0,32(a5) ld a1,40(a5) ld a2,48(a5) ld a3,56(a5) ld a4,64(a5) ld a5,72(a5) sd t3,-112(s0) sd t1,-104(s0) sd a7,-96(s0) sd a6,-88(s0) sd a0,-80(s0) sd a1,-72(s0) sd a2,-64(s0) sd a3,-56(s0) sd a4,-48(s0) sd a5,-40(s0) sw zero,-168(s0) ld a5,-184(s0) lbu a5,0(a5) beqz a5,.L2 .L10: sw zero,-164(s0) j .L3 .L5: lw a5,-164(s0) ld a4,-184(s0) add a5,a4,a5 lbu a4,0(a5) lw a5,-164(s0) addi a3,s0,-16 add a5,a3,a5 sb a4,-16(a5) lw a5,-164(s0) addiw a5,a5,1 sw a5,-164(s0) .L3: lw a5,-164(s0) ld a4,-184(s0) add a5,a4,a5 lbu a5,0(a5) mv a4,a5 li a5,32 beq a4,a5,.L4 lw a5,-164(s0) ld a4,-184(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L5 .L4: lw a5,-164(s0) addi a4,s0,-16 add a5,a4,a5 sb zero,-16(a5) sw zero,-160(s0) j .L6 .L9: lw a5,-160(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a4,-96(a5) addi a5,s0,-32 mv a1,a4 mv a0,a5 call strcmp@plt mv a5,a0 bnez a5,.L7 lw a5,-160(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a5,-136(a5) addiw a5,a5,1 sext.w a4,a5 lw a5,-160(s0) slli a5,a5,2 addi a3,s0,-16 add a5,a3,a5 sw a4,-136(a5) j .L8 .L7: lw a5,-160(s0) addiw a5,a5,1 sw a5,-160(s0) .L6: lw a5,-160(s0) sext.w a4,a5 li a5,9 ble a4,a5,.L9 .L8: lw a5,-164(s0) addi a5,a5,1 ld a4,-184(s0) add a5,a4,a5 sd a5,-184(s0) ld a5,-184(s0) addi a5,a5,-1 lbu a5,0(a5) bnez a5,.L10 .L2: sw zero,-164(s0) j .L11 .L16: sw zero,-160(s0) j .L12 .L15: sw zero,-156(s0) j .L13 .L14: lw a5,-164(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a4,-96(a5) lw a5,-156(s0) add a5,a4,a5 lbu a4,0(a5) lla a3,out.2090 lw a5,-168(s0) add a5,a3,a5 sb a4,0(a5) lw a5,-156(s0) addiw a5,a5,1 sw a5,-156(s0) lw a5,-168(s0) addiw a5,a5,1 sw a5,-168(s0) .L13: lw a5,-164(s0) slli a5,a5,3 addi a4,s0,-16 add a5,a4,a5 ld a4,-96(a5) lw a5,-156(s0) add a5,a4,a5 lbu a5,0(a5) bnez a5,.L14 lw a5,-168(s0) addiw a4,a5,1 sw a4,-168(s0) lla a4,out.2090 add a5,a4,a5 li a4,32 sb a4,0(a5) lw a5,-160(s0) addiw a5,a5,1 sw a5,-160(s0) .L12: lw a5,-164(s0) slli a5,a5,2 addi a4,s0,-16 add a5,a4,a5 lw a4,-136(a5) lw a5,-160(s0) sext.w a5,a5 blt a5,a4,.L15 lw a5,-164(s0) addiw a5,a5,1 sw a5,-164(s0) .L11: lw a5,-164(s0) sext.w a4,a5 li a5,9 ble a4,a5,.L16 lw a5,-168(s0) sext.w a5,a5 blez a5,.L17 lw a5,-168(s0) addiw a5,a5,-1 sext.w a5,a5 lla a4,out.2090 add a5,a4,a5 sb zero,0(a5) j .L18 .L17: lla a5,out.2090 sb zero,0(a5) .L18: lla a5,out.2090 mv a3,a5 la a5,__stack_chk_guard ld a4,-24(s0) ld a5,0(a5) beq a4,a5,.L20 call __stack_chk_fail@plt .L20: mv a0,a3 ld ra,184(sp) ld s0,176(sp) addi sp,sp,192 jr ra .size func0, .-func0 .local out.2090 .comm out.2090,1000,8 .ident "GCC: (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0" .section .note.GNU-stack,"",@progbits