Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2726 | vana | 1 | .text |
2 | .align 4 |
||
3 | |||
4 | .globl _start |
||
5 | _start: |
||
6 | #if 0 |
||
7 | pushl %ebp |
||
8 | movl %esp,%ebp |
||
9 | pushl %ebx # save ebx |
||
10 | movl 12(%ebp),%eax # eax <- systab |
||
11 | movl 24(%eax),%ebx # ebx <- systab->FirmwareVendor |
||
12 | pushl %ebx |
||
13 | movl 44(%eax),%ebx # ebx <- systab->ConOut |
||
14 | pushl %ebx |
||
15 | movl 4(%ebx),%eax # eax <- conout->OutputString |
||
16 | call *%eax |
||
17 | movl -4(%ebp),%ebx # restore ebx |
||
18 | leave |
||
19 | ret |
||
20 | |||
21 | #else |
||
22 | |||
23 | pushl %ebp |
||
24 | movl %esp,%ebp |
||
25 | pushl %ebx |
||
26 | call 0f |
||
27 | 0: popl %eax |
||
28 | addl $hello-0b,%eax |
||
29 | pushl %eax |
||
30 | movl 12(%ebp),%eax # eax <- systab |
||
31 | movl 44(%eax),%ebx # ebx <- systab->ConOut |
||
32 | pushl %ebx |
||
33 | movl 4(%ebx),%eax # eax <- conout->OutputString |
||
34 | call *%eax |
||
35 | movl -4(%ebp),%ebx |
||
36 | leave |
||
37 | ret |
||
38 | |||
39 | .section .rodata |
||
40 | .align 2 |
||
41 | hello: .byte 'h',0,'e',0,'l',0,'l',0,'o',0,'\n',0,'\r',0,0,0 |
||
42 | |||
43 | #endif |