Commit | Line | Data |
---|---|---|
e25de718 JL |
1 | .file "tester.c" |
2 | .text | |
3 | .global a | |
4 | .data | |
5 | .balign 2 | |
6 | .type a, @object | |
7 | .size a, 2 | |
8 | a: | |
9 | .short 5 | |
10 | .text | |
11 | .balign 2 | |
12 | .global foo | |
13 | .type foo, @function | |
14 | foo: | |
15 | ; start of function | |
16 | ; framesize_regs: 0 | |
17 | ; framesize_locals: 2 | |
18 | ; framesize_outgoing: 0 | |
19 | ; framesize: 2 | |
20 | ; elim ap -> fp 2 | |
21 | ; elim fp -> sp 2 | |
22 | ; saved regs:(none) | |
23 | ; start of prologue | |
24 | SUB.W #2, R1 | |
25 | ; end of prologue | |
26 | MOV.W R12, @R1 | |
27 | MOV.W @R1, R12 | |
28 | ADD.W #-2, R12 | |
29 | MOV.W @R12, R12 | |
30 | CMP.W #0, R12 { JEQ .L2 | |
31 | MOV.B #0, R12 | |
32 | BR #.L3 | |
33 | .L2: | |
34 | MOV.B #1, R12 | |
35 | .L3: | |
36 | ; start of epilogue | |
37 | ADD.W #2, R1 | |
38 | RET | |
39 | .size foo, .-foo | |
40 | .balign 2 | |
41 | .global main | |
42 | .type main, @function | |
43 | main: | |
44 | ; start of function | |
45 | ; framesize_regs: 0 | |
46 | ; framesize_locals: 0 | |
47 | ; framesize_outgoing: 0 | |
48 | ; framesize: 0 | |
49 | ; elim ap -> fp 2 | |
50 | ; elim fp -> sp 0 | |
51 | ; saved regs:(none) | |
52 | ; start of prologue | |
53 | ; end of prologue | |
54 | MOV.W #a, R12 | |
55 | CALL #foo | |
56 | ; start of epilogue | |
57 | .refsym __crt0_call_exit | |
58 | RET | |
59 | .size main, .-main | |
60 | .ident "GCC: (jozef) 7.3.2" |