Created
January 4, 2014 21:09
-
-
Save emoon/8260765 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 .section __TEXT,__text,regular,pure_instructions | |
2 .globl _main | |
3 .align 4, 0x90 | |
4 _main: ## @main | |
5 .cfi_startproc | |
6 ## BB#0: | |
7 push RBP | |
8 Ltmp2: | |
9 .cfi_def_cfa_offset 16 | |
10 Ltmp3: | |
11 .cfi_offset rbp, -16 | |
12 mov RBP, RSP | |
13 Ltmp4: | |
14 .cfi_def_cfa_register rbp | |
15 mov RAX, QWORD PTR [RIP + _foo@GOTPCREL] | |
16 movsx EAX, WORD PTR [RAX] | |
17 mov ESI, EAX | |
18 sar ESI, 31 | |
19 shr ESI, 24 | |
20 add ESI, EAX | |
21 sar ESI, 8 | |
22 lea RDI, QWORD PTR [RIP + L_.str] | |
23 xor AL, AL | |
24 call _printf | |
25 xor EAX, EAX | |
26 pop RBP | |
27 ret | |
28 .cfi_endproc | |
29 | |
30 .section __TEXT,__cstring,cstring_literals | |
31 L_.str: ## @.str | |
32 .asciz "%d\n" | |
33 | |
34 | |
35 .subsections_via_symbols | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment