1 eÿcsa.s
\0\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0ö
\ 1.global csa
7 ! jump table address in %o0
10 ld [%o0], %o4 ! default address
12 subcc %o1, %o2, %o1 ! index - lower bound
15 cmp %o1, %o3 ! rel. index, upper - lower bound
19 add %o0, %o5, %o3 ! %o3 = @jump address
20 ld [%o3+12], %o2 ! %o2 = jump address
38 csb.s
\0\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0·
\ 1.global csb
42 ! case descriptor in %o0
44 ld [%o0], %o2 ! default jump address
45 ld [%o0+4], %o3 ! # entries
78 4dvu.s
\0\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0b
\ 6.global dvu4
160 bge 3f /* jump if msb clear */
167 bl 5f /* jump if msb set */
207 5: /* div common for dvu4 && ( %o0 & 0x80000000) */
248 0: /* divide by zero */
254 lar.s
\0\0\0\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0;
\ 6.global aar
258 aar: ! %o0 = descr %o1 = index %o2 = array_ptr
261 ld [%i0], %o0 ! lower bound
262 subcc %i1, %o0, %o1 ! 0..N-1
269 call mli4 ! descr *= n.size
270 ld [%i0+8], %o0 ! el.size
271 add %i2, %o0, %i0 ! &base_addr[n]
281 lar: ! %o0 = descr %o1 = index %o2 = array_ptr
288 ! %o0 = address of el, %o1 = sizeof(el), %o2 = word, %o3 = descr
289 ld [%o3+8], %o1 ! el.size
293 ldub [%o0], %o2 ! el.size == 1
296 st %o2, [%l0] ! delay slot
300 lduh [%o0], %o2 ! el.size == 2
303 st %o2, [%l0] ! delay slot
310 st %o2, [%l0] ! delay slot
319 sar: ! %o0 = descr %o1 = index %o2 = array_ptr
326 ! %o0 = address of el, %o1 = sizeof(el), %o2 = word, %o3 = descr
328 ld [%o3+8], %o1 ! el.size
335 inc 4, %l0 ! delay slot
342 inc 4, %l0 ! delay slot
349 inc 4, %l0 ! delay slot
355 st %o2, [%o0+%o1] ! delay slot
357 add %l0, %o4, %l0 ! delay slot
358 muldiv.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0=
364 andncc %o0, 0xfff, %g0
437 andncc %o4, 0xfff, %o5
507 \0fif.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0¡
\ 3.global fif8, Fd0, Fd1, Fd80000000, Fs80000000, Fs0
515 .word 0x43300000, 0x0 ! magic const: (a.b + x) - x == a.0
574 rfef.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0¡
\ 2#
629 nop.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0\1d\0.global nop
634 eshp.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0¾
\ 1.global strhp
637 strhp: ! %o0 = new heap pointer
640 st %i0, [%o1] ! it'll probably go right, anyway
646 add %i0, 0x400, %i0 ! extra 1K
648 st %o0, [%o1] ! prematurely set limhp
664 trp.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0¤
\ 1.global trp, write
690 set message_high-message, %o2
698 .ascii "the error code is in %o0\n"
700 cfu.s
\0.s
\0\0\0\0\0\0\0\0\0\0\ 2\ 2¤
\ 1\0\0Ê
\ 2.global cfu4, cfu8