Create
Edit
Diff
FrontPage
Index
Search
Changes
Login
はじめてのひき - FizzBuzzAsm_x86
Title
! Version % gcc -m32 -v Using built-in specs. Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Debian 4.3.3-5' --with-bugurl=file:///usr/share/doc/gcc-4.3/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --enable-nls --with-gxx-include-dir=/usr/include/c++/4.3 --program-suffix=-4.3 --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --enable-mpfr --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu Thread model: posix gcc version 4.3.3 (Debian 4.3.3-5) ! Optimized fizzbuzz.o: file format elf32-i386 Disassembly of section .text: 00000000 <main>: 0: 8d 4c 24 04 lea 0x4(%esp),%ecx 4: 83 e4 f0 and $0xfffffff0,%esp 7: ff 71 fc pushl -0x4(%ecx) a: 55 push %ebp b: 89 e5 mov %esp,%ebp d: 57 push %edi e: 56 push %esi f: 53 push %ebx 10: 51 push %ecx 11: 83 ec 08 sub $0x8,%esp 14: bb 01 00 00 00 mov $0x1,%ebx 19: be 89 88 88 88 mov $0x88888889,%esi 1e: bf 67 66 66 66 mov $0x66666667,%edi 23: 89 d8 mov %ebx,%eax 25: f7 ee imul %esi 27: 01 da add %ebx,%edx 29: c1 fa 03 sar $0x3,%edx 2c: 89 d8 mov %ebx,%eax 2e: c1 f8 1f sar $0x1f,%eax 31: 29 c2 sub %eax,%edx 33: 89 d0 mov %edx,%eax 35: c1 e0 04 shl $0x4,%eax 38: 29 d0 sub %edx,%eax 3a: 39 c3 cmp %eax,%ebx 3c: 75 0e jne 4c <main+0x4c> 3e: c7 04 24 00 00 00 00 movl $0x0,(%esp) 41: R_386_32 .rodata.str1.1 45: e8 fc ff ff ff call 46 <main+0x46> 46: R_386_PC32 puts 4a: eb 57 jmp a3 <main+0xa3> 4c: 89 d8 mov %ebx,%eax 4e: f7 ef imul %edi 50: d1 fa sar %edx 52: 89 d8 mov %ebx,%eax 54: c1 f8 1f sar $0x1f,%eax 57: 29 c2 sub %eax,%edx 59: 8d 14 92 lea (%edx,%edx,4),%edx 5c: 39 d3 cmp %edx,%ebx 5e: 75 0e jne 6e <main+0x6e> 60: c7 04 24 09 00 00 00 movl $0x9,(%esp) 63: R_386_32 .rodata.str1.1 67: e8 fc ff ff ff call 68 <main+0x68> 68: R_386_PC32 puts 6c: eb 35 jmp a3 <main+0xa3> 6e: ba 56 55 55 55 mov $0x55555556,%edx 73: 89 d8 mov %ebx,%eax 75: f7 ea imul %edx 77: 89 d8 mov %ebx,%eax 79: c1 f8 1f sar $0x1f,%eax 7c: 29 c2 sub %eax,%edx 7e: 8d 14 52 lea (%edx,%edx,2),%edx 81: 39 d3 cmp %edx,%ebx 83: 75 0e jne 93 <main+0x93> 85: c7 04 24 0e 00 00 00 movl $0xe,(%esp) 88: R_386_32 .rodata.str1.1 8c: e8 fc ff ff ff call 8d <main+0x8d> 8d: R_386_PC32 puts 91: eb 10 jmp a3 <main+0xa3> 93: 89 5c 24 04 mov %ebx,0x4(%esp) 97: c7 04 24 13 00 00 00 movl $0x13,(%esp) 9a: R_386_32 .rodata.str1.1 9e: e8 fc ff ff ff call 9f <main+0x9f> 9f: R_386_PC32 printf a3: 83 c3 01 add $0x1,%ebx a6: 83 fb 65 cmp $0x65,%ebx a9: 0f 85 74 ff ff ff jne 23 <main+0x23> af: 83 c4 08 add $0x8,%esp b2: 59 pop %ecx b3: 5b pop %ebx b4: 5e pop %esi b5: 5f pop %edi b6: 5d pop %ebp b7: 8d 61 fc lea -0x4(%ecx),%esp ba: c3 ret ! Normal fizzbuzz.o: file format elf32-i386 Disassembly of section .text: 00000000 <main>: 0: 8d 4c 24 04 lea 0x4(%esp),%ecx 4: 83 e4 f0 and $0xfffffff0,%esp 7: ff 71 fc pushl -0x4(%ecx) a: 55 push %ebp b: 89 e5 mov %esp,%ebp d: 53 push %ebx e: 51 push %ecx f: 83 ec 30 sub $0x30,%esp 12: c7 45 f4 01 00 00 00 movl $0x1,-0xc(%ebp) 19: e9 e8 00 00 00 jmp 106 <main+0x106> 1e: 8b 4d f4 mov -0xc(%ebp),%ecx 21: c7 45 d4 89 88 88 88 movl $0x88888889,-0x2c(%ebp) 28: 8b 45 d4 mov -0x2c(%ebp),%eax 2b: f7 e9 imul %ecx 2d: 8d 04 0a lea (%edx,%ecx,1),%eax 30: 89 c2 mov %eax,%edx 32: c1 fa 03 sar $0x3,%edx 35: 89 c8 mov %ecx,%eax 37: c1 f8 1f sar $0x1f,%eax 3a: 89 d3 mov %edx,%ebx 3c: 29 c3 sub %eax,%ebx 3e: 89 5d dc mov %ebx,-0x24(%ebp) 41: 8b 45 dc mov -0x24(%ebp),%eax 44: c1 e0 04 shl $0x4,%eax 47: 2b 45 dc sub -0x24(%ebp),%eax 4a: 89 ca mov %ecx,%edx 4c: 29 c2 sub %eax,%edx 4e: 89 55 dc mov %edx,-0x24(%ebp) 51: 83 7d dc 00 cmpl $0x0,-0x24(%ebp) 55: 75 11 jne 68 <main+0x68> 57: c7 04 24 00 00 00 00 movl $0x0,(%esp) 5a: R_386_32 .rodata 5e: e8 fc ff ff ff call 5f <main+0x5f> 5f: R_386_PC32 puts 63: e9 9a 00 00 00 jmp 102 <main+0x102> 68: 8b 4d f4 mov -0xc(%ebp),%ecx 6b: c7 45 d4 67 66 66 66 movl $0x66666667,-0x2c(%ebp) 72: 8b 45 d4 mov -0x2c(%ebp),%eax 75: f7 e9 imul %ecx 77: d1 fa sar %edx 79: 89 c8 mov %ecx,%eax 7b: c1 f8 1f sar $0x1f,%eax 7e: 89 d3 mov %edx,%ebx 80: 29 c3 sub %eax,%ebx 82: 89 5d e0 mov %ebx,-0x20(%ebp) 85: 8b 45 e0 mov -0x20(%ebp),%eax 88: c1 e0 02 shl $0x2,%eax 8b: 03 45 e0 add -0x20(%ebp),%eax 8e: 89 ca mov %ecx,%edx 90: 29 c2 sub %eax,%edx 92: 89 55 e0 mov %edx,-0x20(%ebp) 95: 83 7d e0 00 cmpl $0x0,-0x20(%ebp) 99: 75 0e jne a9 <main+0xa9> 9b: c7 04 24 09 00 00 00 movl $0x9,(%esp) 9e: R_386_32 .rodata a2: e8 fc ff ff ff call a3 <main+0xa3> a3: R_386_PC32 puts a7: eb 59 jmp 102 <main+0x102> a9: 8b 5d f4 mov -0xc(%ebp),%ebx ac: 89 5d d0 mov %ebx,-0x30(%ebp) af: c7 45 d4 56 55 55 55 movl $0x55555556,-0x2c(%ebp) b6: 8b 45 d4 mov -0x2c(%ebp),%eax b9: f7 6d d0 imull -0x30(%ebp) bc: 89 d1 mov %edx,%ecx be: 8b 45 d0 mov -0x30(%ebp),%eax c1: c1 f8 1f sar $0x1f,%eax c4: 89 cb mov %ecx,%ebx c6: 29 c3 sub %eax,%ebx c8: 89 5d e4 mov %ebx,-0x1c(%ebp) cb: 8b 45 e4 mov -0x1c(%ebp),%eax ce: 01 c0 add %eax,%eax d0: 03 45 e4 add -0x1c(%ebp),%eax d3: 8b 55 d0 mov -0x30(%ebp),%edx d6: 29 c2 sub %eax,%edx d8: 89 55 e4 mov %edx,-0x1c(%ebp) db: 83 7d e4 00 cmpl $0x0,-0x1c(%ebp) df: 75 0e jne ef <main+0xef> e1: c7 04 24 0e 00 00 00 movl $0xe,(%esp) e4: R_386_32 .rodata e8: e8 fc ff ff ff call e9 <main+0xe9> e9: R_386_PC32 puts ed: eb 13 jmp 102 <main+0x102> ef: 8b 45 f4 mov -0xc(%ebp),%eax f2: 89 44 24 04 mov %eax,0x4(%esp) f6: c7 04 24 13 00 00 00 movl $0x13,(%esp) f9: R_386_32 .rodata fd: e8 fc ff ff ff call fe <main+0xfe> fe: R_386_PC32 printf 102: 83 45 f4 01 addl $0x1,-0xc(%ebp) 106: 83 7d f4 64 cmpl $0x64,-0xc(%ebp) 10a: 0f 8e 0e ff ff ff jle 1e <main+0x1e> 110: 83 c4 30 add $0x30,%esp 113: 59 pop %ecx 114: 5b pop %ebx 115: 5d pop %ebp 116: 8d 61 fc lea -0x4(%ecx),%esp 119: c3 ret
人生、宇宙、すべての答え+1
:
Keyword(s) (one keyword per line)
[FizzBuzzAsm_x86]
See
TextFormattingRules
for formatting help.
See TextFormattingRules for formatting help.