Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; Disassembly of file: main.o
- ; Sat Nov 11 11:24:23 2023
- ; Mode: 64 bits
- ; Syntax: YASM/NASM
- ; Instruction set: SSE2, x64
- default rel
- global main: function
- extern __mingw_vfscanf ; near
- extern __mingw_vfprintf ; near
- extern __main ; near
- extern __imp___acrt_iob_func ; qword
- SECTION .text align=16 execute ; section number 1, code
- .text: ; Local function
- printf: push rsi ; 0000 _ 56
- push rbx ; 0001 _ 53
- mov rbx, rcx ; 0002 _ 48: 89. CB
- mov ecx, 1 ; 0005 _ B9, 00000001
- sub rsp, 56 ; 000A _ 48: 83. EC, 38
- lea rsi, [rsp+58H] ; 000E _ 48: 8D. 74 24, 58
- mov qword [rsp+58H], rdx ; 0013 _ 48: 89. 54 24, 58
- mov qword [rsp+60H], r8 ; 0018 _ 4C: 89. 44 24, 60
- mov qword [rsp+68H], r9 ; 001D _ 4C: 89. 4C 24, 68
- mov qword [rsp+28H], rsi ; 0022 _ 48: 89. 74 24, 28
- call near [rel __imp___acrt_iob_func] ; 0027 _ FF. 15, 00000000(rel)
- mov r8, rsi ; 002D _ 49: 89. F0
- mov rdx, rbx ; 0030 _ 48: 89. DA
- mov rcx, rax ; 0033 _ 48: 89. C1
- call __mingw_vfprintf ; 0036 _ E8, 00000000(rel)
- add rsp, 56 ; 003B _ 48: 83. C4, 38
- pop rbx ; 003F _ 5B
- pop rsi ; 0040 _ 5E
- ret ; 0041 _ C3
- ; Filling space: 0EH
- ; Filler type: Multi-byte NOP
- ; db 66H, 66H, 2EH, 0FH, 1FH, 84H, 00H, 00H
- ; db 00H, 00H, 00H, 0FH, 1FH, 00H
- ALIGN 16
- scanf.constprop.0:; Local function
- push rbx ; 0050 _ 53
- xor ecx, ecx ; 0051 _ 31. C9
- sub rsp, 48 ; 0053 _ 48: 83. EC, 30
- lea rbx, [rsp+48H] ; 0057 _ 48: 8D. 5C 24, 48
- mov qword [rsp+48H], rdx ; 005C _ 48: 89. 54 24, 48
- mov qword [rsp+50H], r8 ; 0061 _ 4C: 89. 44 24, 50
- mov qword [rsp+58H], r9 ; 0066 _ 4C: 89. 4C 24, 58
- mov qword [rsp+28H], rbx ; 006B _ 48: 89. 5C 24, 28
- call near [rel __imp___acrt_iob_func] ; 0070 _ FF. 15, 00000000(rel)
- mov r8, rbx ; 0076 _ 49: 89. D8
- lea rdx, [rel ?_001] ; 0079 _ 48: 8D. 15, 00000000(rel)
- mov rcx, rax ; 0080 _ 48: 89. C1
- call __mingw_vfscanf ; 0083 _ E8, 00000000(rel)
- add rsp, 48 ; 0088 _ 48: 83. C4, 30
- pop rbx ; 008C _ 5B
- ret ; 008D _ C3
- nop ; 008E _ 90
- nop ; 008F _ 90
- SECTION .data align=16 noexecute ; section number 2, data
- SECTION .bss align=16 noexecute ; section number 3, bss
- SECTION .rdata align=16 noexecute ; section number 4, const
- ?_001: ; byte
- db 25H, 64H, 00H ; 0000 _ %d.
- ?_002: ; byte
- db 49H, 6EH, 74H, 72H, 6FH, 64H, 75H, 7AH ; 0003 _ Introduz
- db 63H, 61H, 20H, 75H, 6EH, 20H, 6EH, 0C3H ; 000B _ ca un n.
- db 0BAH, 6DH, 65H, 72H, 6FH, 3AH, 20H, 00H ; 0013 _ .mero: .
- db 00H, 00H, 00H, 00H, 00H ; 001B _ .....
- ?_003: ; byte
- db 45H, 6CH, 20H, 6EH, 0C3H, 0BAH, 6DH, 65H ; 0020 _ El n..me
- db 72H, 6FH, 20H, 64H, 65H, 62H, 65H, 20H ; 0028 _ ro debe
- db 73H, 65H, 72H, 20H, 70H, 6FH, 73H, 69H ; 0030 _ ser posi
- db 74H, 69H, 76H, 6FH, 2EH, 0AH, 00H ; 0038 _ tivo...
- ?_004: ; byte
- db 45H, 6CH, 20H, 66H, 61H, 63H, 74H, 6FH ; 003F _ El facto
- db 72H, 69H, 61H, 6CH, 20H, 64H, 65H, 20H ; 0047 _ rial de
- db 25H, 64H, 20H, 65H, 73H, 3AH, 20H, 25H ; 004F _ %d es: %
- db 2EH, 30H, 66H, 0AH, 00H, 00H, 00H, 00H ; 0057 _ .0f.....
- db 00H ; 005F _ .
- ?_005: dq 3FF0000000000000H ; 0060 _ 1.0
- dq 0000000000000000H ; 0068 _ 0.0
- SECTION .text.startup align=16 execute ; section number 5, code
- .text.startup:; Local function
- main:
- sub rsp, 56 ; 0000 _ 48: 83. EC, 38
- call __main ; 0004 _ E8, 00000000(rel)
- lea rcx, [rel ?_002] ; 0009 _ 48: 8D. 0D, 00000003(rel)
- call printf ; 0010 _ E8, 00000000(rel)
- lea rdx, [rsp+2CH] ; 0015 _ 48: 8D. 54 24, 2C
- lea rcx, [rel ?_001] ; 001A _ 48: 8D. 0D, 00000000(rel)
- call scanf.constprop.0 ; 0021 _ E8, 00000050(rel)
- mov edx, dword [rsp+2CH] ; 0026 _ 8B. 54 24, 2C
- test edx, edx ; 002A _ 85. D2
- js ?_009 ; 002C _ 78, 3B
- movsd xmm2, qword [rel ?_005] ; 002E _ F2: 0F 10. 15, 00000060(rel)
- mov eax, edx ; 0036 _ 89. D0
- jz ?_007 ; 0038 _ 74, 17
- ; Filling space: 6H
- ; Filler type: Multi-byte NOP
- ; db 66H, 0FH, 1FH, 44H, 00H, 00H
- ALIGN 8
- ?_006: pxor xmm0, xmm0 ; 0040 _ 66: 0F EF. C0
- cvtsi2sd xmm0, eax ; 0044 _ F2: 0F 2A. C0
- mulsd xmm2, xmm0 ; 0048 _ F2: 0F 59. D0
- sub eax, 1 ; 004C _ 83. E8, 01
- jnz ?_006 ; 004F _ 75, EF
- ?_007: movq r8, xmm2 ; 0051 _ 66 49: 0F 7E. D0
- lea rcx, [rel ?_004] ; 0056 _ 48: 8D. 0D, 0000003F(rel)
- call printf ; 005D _ E8, 00000000(rel)
- xor eax, eax ; 0062 _ 31. C0
- ?_008: add rsp, 56 ; 0064 _ 48: 83. C4, 38
- ret ; 0068 _ C3
- ?_009: ; Local function
- lea rcx, [rel ?_003] ; 0069 _ 48: 8D. 0D, 00000020(rel)
- call printf ; 0070 _ E8, 00000000(rel)
- mov eax, 1 ; 0075 _ B8, 00000001
- jmp ?_008 ; 007A _ EB, E8
- nop ; 007C _ 90
- nop ; 007D _ 90
- nop ; 007E _ 90
- nop ; 007F _ 90
- SECTION .rdata$zzz align=16 noexecute ; section number 6, const
- db 47H, 43H, 43H, 3AH, 20H, 28H, 52H, 65H ; 0000 _ GCC: (Re
- db 76H, 36H, 2CH, 20H, 42H, 75H, 69H, 6CH ; 0008 _ v6, Buil
- db 74H, 20H, 62H, 79H, 20H, 4DH, 53H, 59H ; 0010 _ t by MSY
- db 53H, 32H, 20H, 70H, 72H, 6FH, 6AH, 65H ; 0018 _ S2 proje
- db 63H, 74H, 29H, 20H, 31H, 33H, 2EH, 31H ; 0020 _ ct) 13.1
- db 2EH, 30H, 00H, 00H, 00H, 00H, 00H, 00H ; 0028 _ .0......
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement