Changeset 26 for trunk/hello.s


Ignore:
Timestamp:
Apr 18, 2014, 8:10:14 AM (10 years ago)
Author:
Mattia Monga
Message:

Programmi 2014

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/hello.s

    r24 r26  
    11        .file   "hello.c"
     2        .intel_syntax noprefix
    23        .section        .rodata
    34.LC0:
    4         .string "Hello world! (%d)\n"
     5        .string "mamma"
     6.LC1:
     7        .string "Ciao %d %s"
    58        .text
    69        .globl  main
     
    912.LFB0:
    1013        .cfi_startproc
    11         pushl   %ebp
     14        push    ebp
    1215        .cfi_def_cfa_offset 8
    1316        .cfi_offset 5, -8
    14         movl    %esp, %ebp
     17        mov     ebp, esp
    1518        .cfi_def_cfa_register 5
    16         andl    $-16, %esp
    17         subl    $32, %esp
    18         movl    $0, 28(%esp)
    19         jmp     .L2
    20 .L3:
    21         movl    28(%esp), %eax
    22         addl    $1, %eax
    23         movl    %eax, 4(%esp)
    24         movl    $.LC0, (%esp)
     19        and     esp, -16
     20        sub     esp, 16
     21        mov     DWORD PTR [esp+8], OFFSET FLAT:.LC0
     22        mov     DWORD PTR [esp+4], 5
     23        mov     DWORD PTR [esp], OFFSET FLAT:.LC1
    2524        call    printf
    26         movl    $1, (%esp)
    27         call    sleep
    28         addl    $1, 28(%esp)
    29 .L2:
    30         cmpl    $9, 28(%esp)
    31         jle     .L3
    32         movl    $0, (%esp)
    33         call    exit
     25#APP
     26# 8 "hello.c" 1
     27        mov eax, 0
     28# 0 "" 2
     29#NO_APP
     30        mov     eax, 0
     31        leave
     32        .cfi_restore 5
     33        .cfi_def_cfa 4, 4
     34        ret
    3435        .cfi_endproc
    3536.LFE0:
    3637        .size   main, .-main
    37         .ident  "GCC: (Debian 4.7.2-5) 4.7.2"
     38        .ident  "GCC: (Debian 4.8.2-18) 4.8.2"
    3839        .section        .note.GNU-stack,"",@progbits
Note: See TracChangeset for help on using the changeset viewer.