Commit | Line | Data |
---|---|---|
dc462216 RS |
1 | |
2 | .sdata | |
3 | shared: .4byte 11 | |
4 | ||
5 | .data | |
6 | .size unshared,16 | |
7 | unshared: | |
8 | .4byte 1 | |
9 | .4byte 2 | |
10 | .4byte 3 | |
11 | .4byte 4 | |
12 | ||
13 | .text | |
14 | .ent func | |
15 | func: | |
16 | .set mips4 | |
17 | .set noreorder | |
18 | .cpload $25 # 0000 lui gp,hi(_gp_disp) | |
19 | # 0004 addiu gp,gp,lo(_gp_disp) | |
20 | # 0008 addu gp,gp,t9 | |
21 | .set reorder | |
22 | .cprestore 8 # 000c sd gp,8(sp) | |
23 | .cpadd $4 # 0010 daddu a0,a0,gp | |
24 | li $4, 0x12345678 # 0014 lui a0,0x1234 | |
25 | # 0018 ori a0,a0,0x5678 | |
26 | la $4, shared # 001c lw a0,got(.sdata)(gp) | |
27 | # 0020 nop | |
28 | # 0024 daddiu a0,a0,lo(shared) | |
29 | la $4, unshared # 0028 lw a0,got(.data)(gp) | |
30 | # 002c nop | |
31 | # 0030 daddiu a0,a0,lo(unshared) | |
32 | la $4, end # 0034 lw a0,got(.text)(gp) | |
33 | # 0038 nop | |
34 | # 003c daddiu a0,a0,lo(end) | |
35 | j end # 0040 b end | |
36 | # 0044 nop | |
37 | jal end # 0048 ld t9,got(.text)(gp) | |
38 | # 004c nop | |
39 | # 0050 daddiu t9,t9,lo(end) | |
40 | # 0054 jalr t9 | |
41 | # 0058 nop | |
42 | # 005c ld gp,8(sp) | |
43 | lw $4, shared # 0060 ld a0,got(.sdata)(gp) | |
44 | # 0064 nop | |
45 | # 0068 daddiu a0,a0,lo(shared) | |
46 | # 006c lw a0,(a0) | |
47 | lw $4, unshared # 0070 ld a0,got(.data)(gp) | |
48 | # 0074 nop | |
49 | # 0078 daddiu a0,a0,lo(unshared) | |
50 | # 007c lw a0,(a0) | |
51 | lw $4, end # 0080 ld a0,got(.text)(gp) | |
52 | # 0084 nop | |
53 | # 0088 daddiu a0,a0,lo(end) | |
54 | # 008c lw a0,(a0) | |
55 | ld $4, shared # 0090 ld a0,got(.sdata)(gp) | |
56 | # 0094 nop | |
57 | # 0098 daddiu a0,a0,lo(shared) | |
58 | # 009c ld a0,(a0) | |
59 | ld $4, unshared # 00a0 ld a0,got(.data)(gp) | |
60 | # 00a4 nop | |
61 | # 00a8 daddiu a0,a0,lo(unshared) | |
62 | # 00ac ld a0,(a0) | |
63 | ld $4, end # 00b0 ld a0,got(.text)(gp) | |
64 | # 00b4 nop | |
65 | # 00b8 daddiu a0,a0,lo(end) | |
66 | # 00bc ld a0,(a0) | |
67 | sw $4, shared # 00c0 ld at,got(.sdata)(gp) | |
68 | # 00c4 nop | |
69 | # 00c8 daddiu at,at,lo(shared) | |
70 | # 00cc sw a0,0(at) | |
71 | sw $4, unshared # 00d0 ld at,got(.data)(gp) | |
72 | # 00d4 nop | |
73 | # 00d8 daddiu at,at,lo(unshared) | |
74 | # 00dc sw a0,0(at) | |
75 | sd $4, shared # 00e0 ld at,got(.sdata)(gp) | |
76 | # 00e4 nop | |
77 | # 00e8 daddiu at,at,lo(shared) | |
78 | # 00ec sd a0,(at) | |
79 | sd $4, unshared # 00f0 ld at,got(.data)(gp) | |
80 | # 00f4 nop | |
81 | # 00f8 daddiu at,at,lo(unshared) | |
82 | # 00fc sd a0,(at) | |
83 | ulh $4, unshared # 0100 ld at,got(.data)(gp) | |
84 | # 0104 nop | |
85 | # 0108 daddiu at,at,lo(unshared) | |
86 | # 010c lb a0,0(at) | |
87 | # 0110 lbu at,1(at) | |
88 | # 0114 sll a0,a0,8 | |
89 | # 0118 or a0,a0,at | |
90 | ush $4, unshared # 011c ld at,got(.data)(gp) | |
91 | # 0120 nop | |
92 | # 0124 daddiu at,at,lo(unshared) | |
93 | # 0128 sb a0,0(at) | |
94 | # 012c srl a0,a0,8 | |
95 | # 0130 sb a0,1(at) | |
96 | # 0134 lbu at,0(at) | |
97 | # 0138 sll a0,a0,8 | |
98 | # 013c or a0,a0,at | |
99 | ulw $4, unshared # 0140 ld at,got(.data)(gp) | |
100 | # 0144 nop | |
101 | # 0148 daddiu at,at,lo(unshared) | |
102 | # 014c lwl a0,0(at) | |
103 | # 0150 lwr a0,3(at) | |
104 | usw $4, unshared # 0154 ld at,got(.data)(gp) | |
105 | # 0158 nop | |
106 | # 015c daddiu at,at,lo(unshared) | |
107 | # 0160 swl a0,0(at) | |
108 | # 0164 swr a0,3(at) | |
109 | li.d $4, 1.0 # 0168 li a0,0xffc0 | |
110 | # 016c dsll32 a0,a0,14 | |
111 | li.d $4, 1.9 # 0170 ld at,got(.rodata)(gp) | |
112 | # 0174 ld a0,lo(F1.9)(at) | |
113 | li.d $f0, 1.0 # 0178 li at,0xffc0 | |
114 | # 017c dsll32 at,at,14 | |
115 | # 0180 dmtc1 at,$f0 | |
116 | li.d $f0, 1.9 # 0184 ld at,got(.rodata)(gp) | |
117 | # 0188 ldc1 $f0,lo(L1.9)(at) | |
118 | seq $4, $5, -100 # 018c daddiu a0,a1,100 | |
119 | # 0190 sltiu a0,a0,1 | |
120 | sne $4, $5, -100 # 0194 daddiu a0,a1,100 | |
121 | # 0198 sltu a0,zero,a0 | |
122 | move $4, $5 # 019c move a0,a1 | |
123 | ||
124 | dla $4, shared # 01a0 ld a0,got(.sdata)(gp) | |
125 | # 01a4 nop | |
126 | # 01a8 daddiu a0,a0,lo(shared) | |
127 | dla $4, unshared # 01ac ld a0,got(.data)(gp) | |
128 | # 01b0 nop | |
129 | # 01b4 daddiu a0,a0,lo(unshared) | |
130 | uld $4, unshared # 01b8 ld at,got(.data)(gp) | |
131 | # 01bc nop | |
132 | # 01c0 daddiu at,at,lo(unshared) | |
133 | # 01c4 ldl a0,0(at) | |
134 | # 01c8 ldr a0,7(at) | |
135 | usd $4, unshared # 01cc ld at,got(.data)(gp) | |
136 | # 01d0 nop | |
137 | # 01d4 daddiu at,at,lo(unshared) | |
138 | # 01d8 sdl a0,0(at) | |
139 | # 01dc sdr a0,7(at) | |
140 | ||
141 | bgt $4, 0x7fffffff, end # 01e0 lui at,0x8000 | |
142 | # 01e4 slt at,a0,at | |
143 | # 01e8 beqz at,end | |
144 | # 01ec nop | |
145 | bgtu $4, 0xffffffff, end # 01f0 li at,0x8000 | |
146 | # 01f4 dsll at,at,17 | |
147 | # 01f8 sltu at,a0,at | |
148 | # 01fc beqz at,end | |
149 | # 0200 nop | |
150 | ble $4, 0x7fffffff, end # 0204 lui at,0x8000 | |
151 | # 0208 slt at,a0,at | |
152 | # 020c bnez at,end | |
153 | # 0210 nop | |
154 | bleu $4, 0xffffffff, end # 0214 li at,0x8000 | |
155 | # 0218 dsll at,at,17 | |
156 | # 021c sltu at,a0,at | |
157 | # 0220 bnez at,end | |
158 | # 0224 nop | |
159 | ||
160 | add.d $f1, $f2, $f3 # 0228 add.d $f1,$f2,$f3 | |
161 | ||
162 | end: |