1~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2MOTOROLA MICROPROCESSOR & MEMORY TECHNOLOGY GROUP
3M68000 Hi-Performance Microprocessor Division
4M68060 Software Package
5Production Release P1.00 -- October 10, 1994
6
7M68060 Software Package Copyright © 1993, 1994 Motorola Inc. All rights reserved.
8
9THE SOFTWARE is provided on an "AS IS" basis and without warranty.
10To the maximum extent permitted by applicable law,
11MOTOROLA DISCLAIMS ALL WARRANTIES WHETHER EXPRESS OR IMPLIED,
12INCLUDING IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE
13and any warranty against infringement with regard to the SOFTWARE
14(INCLUDING ANY MODIFIED VERSIONS THEREOF) and any accompanying written materials.
15
16To the maximum extent permitted by applicable law,
17IN NO EVENT SHALL MOTOROLA BE LIABLE FOR ANY DAMAGES WHATSOEVER
18(INCLUDING WITHOUT LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFITS,
19BUSINESS INTERRUPTION, LOSS OF BUSINESS INFORMATION, OR OTHER PECUNIARY LOSS)
20ARISING OF THE USE OR INABILITY TO USE THE SOFTWARE.
21Motorola assumes no responsibility for the maintenance and support of the SOFTWARE.
22
23You are hereby granted a copyright license to use, modify, and distribute the SOFTWARE
24so long as this entire notice is retained without alteration in any modified and/or
25redistributed versions, and that such modified versions are clearly identified as such.
26No licenses are granted by implication, estoppel or otherwise under any patents
27or trademarks of Motorola, Inc.
28~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
29
30
31
32
33
34
35
36 bra.l _facoss_
37 short 0x0000
38 bra.l _facosd_
39 short 0x0000
40 bra.l _facosx_
41 short 0x0000
42
43 bra.l _fasins_
44 short 0x0000
45 bra.l _fasind_
46 short 0x0000
47 bra.l _fasinx_
48 short 0x0000
49
50 bra.l _fatans_
51 short 0x0000
52 bra.l _fatand_
53 short 0x0000
54 bra.l _fatanx_
55 short 0x0000
56
57 bra.l _fatanhs_
58 short 0x0000
59 bra.l _fatanhd_
60 short 0x0000
61 bra.l _fatanhx_
62 short 0x0000
63
64 bra.l _fcoss_
65 short 0x0000
66 bra.l _fcosd_
67 short 0x0000
68 bra.l _fcosx_
69 short 0x0000
70
71 bra.l _fcoshs_
72 short 0x0000
73 bra.l _fcoshd_
74 short 0x0000
75 bra.l _fcoshx_
76 short 0x0000
77
78 bra.l _fetoxs_
79 short 0x0000
80 bra.l _fetoxd_
81 short 0x0000
82 bra.l _fetoxx_
83 short 0x0000
84
85 bra.l _fetoxm1s_
86 short 0x0000
87 bra.l _fetoxm1d_
88 short 0x0000
89 bra.l _fetoxm1x_
90 short 0x0000
91
92 bra.l _fgetexps_
93 short 0x0000
94 bra.l _fgetexpd_
95 short 0x0000
96 bra.l _fgetexpx_
97 short 0x0000
98
99 bra.l _fgetmans_
100 short 0x0000
101 bra.l _fgetmand_
102 short 0x0000
103 bra.l _fgetmanx_
104 short 0x0000
105
106 bra.l _flog10s_
107 short 0x0000
108 bra.l _flog10d_
109 short 0x0000
110 bra.l _flog10x_
111 short 0x0000
112
113 bra.l _flog2s_
114 short 0x0000
115 bra.l _flog2d_
116 short 0x0000
117 bra.l _flog2x_
118 short 0x0000
119
120 bra.l _flogns_
121 short 0x0000
122 bra.l _flognd_
123 short 0x0000
124 bra.l _flognx_
125 short 0x0000
126
127 bra.l _flognp1s_
128 short 0x0000
129 bra.l _flognp1d_
130 short 0x0000
131 bra.l _flognp1x_
132 short 0x0000
133
134 bra.l _fmods_
135 short 0x0000
136 bra.l _fmodd_
137 short 0x0000
138 bra.l _fmodx_
139 short 0x0000
140
141 bra.l _frems_
142 short 0x0000
143 bra.l _fremd_
144 short 0x0000
145 bra.l _fremx_
146 short 0x0000
147
148 bra.l _fscales_
149 short 0x0000
150 bra.l _fscaled_
151 short 0x0000
152 bra.l _fscalex_
153 short 0x0000
154
155 bra.l _fsins_
156 short 0x0000
157 bra.l _fsind_
158 short 0x0000
159 bra.l _fsinx_
160 short 0x0000
161
162 bra.l _fsincoss_
163 short 0x0000
164 bra.l _fsincosd_
165 short 0x0000
166 bra.l _fsincosx_
167 short 0x0000
168
169 bra.l _fsinhs_
170 short 0x0000
171 bra.l _fsinhd_
172 short 0x0000
173 bra.l _fsinhx_
174 short 0x0000
175
176 bra.l _ftans_
177 short 0x0000
178 bra.l _ftand_
179 short 0x0000
180 bra.l _ftanx_
181 short 0x0000
182
183 bra.l _ftanhs_
184 short 0x0000
185 bra.l _ftanhd_
186 short 0x0000
187 bra.l _ftanhx_
188 short 0x0000
189
190 bra.l _ftentoxs_
191 short 0x0000
192 bra.l _ftentoxd_
193 short 0x0000
194 bra.l _ftentoxx_
195 short 0x0000
196
197 bra.l _ftwotoxs_
198 short 0x0000
199 bra.l _ftwotoxd_
200 short 0x0000
201 bra.l _ftwotoxx_
202 short 0x0000
203
204 bra.l _fabss_
205 short 0x0000
206 bra.l _fabsd_
207 short 0x0000
208 bra.l _fabsx_
209 short 0x0000
210
211 bra.l _fadds_
212 short 0x0000
213 bra.l _faddd_
214 short 0x0000
215 bra.l _faddx_
216 short 0x0000
217
218 bra.l _fdivs_
219 short 0x0000
220 bra.l _fdivd_
221 short 0x0000
222 bra.l _fdivx_
223 short 0x0000
224
225 bra.l _fints_
226 short 0x0000
227 bra.l _fintd_
228 short 0x0000
229 bra.l _fintx_
230 short 0x0000
231
232 bra.l _fintrzs_
233 short 0x0000
234 bra.l _fintrzd_
235 short 0x0000
236 bra.l _fintrzx_
237 short 0x0000
238
239 bra.l _fmuls_
240 short 0x0000
241 bra.l _fmuld_
242 short 0x0000
243 bra.l _fmulx_
244 short 0x0000
245
246 bra.l _fnegs_
247 short 0x0000
248 bra.l _fnegd_
249 short 0x0000
250 bra.l _fnegx_
251 short 0x0000
252
253 bra.l _fsqrts_
254 short 0x0000
255 bra.l _fsqrtd_
256 short 0x0000
257 bra.l _fsqrtx_
258 short 0x0000
259
260 bra.l _fsubs_
261 short 0x0000
262 bra.l _fsubd_
263 short 0x0000
264 bra.l _fsubx_
265 short 0x0000
266
267
268 align 0x400
269
270
271
272
273
274
275set LOCAL_SIZE, 192
276set LV, -LOCAL_SIZE
277
278set EXC_SR, 0x4
279set EXC_PC, 0x6
280set EXC_VOFF, 0xa
281set EXC_EA, 0xc
282
283set EXC_FP, 0x0
284
285set EXC_AREGS, -68
286set EXC_DREGS, -100
287set EXC_FPREGS, -36
288
289set EXC_A7, EXC_AREGS+(7*4)
290set OLD_A7, EXC_AREGS+(6*4)
291set EXC_A6, EXC_AREGS+(6*4)
292set EXC_A5, EXC_AREGS+(5*4)
293set EXC_A4, EXC_AREGS+(4*4)
294set EXC_A3, EXC_AREGS+(3*4)
295set EXC_A2, EXC_AREGS+(2*4)
296set EXC_A1, EXC_AREGS+(1*4)
297set EXC_A0, EXC_AREGS+(0*4)
298set EXC_D7, EXC_DREGS+(7*4)
299set EXC_D6, EXC_DREGS+(6*4)
300set EXC_D5, EXC_DREGS+(5*4)
301set EXC_D4, EXC_DREGS+(4*4)
302set EXC_D3, EXC_DREGS+(3*4)
303set EXC_D2, EXC_DREGS+(2*4)
304set EXC_D1, EXC_DREGS+(1*4)
305set EXC_D0, EXC_DREGS+(0*4)
306
307set EXC_FP0, EXC_FPREGS+(0*12)
308set EXC_FP1, EXC_FPREGS+(1*12)
309set EXC_FP2, EXC_FPREGS+(2*12)
310
311set FP_SCR1, LV+80
312set FP_SCR1_EX, FP_SCR1+0
313set FP_SCR1_SGN, FP_SCR1+2
314set FP_SCR1_HI, FP_SCR1+4
315set FP_SCR1_LO, FP_SCR1+8
316
317set FP_SCR0, LV+68
318set FP_SCR0_EX, FP_SCR0+0
319set FP_SCR0_SGN, FP_SCR0+2
320set FP_SCR0_HI, FP_SCR0+4
321set FP_SCR0_LO, FP_SCR0+8
322
323set FP_DST, LV+56
324set FP_DST_EX, FP_DST+0
325set FP_DST_SGN, FP_DST+2
326set FP_DST_HI, FP_DST+4
327set FP_DST_LO, FP_DST+8
328
329set FP_SRC, LV+44
330set FP_SRC_EX, FP_SRC+0
331set FP_SRC_SGN, FP_SRC+2
332set FP_SRC_HI, FP_SRC+4
333set FP_SRC_LO, FP_SRC+8
334
335set USER_FPIAR, LV+40
336
337set USER_FPSR, LV+36
338set FPSR_CC, USER_FPSR+0
339set FPSR_QBYTE, USER_FPSR+1
340set FPSR_EXCEPT, USER_FPSR+2
341set FPSR_AEXCEPT, USER_FPSR+3
342
343set USER_FPCR, LV+32
344set FPCR_ENABLE, USER_FPCR+2
345set FPCR_MODE, USER_FPCR+3
346
347set L_SCR3, LV+28
348set L_SCR2, LV+24
349set L_SCR1, LV+20
350
351set STORE_FLG, LV+19
352
353set EXC_TEMP2, LV+24
354set EXC_TEMP, LV+16
355
356set DTAG, LV+15
357set STAG, LV+14
358
359set SPCOND_FLG, LV+10
360
361set EXC_CC, LV+8
362set EXC_EXTWPTR, LV+4
363set EXC_EXTWORD, LV+2
364set EXC_CMDREG, LV+2
365set EXC_OPWORD, LV+0
366
367
368
369
370
371set FTEMP, 0
372set FTEMP_EX, 0
373set FTEMP_SGN, 2
374set FTEMP_HI, 4
375set FTEMP_LO, 8
376set FTEMP_GRS, 12
377
378set LOCAL, 0
379set LOCAL_EX, 0
380set LOCAL_SGN, 2
381set LOCAL_HI, 4
382set LOCAL_LO, 8
383set LOCAL_GRS, 12
384
385set DST, 0
386set DST_EX, 0
387set DST_HI, 4
388set DST_LO, 8
389
390set SRC, 0
391set SRC_EX, 0
392set SRC_HI, 4
393set SRC_LO, 8
394
395set SGL_LO, 0x3f81
396set SGL_HI, 0x407e
397set DBL_LO, 0x3c01
398set DBL_HI, 0x43fe
399set EXT_LO, 0x0
400set EXT_HI, 0x7ffe
401
402set EXT_BIAS, 0x3fff
403set SGL_BIAS, 0x007f
404set DBL_BIAS, 0x03ff
405
406set NORM, 0x00
407set ZERO, 0x01
408set INF, 0x02
409set QNAN, 0x03
410set DENORM, 0x04
411set SNAN, 0x05
412set UNNORM, 0x06
413
414
415
416
417set neg_bit, 0x3
418set z_bit, 0x2
419set inf_bit, 0x1
420set nan_bit, 0x0
421
422set q_sn_bit, 0x7
423
424set bsun_bit, 7
425set snan_bit, 6
426set operr_bit, 5
427set ovfl_bit, 4
428set unfl_bit, 3
429set dz_bit, 2
430set inex2_bit, 1
431set inex1_bit, 0
432
433set aiop_bit, 7
434set aovfl_bit, 6
435set aunfl_bit, 5
436set adz_bit, 4
437set ainex_bit, 3
438
439
440
441
442set neg_mask, 0x08000000
443set inf_mask, 0x02000000
444set z_mask, 0x04000000
445set nan_mask, 0x01000000
446
447set neg_bmask, 0x08
448set inf_bmask, 0x02
449set z_bmask, 0x04
450set nan_bmask, 0x01
451
452set bsun_mask, 0x00008000
453set snan_mask, 0x00004000
454set operr_mask, 0x00002000
455set ovfl_mask, 0x00001000
456set unfl_mask, 0x00000800
457set dz_mask, 0x00000400
458set inex2_mask, 0x00000200
459set inex1_mask, 0x00000100
460
461set aiop_mask, 0x00000080
462set aovfl_mask, 0x00000040
463set aunfl_mask, 0x00000020
464set adz_mask, 0x00000010
465set ainex_mask, 0x00000008
466
467
468
469
470set dzinf_mask, inf_mask+dz_mask+adz_mask
471set opnan_mask, nan_mask+operr_mask+aiop_mask
472set nzi_mask, 0x01ffffff
473set unfinx_mask, unfl_mask+inex2_mask+aunfl_mask+ainex_mask
474set unf2inx_mask, unfl_mask+inex2_mask+ainex_mask
475set ovfinx_mask, ovfl_mask+inex2_mask+aovfl_mask+ainex_mask
476set inx1a_mask, inex1_mask+ainex_mask
477set inx2a_mask, inex2_mask+ainex_mask
478set snaniop_mask, nan_mask+snan_mask+aiop_mask
479set snaniop2_mask, snan_mask+aiop_mask
480set naniop_mask, nan_mask+aiop_mask
481set neginf_mask, neg_mask+inf_mask
482set infaiop_mask, inf_mask+aiop_mask
483set negz_mask, neg_mask+z_mask
484set opaop_mask, operr_mask+aiop_mask
485set unfl_inx_mask, unfl_mask+aunfl_mask+ainex_mask
486set ovfl_inx_mask, ovfl_mask+aovfl_mask+ainex_mask
487
488
489
490
491set rnd_stky_bit, 29
492
493set sign_bit, 0x7
494set signan_bit, 0x6
495
496set sgl_thresh, 0x3f81
497set dbl_thresh, 0x3c01
498
499set x_mode, 0x0
500set s_mode, 0x4
501set d_mode, 0x8
502
503set rn_mode, 0x0
504set rz_mode, 0x1
505set rm_mode, 0x2
506set rp_mode, 0x3
507
508set mantissalen, 64
509
510set BYTE, 1
511set WORD, 2
512set LONG, 4
513
514set BSUN_VEC, 0xc0
515set INEX_VEC, 0xc4
516set DZ_VEC, 0xc8
517set UNFL_VEC, 0xcc
518set OPERR_VEC, 0xd0
519set OVFL_VEC, 0xd4
520set SNAN_VEC, 0xd8
521
522
523
524
525set ftrapcc_flg, 0x01
526set fbsun_flg, 0x02
527set mia7_flg, 0x04
528set mda7_flg, 0x08
529set fmovm_flg, 0x40
530set immed_flg, 0x80
531
532set ftrapcc_bit, 0x0
533set fbsun_bit, 0x1
534set mia7_bit, 0x2
535set mda7_bit, 0x3
536set immed_bit, 0x7
537
538
539
540
541set FMUL_OP, 0x0
542set FDIV_OP, 0x1
543set FADD_OP, 0x2
544set FMOV_OP, 0x3
545
546
547
548
549T1: long 0x40C62D38,0xD3D64634
550T2: long 0x3D6F90AE,0xB1E75CC7
551
552PI: long 0x40000000,0xC90FDAA2,0x2168C235,0x00000000
553PIBY2: long 0x3FFF0000,0xC90FDAA2,0x2168C235,0x00000000
554
555TWOBYPI:
556 long 0x3FE45F30,0x6DC9C883
557
558
559
560
561 global _fsins_
562_fsins_:
563 link %a6,&-LOCAL_SIZE
564
565 movm.l &0x0303,EXC_DREGS(%a6)
566 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
567 fmovm.x &0xc0,EXC_FP0(%a6)
568
569 fmov.l &0x0,%fpcr
570
571
572
573
574 fmov.s 0x8(%a6),%fp0
575 fmov.x %fp0,FP_SRC(%a6)
576 lea FP_SRC(%a6),%a0
577 bsr.l tag
578 mov.b %d0,STAG(%a6)
579 mov.b %d0,%d1
580
581 andi.l &0x00ff00ff,USER_FPSR(%a6)
582
583 clr.l %d0
584 mov.b FPCR_MODE(%a6),%d0
585
586 tst.b %d1
587 bne.b _L0_2s
588 bsr.l ssin
589 bra.b _L0_6s
590_L0_2s:
591 cmpi.b %d1,&ZERO
592 bne.b _L0_3s
593 bsr.l src_zero
594 bra.b _L0_6s
595_L0_3s:
596 cmpi.b %d1,&INF
597 bne.b _L0_4s
598 bsr.l t_operr
599 bra.b _L0_6s
600_L0_4s:
601 cmpi.b %d1,&QNAN
602 bne.b _L0_5s
603 bsr.l src_qnan
604 bra.b _L0_6s
605_L0_5s:
606 bsr.l ssind
607_L0_6s:
608
609
610
611
612 movm.l EXC_DREGS(%a6),&0x0303
613 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
614 fmovm.x EXC_FP1(%a6),&0x40
615 unlk %a6
616 rts
617
618 global _fsind_
619_fsind_:
620 link %a6,&-LOCAL_SIZE
621
622 movm.l &0x0303,EXC_DREGS(%a6)
623 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
624 fmovm.x &0xc0,EXC_FP0(%a6)
625
626 fmov.l &0x0,%fpcr
627
628
629
630
631 fmov.d 0x8(%a6),%fp0
632 fmov.x %fp0,FP_SRC(%a6)
633 lea FP_SRC(%a6),%a0
634 bsr.l tag
635 mov.b %d0,STAG(%a6)
636 mov.b %d0,%d1
637
638 andi.l &0x00ff00ff,USER_FPSR(%a6)
639
640 clr.l %d0
641 mov.b FPCR_MODE(%a6),%d0
642
643 mov.b %d1,STAG(%a6)
644 tst.b %d1
645 bne.b _L0_2d
646 bsr.l ssin
647 bra.b _L0_6d
648_L0_2d:
649 cmpi.b %d1,&ZERO
650 bne.b _L0_3d
651 bsr.l src_zero
652 bra.b _L0_6d
653_L0_3d:
654 cmpi.b %d1,&INF
655 bne.b _L0_4d
656 bsr.l t_operr
657 bra.b _L0_6d
658_L0_4d:
659 cmpi.b %d1,&QNAN
660 bne.b _L0_5d
661 bsr.l src_qnan
662 bra.b _L0_6d
663_L0_5d:
664 bsr.l ssind
665_L0_6d:
666
667
668
669
670 movm.l EXC_DREGS(%a6),&0x0303
671 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
672 fmovm.x EXC_FP1(%a6),&0x40
673 unlk %a6
674 rts
675
676 global _fsinx_
677_fsinx_:
678 link %a6,&-LOCAL_SIZE
679
680 movm.l &0x0303,EXC_DREGS(%a6)
681 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
682 fmovm.x &0xc0,EXC_FP0(%a6)
683
684 fmov.l &0x0,%fpcr
685
686
687
688
689 lea FP_SRC(%a6),%a0
690 mov.l 0x8+0x0(%a6),0x0(%a0)
691 mov.l 0x8+0x4(%a6),0x4(%a0)
692 mov.l 0x8+0x8(%a6),0x8(%a0)
693 bsr.l tag
694 mov.b %d0,STAG(%a6)
695 mov.b %d0,%d1
696
697 andi.l &0x00ff00ff,USER_FPSR(%a6)
698
699 clr.l %d0
700 mov.b FPCR_MODE(%a6),%d0
701
702 tst.b %d1
703 bne.b _L0_2x
704 bsr.l ssin
705 bra.b _L0_6x
706_L0_2x:
707 cmpi.b %d1,&ZERO
708 bne.b _L0_3x
709 bsr.l src_zero
710 bra.b _L0_6x
711_L0_3x:
712 cmpi.b %d1,&INF
713 bne.b _L0_4x
714 bsr.l t_operr
715 bra.b _L0_6x
716_L0_4x:
717 cmpi.b %d1,&QNAN
718 bne.b _L0_5x
719 bsr.l src_qnan
720 bra.b _L0_6x
721_L0_5x:
722 bsr.l ssind
723_L0_6x:
724
725
726
727
728 movm.l EXC_DREGS(%a6),&0x0303
729 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
730 fmovm.x EXC_FP1(%a6),&0x40
731 unlk %a6
732 rts
733
734
735
736
737
738 global _fcoss_
739_fcoss_:
740 link %a6,&-LOCAL_SIZE
741
742 movm.l &0x0303,EXC_DREGS(%a6)
743 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
744 fmovm.x &0xc0,EXC_FP0(%a6)
745
746 fmov.l &0x0,%fpcr
747
748
749
750
751 fmov.s 0x8(%a6),%fp0
752 fmov.x %fp0,FP_SRC(%a6)
753 lea FP_SRC(%a6),%a0
754 bsr.l tag
755 mov.b %d0,STAG(%a6)
756 mov.b %d0,%d1
757
758 andi.l &0x00ff00ff,USER_FPSR(%a6)
759
760 clr.l %d0
761 mov.b FPCR_MODE(%a6),%d0
762
763 tst.b %d1
764 bne.b _L1_2s
765 bsr.l scos
766 bra.b _L1_6s
767_L1_2s:
768 cmpi.b %d1,&ZERO
769 bne.b _L1_3s
770 bsr.l ld_pone
771 bra.b _L1_6s
772_L1_3s:
773 cmpi.b %d1,&INF
774 bne.b _L1_4s
775 bsr.l t_operr
776 bra.b _L1_6s
777_L1_4s:
778 cmpi.b %d1,&QNAN
779 bne.b _L1_5s
780 bsr.l src_qnan
781 bra.b _L1_6s
782_L1_5s:
783 bsr.l scosd
784_L1_6s:
785
786
787
788
789 movm.l EXC_DREGS(%a6),&0x0303
790 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
791 fmovm.x EXC_FP1(%a6),&0x40
792 unlk %a6
793 rts
794
795 global _fcosd_
796_fcosd_:
797 link %a6,&-LOCAL_SIZE
798
799 movm.l &0x0303,EXC_DREGS(%a6)
800 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
801 fmovm.x &0xc0,EXC_FP0(%a6)
802
803 fmov.l &0x0,%fpcr
804
805
806
807
808 fmov.d 0x8(%a6),%fp0
809 fmov.x %fp0,FP_SRC(%a6)
810 lea FP_SRC(%a6),%a0
811 bsr.l tag
812 mov.b %d0,STAG(%a6)
813 mov.b %d0,%d1
814
815 andi.l &0x00ff00ff,USER_FPSR(%a6)
816
817 clr.l %d0
818 mov.b FPCR_MODE(%a6),%d0
819
820 mov.b %d1,STAG(%a6)
821 tst.b %d1
822 bne.b _L1_2d
823 bsr.l scos
824 bra.b _L1_6d
825_L1_2d:
826 cmpi.b %d1,&ZERO
827 bne.b _L1_3d
828 bsr.l ld_pone
829 bra.b _L1_6d
830_L1_3d:
831 cmpi.b %d1,&INF
832 bne.b _L1_4d
833 bsr.l t_operr
834 bra.b _L1_6d
835_L1_4d:
836 cmpi.b %d1,&QNAN
837 bne.b _L1_5d
838 bsr.l src_qnan
839 bra.b _L1_6d
840_L1_5d:
841 bsr.l scosd
842_L1_6d:
843
844
845
846
847 movm.l EXC_DREGS(%a6),&0x0303
848 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
849 fmovm.x EXC_FP1(%a6),&0x40
850 unlk %a6
851 rts
852
853 global _fcosx_
854_fcosx_:
855 link %a6,&-LOCAL_SIZE
856
857 movm.l &0x0303,EXC_DREGS(%a6)
858 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
859 fmovm.x &0xc0,EXC_FP0(%a6)
860
861 fmov.l &0x0,%fpcr
862
863
864
865
866 lea FP_SRC(%a6),%a0
867 mov.l 0x8+0x0(%a6),0x0(%a0)
868 mov.l 0x8+0x4(%a6),0x4(%a0)
869 mov.l 0x8+0x8(%a6),0x8(%a0)
870 bsr.l tag
871 mov.b %d0,STAG(%a6)
872 mov.b %d0,%d1
873
874 andi.l &0x00ff00ff,USER_FPSR(%a6)
875
876 clr.l %d0
877 mov.b FPCR_MODE(%a6),%d0
878
879 tst.b %d1
880 bne.b _L1_2x
881 bsr.l scos
882 bra.b _L1_6x
883_L1_2x:
884 cmpi.b %d1,&ZERO
885 bne.b _L1_3x
886 bsr.l ld_pone
887 bra.b _L1_6x
888_L1_3x:
889 cmpi.b %d1,&INF
890 bne.b _L1_4x
891 bsr.l t_operr
892 bra.b _L1_6x
893_L1_4x:
894 cmpi.b %d1,&QNAN
895 bne.b _L1_5x
896 bsr.l src_qnan
897 bra.b _L1_6x
898_L1_5x:
899 bsr.l scosd
900_L1_6x:
901
902
903
904
905 movm.l EXC_DREGS(%a6),&0x0303
906 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
907 fmovm.x EXC_FP1(%a6),&0x40
908 unlk %a6
909 rts
910
911
912
913
914
915 global _fsinhs_
916_fsinhs_:
917 link %a6,&-LOCAL_SIZE
918
919 movm.l &0x0303,EXC_DREGS(%a6)
920 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
921 fmovm.x &0xc0,EXC_FP0(%a6)
922
923 fmov.l &0x0,%fpcr
924
925
926
927
928 fmov.s 0x8(%a6),%fp0
929 fmov.x %fp0,FP_SRC(%a6)
930 lea FP_SRC(%a6),%a0
931 bsr.l tag
932 mov.b %d0,STAG(%a6)
933 mov.b %d0,%d1
934
935 andi.l &0x00ff00ff,USER_FPSR(%a6)
936
937 clr.l %d0
938 mov.b FPCR_MODE(%a6),%d0
939
940 tst.b %d1
941 bne.b _L2_2s
942 bsr.l ssinh
943 bra.b _L2_6s
944_L2_2s:
945 cmpi.b %d1,&ZERO
946 bne.b _L2_3s
947 bsr.l src_zero
948 bra.b _L2_6s
949_L2_3s:
950 cmpi.b %d1,&INF
951 bne.b _L2_4s
952 bsr.l src_inf
953 bra.b _L2_6s
954_L2_4s:
955 cmpi.b %d1,&QNAN
956 bne.b _L2_5s
957 bsr.l src_qnan
958 bra.b _L2_6s
959_L2_5s:
960 bsr.l ssinhd
961_L2_6s:
962
963
964
965
966 movm.l EXC_DREGS(%a6),&0x0303
967 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
968 fmovm.x EXC_FP1(%a6),&0x40
969 unlk %a6
970 rts
971
972 global _fsinhd_
973_fsinhd_:
974 link %a6,&-LOCAL_SIZE
975
976 movm.l &0x0303,EXC_DREGS(%a6)
977 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
978 fmovm.x &0xc0,EXC_FP0(%a6)
979
980 fmov.l &0x0,%fpcr
981
982
983
984
985 fmov.d 0x8(%a6),%fp0
986 fmov.x %fp0,FP_SRC(%a6)
987 lea FP_SRC(%a6),%a0
988 bsr.l tag
989 mov.b %d0,STAG(%a6)
990 mov.b %d0,%d1
991
992 andi.l &0x00ff00ff,USER_FPSR(%a6)
993
994 clr.l %d0
995 mov.b FPCR_MODE(%a6),%d0
996
997 mov.b %d1,STAG(%a6)
998 tst.b %d1
999 bne.b _L2_2d
1000 bsr.l ssinh
1001 bra.b _L2_6d
1002_L2_2d:
1003 cmpi.b %d1,&ZERO
1004 bne.b _L2_3d
1005 bsr.l src_zero
1006 bra.b _L2_6d
1007_L2_3d:
1008 cmpi.b %d1,&INF
1009 bne.b _L2_4d
1010 bsr.l src_inf
1011 bra.b _L2_6d
1012_L2_4d:
1013 cmpi.b %d1,&QNAN
1014 bne.b _L2_5d
1015 bsr.l src_qnan
1016 bra.b _L2_6d
1017_L2_5d:
1018 bsr.l ssinhd
1019_L2_6d:
1020
1021
1022
1023
1024 movm.l EXC_DREGS(%a6),&0x0303
1025 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1026 fmovm.x EXC_FP1(%a6),&0x40
1027 unlk %a6
1028 rts
1029
1030 global _fsinhx_
1031_fsinhx_:
1032 link %a6,&-LOCAL_SIZE
1033
1034 movm.l &0x0303,EXC_DREGS(%a6)
1035 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1036 fmovm.x &0xc0,EXC_FP0(%a6)
1037
1038 fmov.l &0x0,%fpcr
1039
1040
1041
1042
1043 lea FP_SRC(%a6),%a0
1044 mov.l 0x8+0x0(%a6),0x0(%a0)
1045 mov.l 0x8+0x4(%a6),0x4(%a0)
1046 mov.l 0x8+0x8(%a6),0x8(%a0)
1047 bsr.l tag
1048 mov.b %d0,STAG(%a6)
1049 mov.b %d0,%d1
1050
1051 andi.l &0x00ff00ff,USER_FPSR(%a6)
1052
1053 clr.l %d0
1054 mov.b FPCR_MODE(%a6),%d0
1055
1056 tst.b %d1
1057 bne.b _L2_2x
1058 bsr.l ssinh
1059 bra.b _L2_6x
1060_L2_2x:
1061 cmpi.b %d1,&ZERO
1062 bne.b _L2_3x
1063 bsr.l src_zero
1064 bra.b _L2_6x
1065_L2_3x:
1066 cmpi.b %d1,&INF
1067 bne.b _L2_4x
1068 bsr.l src_inf
1069 bra.b _L2_6x
1070_L2_4x:
1071 cmpi.b %d1,&QNAN
1072 bne.b _L2_5x
1073 bsr.l src_qnan
1074 bra.b _L2_6x
1075_L2_5x:
1076 bsr.l ssinhd
1077_L2_6x:
1078
1079
1080
1081
1082 movm.l EXC_DREGS(%a6),&0x0303
1083 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1084 fmovm.x EXC_FP1(%a6),&0x40
1085 unlk %a6
1086 rts
1087
1088
1089
1090
1091
1092 global _flognp1s_
1093_flognp1s_:
1094 link %a6,&-LOCAL_SIZE
1095
1096 movm.l &0x0303,EXC_DREGS(%a6)
1097 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1098 fmovm.x &0xc0,EXC_FP0(%a6)
1099
1100 fmov.l &0x0,%fpcr
1101
1102
1103
1104
1105 fmov.s 0x8(%a6),%fp0
1106 fmov.x %fp0,FP_SRC(%a6)
1107 lea FP_SRC(%a6),%a0
1108 bsr.l tag
1109 mov.b %d0,STAG(%a6)
1110 mov.b %d0,%d1
1111
1112 andi.l &0x00ff00ff,USER_FPSR(%a6)
1113
1114 clr.l %d0
1115 mov.b FPCR_MODE(%a6),%d0
1116
1117 tst.b %d1
1118 bne.b _L3_2s
1119 bsr.l slognp1
1120 bra.b _L3_6s
1121_L3_2s:
1122 cmpi.b %d1,&ZERO
1123 bne.b _L3_3s
1124 bsr.l src_zero
1125 bra.b _L3_6s
1126_L3_3s:
1127 cmpi.b %d1,&INF
1128 bne.b _L3_4s
1129 bsr.l sopr_inf
1130 bra.b _L3_6s
1131_L3_4s:
1132 cmpi.b %d1,&QNAN
1133 bne.b _L3_5s
1134 bsr.l src_qnan
1135 bra.b _L3_6s
1136_L3_5s:
1137 bsr.l slognp1d
1138_L3_6s:
1139
1140
1141
1142
1143 movm.l EXC_DREGS(%a6),&0x0303
1144 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1145 fmovm.x EXC_FP1(%a6),&0x40
1146 unlk %a6
1147 rts
1148
1149 global _flognp1d_
1150_flognp1d_:
1151 link %a6,&-LOCAL_SIZE
1152
1153 movm.l &0x0303,EXC_DREGS(%a6)
1154 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1155 fmovm.x &0xc0,EXC_FP0(%a6)
1156
1157 fmov.l &0x0,%fpcr
1158
1159
1160
1161
1162 fmov.d 0x8(%a6),%fp0
1163 fmov.x %fp0,FP_SRC(%a6)
1164 lea FP_SRC(%a6),%a0
1165 bsr.l tag
1166 mov.b %d0,STAG(%a6)
1167 mov.b %d0,%d1
1168
1169 andi.l &0x00ff00ff,USER_FPSR(%a6)
1170
1171 clr.l %d0
1172 mov.b FPCR_MODE(%a6),%d0
1173
1174 mov.b %d1,STAG(%a6)
1175 tst.b %d1
1176 bne.b _L3_2d
1177 bsr.l slognp1
1178 bra.b _L3_6d
1179_L3_2d:
1180 cmpi.b %d1,&ZERO
1181 bne.b _L3_3d
1182 bsr.l src_zero
1183 bra.b _L3_6d
1184_L3_3d:
1185 cmpi.b %d1,&INF
1186 bne.b _L3_4d
1187 bsr.l sopr_inf
1188 bra.b _L3_6d
1189_L3_4d:
1190 cmpi.b %d1,&QNAN
1191 bne.b _L3_5d
1192 bsr.l src_qnan
1193 bra.b _L3_6d
1194_L3_5d:
1195 bsr.l slognp1d
1196_L3_6d:
1197
1198
1199
1200
1201 movm.l EXC_DREGS(%a6),&0x0303
1202 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1203 fmovm.x EXC_FP1(%a6),&0x40
1204 unlk %a6
1205 rts
1206
1207 global _flognp1x_
1208_flognp1x_:
1209 link %a6,&-LOCAL_SIZE
1210
1211 movm.l &0x0303,EXC_DREGS(%a6)
1212 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1213 fmovm.x &0xc0,EXC_FP0(%a6)
1214
1215 fmov.l &0x0,%fpcr
1216
1217
1218
1219
1220 lea FP_SRC(%a6),%a0
1221 mov.l 0x8+0x0(%a6),0x0(%a0)
1222 mov.l 0x8+0x4(%a6),0x4(%a0)
1223 mov.l 0x8+0x8(%a6),0x8(%a0)
1224 bsr.l tag
1225 mov.b %d0,STAG(%a6)
1226 mov.b %d0,%d1
1227
1228 andi.l &0x00ff00ff,USER_FPSR(%a6)
1229
1230 clr.l %d0
1231 mov.b FPCR_MODE(%a6),%d0
1232
1233 tst.b %d1
1234 bne.b _L3_2x
1235 bsr.l slognp1
1236 bra.b _L3_6x
1237_L3_2x:
1238 cmpi.b %d1,&ZERO
1239 bne.b _L3_3x
1240 bsr.l src_zero
1241 bra.b _L3_6x
1242_L3_3x:
1243 cmpi.b %d1,&INF
1244 bne.b _L3_4x
1245 bsr.l sopr_inf
1246 bra.b _L3_6x
1247_L3_4x:
1248 cmpi.b %d1,&QNAN
1249 bne.b _L3_5x
1250 bsr.l src_qnan
1251 bra.b _L3_6x
1252_L3_5x:
1253 bsr.l slognp1d
1254_L3_6x:
1255
1256
1257
1258
1259 movm.l EXC_DREGS(%a6),&0x0303
1260 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1261 fmovm.x EXC_FP1(%a6),&0x40
1262 unlk %a6
1263 rts
1264
1265
1266
1267
1268
1269 global _fetoxm1s_
1270_fetoxm1s_:
1271 link %a6,&-LOCAL_SIZE
1272
1273 movm.l &0x0303,EXC_DREGS(%a6)
1274 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1275 fmovm.x &0xc0,EXC_FP0(%a6)
1276
1277 fmov.l &0x0,%fpcr
1278
1279
1280
1281
1282 fmov.s 0x8(%a6),%fp0
1283 fmov.x %fp0,FP_SRC(%a6)
1284 lea FP_SRC(%a6),%a0
1285 bsr.l tag
1286 mov.b %d0,STAG(%a6)
1287 mov.b %d0,%d1
1288
1289 andi.l &0x00ff00ff,USER_FPSR(%a6)
1290
1291 clr.l %d0
1292 mov.b FPCR_MODE(%a6),%d0
1293
1294 tst.b %d1
1295 bne.b _L4_2s
1296 bsr.l setoxm1
1297 bra.b _L4_6s
1298_L4_2s:
1299 cmpi.b %d1,&ZERO
1300 bne.b _L4_3s
1301 bsr.l src_zero
1302 bra.b _L4_6s
1303_L4_3s:
1304 cmpi.b %d1,&INF
1305 bne.b _L4_4s
1306 bsr.l setoxm1i
1307 bra.b _L4_6s
1308_L4_4s:
1309 cmpi.b %d1,&QNAN
1310 bne.b _L4_5s
1311 bsr.l src_qnan
1312 bra.b _L4_6s
1313_L4_5s:
1314 bsr.l setoxm1d
1315_L4_6s:
1316
1317
1318
1319
1320 movm.l EXC_DREGS(%a6),&0x0303
1321 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1322 fmovm.x EXC_FP1(%a6),&0x40
1323 unlk %a6
1324 rts
1325
1326 global _fetoxm1d_
1327_fetoxm1d_:
1328 link %a6,&-LOCAL_SIZE
1329
1330 movm.l &0x0303,EXC_DREGS(%a6)
1331 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1332 fmovm.x &0xc0,EXC_FP0(%a6)
1333
1334 fmov.l &0x0,%fpcr
1335
1336
1337
1338
1339 fmov.d 0x8(%a6),%fp0
1340 fmov.x %fp0,FP_SRC(%a6)
1341 lea FP_SRC(%a6),%a0
1342 bsr.l tag
1343 mov.b %d0,STAG(%a6)
1344 mov.b %d0,%d1
1345
1346 andi.l &0x00ff00ff,USER_FPSR(%a6)
1347
1348 clr.l %d0
1349 mov.b FPCR_MODE(%a6),%d0
1350
1351 mov.b %d1,STAG(%a6)
1352 tst.b %d1
1353 bne.b _L4_2d
1354 bsr.l setoxm1
1355 bra.b _L4_6d
1356_L4_2d:
1357 cmpi.b %d1,&ZERO
1358 bne.b _L4_3d
1359 bsr.l src_zero
1360 bra.b _L4_6d
1361_L4_3d:
1362 cmpi.b %d1,&INF
1363 bne.b _L4_4d
1364 bsr.l setoxm1i
1365 bra.b _L4_6d
1366_L4_4d:
1367 cmpi.b %d1,&QNAN
1368 bne.b _L4_5d
1369 bsr.l src_qnan
1370 bra.b _L4_6d
1371_L4_5d:
1372 bsr.l setoxm1d
1373_L4_6d:
1374
1375
1376
1377
1378 movm.l EXC_DREGS(%a6),&0x0303
1379 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1380 fmovm.x EXC_FP1(%a6),&0x40
1381 unlk %a6
1382 rts
1383
1384 global _fetoxm1x_
1385_fetoxm1x_:
1386 link %a6,&-LOCAL_SIZE
1387
1388 movm.l &0x0303,EXC_DREGS(%a6)
1389 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1390 fmovm.x &0xc0,EXC_FP0(%a6)
1391
1392 fmov.l &0x0,%fpcr
1393
1394
1395
1396
1397 lea FP_SRC(%a6),%a0
1398 mov.l 0x8+0x0(%a6),0x0(%a0)
1399 mov.l 0x8+0x4(%a6),0x4(%a0)
1400 mov.l 0x8+0x8(%a6),0x8(%a0)
1401 bsr.l tag
1402 mov.b %d0,STAG(%a6)
1403 mov.b %d0,%d1
1404
1405 andi.l &0x00ff00ff,USER_FPSR(%a6)
1406
1407 clr.l %d0
1408 mov.b FPCR_MODE(%a6),%d0
1409
1410 tst.b %d1
1411 bne.b _L4_2x
1412 bsr.l setoxm1
1413 bra.b _L4_6x
1414_L4_2x:
1415 cmpi.b %d1,&ZERO
1416 bne.b _L4_3x
1417 bsr.l src_zero
1418 bra.b _L4_6x
1419_L4_3x:
1420 cmpi.b %d1,&INF
1421 bne.b _L4_4x
1422 bsr.l setoxm1i
1423 bra.b _L4_6x
1424_L4_4x:
1425 cmpi.b %d1,&QNAN
1426 bne.b _L4_5x
1427 bsr.l src_qnan
1428 bra.b _L4_6x
1429_L4_5x:
1430 bsr.l setoxm1d
1431_L4_6x:
1432
1433
1434
1435
1436 movm.l EXC_DREGS(%a6),&0x0303
1437 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1438 fmovm.x EXC_FP1(%a6),&0x40
1439 unlk %a6
1440 rts
1441
1442
1443
1444
1445
1446 global _ftanhs_
1447_ftanhs_:
1448 link %a6,&-LOCAL_SIZE
1449
1450 movm.l &0x0303,EXC_DREGS(%a6)
1451 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1452 fmovm.x &0xc0,EXC_FP0(%a6)
1453
1454 fmov.l &0x0,%fpcr
1455
1456
1457
1458
1459 fmov.s 0x8(%a6),%fp0
1460 fmov.x %fp0,FP_SRC(%a6)
1461 lea FP_SRC(%a6),%a0
1462 bsr.l tag
1463 mov.b %d0,STAG(%a6)
1464 mov.b %d0,%d1
1465
1466 andi.l &0x00ff00ff,USER_FPSR(%a6)
1467
1468 clr.l %d0
1469 mov.b FPCR_MODE(%a6),%d0
1470
1471 tst.b %d1
1472 bne.b _L5_2s
1473 bsr.l stanh
1474 bra.b _L5_6s
1475_L5_2s:
1476 cmpi.b %d1,&ZERO
1477 bne.b _L5_3s
1478 bsr.l src_zero
1479 bra.b _L5_6s
1480_L5_3s:
1481 cmpi.b %d1,&INF
1482 bne.b _L5_4s
1483 bsr.l src_one
1484 bra.b _L5_6s
1485_L5_4s:
1486 cmpi.b %d1,&QNAN
1487 bne.b _L5_5s
1488 bsr.l src_qnan
1489 bra.b _L5_6s
1490_L5_5s:
1491 bsr.l stanhd
1492_L5_6s:
1493
1494
1495
1496
1497 movm.l EXC_DREGS(%a6),&0x0303
1498 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1499 fmovm.x EXC_FP1(%a6),&0x40
1500 unlk %a6
1501 rts
1502
1503 global _ftanhd_
1504_ftanhd_:
1505 link %a6,&-LOCAL_SIZE
1506
1507 movm.l &0x0303,EXC_DREGS(%a6)
1508 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1509 fmovm.x &0xc0,EXC_FP0(%a6)
1510
1511 fmov.l &0x0,%fpcr
1512
1513
1514
1515
1516 fmov.d 0x8(%a6),%fp0
1517 fmov.x %fp0,FP_SRC(%a6)
1518 lea FP_SRC(%a6),%a0
1519 bsr.l tag
1520 mov.b %d0,STAG(%a6)
1521 mov.b %d0,%d1
1522
1523 andi.l &0x00ff00ff,USER_FPSR(%a6)
1524
1525 clr.l %d0
1526 mov.b FPCR_MODE(%a6),%d0
1527
1528 mov.b %d1,STAG(%a6)
1529 tst.b %d1
1530 bne.b _L5_2d
1531 bsr.l stanh
1532 bra.b _L5_6d
1533_L5_2d:
1534 cmpi.b %d1,&ZERO
1535 bne.b _L5_3d
1536 bsr.l src_zero
1537 bra.b _L5_6d
1538_L5_3d:
1539 cmpi.b %d1,&INF
1540 bne.b _L5_4d
1541 bsr.l src_one
1542 bra.b _L5_6d
1543_L5_4d:
1544 cmpi.b %d1,&QNAN
1545 bne.b _L5_5d
1546 bsr.l src_qnan
1547 bra.b _L5_6d
1548_L5_5d:
1549 bsr.l stanhd
1550_L5_6d:
1551
1552
1553
1554
1555 movm.l EXC_DREGS(%a6),&0x0303
1556 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1557 fmovm.x EXC_FP1(%a6),&0x40
1558 unlk %a6
1559 rts
1560
1561 global _ftanhx_
1562_ftanhx_:
1563 link %a6,&-LOCAL_SIZE
1564
1565 movm.l &0x0303,EXC_DREGS(%a6)
1566 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1567 fmovm.x &0xc0,EXC_FP0(%a6)
1568
1569 fmov.l &0x0,%fpcr
1570
1571
1572
1573
1574 lea FP_SRC(%a6),%a0
1575 mov.l 0x8+0x0(%a6),0x0(%a0)
1576 mov.l 0x8+0x4(%a6),0x4(%a0)
1577 mov.l 0x8+0x8(%a6),0x8(%a0)
1578 bsr.l tag
1579 mov.b %d0,STAG(%a6)
1580 mov.b %d0,%d1
1581
1582 andi.l &0x00ff00ff,USER_FPSR(%a6)
1583
1584 clr.l %d0
1585 mov.b FPCR_MODE(%a6),%d0
1586
1587 tst.b %d1
1588 bne.b _L5_2x
1589 bsr.l stanh
1590 bra.b _L5_6x
1591_L5_2x:
1592 cmpi.b %d1,&ZERO
1593 bne.b _L5_3x
1594 bsr.l src_zero
1595 bra.b _L5_6x
1596_L5_3x:
1597 cmpi.b %d1,&INF
1598 bne.b _L5_4x
1599 bsr.l src_one
1600 bra.b _L5_6x
1601_L5_4x:
1602 cmpi.b %d1,&QNAN
1603 bne.b _L5_5x
1604 bsr.l src_qnan
1605 bra.b _L5_6x
1606_L5_5x:
1607 bsr.l stanhd
1608_L5_6x:
1609
1610
1611
1612
1613 movm.l EXC_DREGS(%a6),&0x0303
1614 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1615 fmovm.x EXC_FP1(%a6),&0x40
1616 unlk %a6
1617 rts
1618
1619
1620
1621
1622
1623 global _fatans_
1624_fatans_:
1625 link %a6,&-LOCAL_SIZE
1626
1627 movm.l &0x0303,EXC_DREGS(%a6)
1628 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1629 fmovm.x &0xc0,EXC_FP0(%a6)
1630
1631 fmov.l &0x0,%fpcr
1632
1633
1634
1635
1636 fmov.s 0x8(%a6),%fp0
1637 fmov.x %fp0,FP_SRC(%a6)
1638 lea FP_SRC(%a6),%a0
1639 bsr.l tag
1640 mov.b %d0,STAG(%a6)
1641 mov.b %d0,%d1
1642
1643 andi.l &0x00ff00ff,USER_FPSR(%a6)
1644
1645 clr.l %d0
1646 mov.b FPCR_MODE(%a6),%d0
1647
1648 tst.b %d1
1649 bne.b _L6_2s
1650 bsr.l satan
1651 bra.b _L6_6s
1652_L6_2s:
1653 cmpi.b %d1,&ZERO
1654 bne.b _L6_3s
1655 bsr.l src_zero
1656 bra.b _L6_6s
1657_L6_3s:
1658 cmpi.b %d1,&INF
1659 bne.b _L6_4s
1660 bsr.l spi_2
1661 bra.b _L6_6s
1662_L6_4s:
1663 cmpi.b %d1,&QNAN
1664 bne.b _L6_5s
1665 bsr.l src_qnan
1666 bra.b _L6_6s
1667_L6_5s:
1668 bsr.l satand
1669_L6_6s:
1670
1671
1672
1673
1674 movm.l EXC_DREGS(%a6),&0x0303
1675 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1676 fmovm.x EXC_FP1(%a6),&0x40
1677 unlk %a6
1678 rts
1679
1680 global _fatand_
1681_fatand_:
1682 link %a6,&-LOCAL_SIZE
1683
1684 movm.l &0x0303,EXC_DREGS(%a6)
1685 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1686 fmovm.x &0xc0,EXC_FP0(%a6)
1687
1688 fmov.l &0x0,%fpcr
1689
1690
1691
1692
1693 fmov.d 0x8(%a6),%fp0
1694 fmov.x %fp0,FP_SRC(%a6)
1695 lea FP_SRC(%a6),%a0
1696 bsr.l tag
1697 mov.b %d0,STAG(%a6)
1698 mov.b %d0,%d1
1699
1700 andi.l &0x00ff00ff,USER_FPSR(%a6)
1701
1702 clr.l %d0
1703 mov.b FPCR_MODE(%a6),%d0
1704
1705 mov.b %d1,STAG(%a6)
1706 tst.b %d1
1707 bne.b _L6_2d
1708 bsr.l satan
1709 bra.b _L6_6d
1710_L6_2d:
1711 cmpi.b %d1,&ZERO
1712 bne.b _L6_3d
1713 bsr.l src_zero
1714 bra.b _L6_6d
1715_L6_3d:
1716 cmpi.b %d1,&INF
1717 bne.b _L6_4d
1718 bsr.l spi_2
1719 bra.b _L6_6d
1720_L6_4d:
1721 cmpi.b %d1,&QNAN
1722 bne.b _L6_5d
1723 bsr.l src_qnan
1724 bra.b _L6_6d
1725_L6_5d:
1726 bsr.l satand
1727_L6_6d:
1728
1729
1730
1731
1732 movm.l EXC_DREGS(%a6),&0x0303
1733 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1734 fmovm.x EXC_FP1(%a6),&0x40
1735 unlk %a6
1736 rts
1737
1738 global _fatanx_
1739_fatanx_:
1740 link %a6,&-LOCAL_SIZE
1741
1742 movm.l &0x0303,EXC_DREGS(%a6)
1743 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1744 fmovm.x &0xc0,EXC_FP0(%a6)
1745
1746 fmov.l &0x0,%fpcr
1747
1748
1749
1750
1751 lea FP_SRC(%a6),%a0
1752 mov.l 0x8+0x0(%a6),0x0(%a0)
1753 mov.l 0x8+0x4(%a6),0x4(%a0)
1754 mov.l 0x8+0x8(%a6),0x8(%a0)
1755 bsr.l tag
1756 mov.b %d0,STAG(%a6)
1757 mov.b %d0,%d1
1758
1759 andi.l &0x00ff00ff,USER_FPSR(%a6)
1760
1761 clr.l %d0
1762 mov.b FPCR_MODE(%a6),%d0
1763
1764 tst.b %d1
1765 bne.b _L6_2x
1766 bsr.l satan
1767 bra.b _L6_6x
1768_L6_2x:
1769 cmpi.b %d1,&ZERO
1770 bne.b _L6_3x
1771 bsr.l src_zero
1772 bra.b _L6_6x
1773_L6_3x:
1774 cmpi.b %d1,&INF
1775 bne.b _L6_4x
1776 bsr.l spi_2
1777 bra.b _L6_6x
1778_L6_4x:
1779 cmpi.b %d1,&QNAN
1780 bne.b _L6_5x
1781 bsr.l src_qnan
1782 bra.b _L6_6x
1783_L6_5x:
1784 bsr.l satand
1785_L6_6x:
1786
1787
1788
1789
1790 movm.l EXC_DREGS(%a6),&0x0303
1791 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1792 fmovm.x EXC_FP1(%a6),&0x40
1793 unlk %a6
1794 rts
1795
1796
1797
1798
1799
1800 global _fasins_
1801_fasins_:
1802 link %a6,&-LOCAL_SIZE
1803
1804 movm.l &0x0303,EXC_DREGS(%a6)
1805 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1806 fmovm.x &0xc0,EXC_FP0(%a6)
1807
1808 fmov.l &0x0,%fpcr
1809
1810
1811
1812
1813 fmov.s 0x8(%a6),%fp0
1814 fmov.x %fp0,FP_SRC(%a6)
1815 lea FP_SRC(%a6),%a0
1816 bsr.l tag
1817 mov.b %d0,STAG(%a6)
1818 mov.b %d0,%d1
1819
1820 andi.l &0x00ff00ff,USER_FPSR(%a6)
1821
1822 clr.l %d0
1823 mov.b FPCR_MODE(%a6),%d0
1824
1825 tst.b %d1
1826 bne.b _L7_2s
1827 bsr.l sasin
1828 bra.b _L7_6s
1829_L7_2s:
1830 cmpi.b %d1,&ZERO
1831 bne.b _L7_3s
1832 bsr.l src_zero
1833 bra.b _L7_6s
1834_L7_3s:
1835 cmpi.b %d1,&INF
1836 bne.b _L7_4s
1837 bsr.l t_operr
1838 bra.b _L7_6s
1839_L7_4s:
1840 cmpi.b %d1,&QNAN
1841 bne.b _L7_5s
1842 bsr.l src_qnan
1843 bra.b _L7_6s
1844_L7_5s:
1845 bsr.l sasind
1846_L7_6s:
1847
1848
1849
1850
1851 movm.l EXC_DREGS(%a6),&0x0303
1852 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1853 fmovm.x EXC_FP1(%a6),&0x40
1854 unlk %a6
1855 rts
1856
1857 global _fasind_
1858_fasind_:
1859 link %a6,&-LOCAL_SIZE
1860
1861 movm.l &0x0303,EXC_DREGS(%a6)
1862 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1863 fmovm.x &0xc0,EXC_FP0(%a6)
1864
1865 fmov.l &0x0,%fpcr
1866
1867
1868
1869
1870 fmov.d 0x8(%a6),%fp0
1871 fmov.x %fp0,FP_SRC(%a6)
1872 lea FP_SRC(%a6),%a0
1873 bsr.l tag
1874 mov.b %d0,STAG(%a6)
1875 mov.b %d0,%d1
1876
1877 andi.l &0x00ff00ff,USER_FPSR(%a6)
1878
1879 clr.l %d0
1880 mov.b FPCR_MODE(%a6),%d0
1881
1882 mov.b %d1,STAG(%a6)
1883 tst.b %d1
1884 bne.b _L7_2d
1885 bsr.l sasin
1886 bra.b _L7_6d
1887_L7_2d:
1888 cmpi.b %d1,&ZERO
1889 bne.b _L7_3d
1890 bsr.l src_zero
1891 bra.b _L7_6d
1892_L7_3d:
1893 cmpi.b %d1,&INF
1894 bne.b _L7_4d
1895 bsr.l t_operr
1896 bra.b _L7_6d
1897_L7_4d:
1898 cmpi.b %d1,&QNAN
1899 bne.b _L7_5d
1900 bsr.l src_qnan
1901 bra.b _L7_6d
1902_L7_5d:
1903 bsr.l sasind
1904_L7_6d:
1905
1906
1907
1908
1909 movm.l EXC_DREGS(%a6),&0x0303
1910 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1911 fmovm.x EXC_FP1(%a6),&0x40
1912 unlk %a6
1913 rts
1914
1915 global _fasinx_
1916_fasinx_:
1917 link %a6,&-LOCAL_SIZE
1918
1919 movm.l &0x0303,EXC_DREGS(%a6)
1920 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1921 fmovm.x &0xc0,EXC_FP0(%a6)
1922
1923 fmov.l &0x0,%fpcr
1924
1925
1926
1927
1928 lea FP_SRC(%a6),%a0
1929 mov.l 0x8+0x0(%a6),0x0(%a0)
1930 mov.l 0x8+0x4(%a6),0x4(%a0)
1931 mov.l 0x8+0x8(%a6),0x8(%a0)
1932 bsr.l tag
1933 mov.b %d0,STAG(%a6)
1934 mov.b %d0,%d1
1935
1936 andi.l &0x00ff00ff,USER_FPSR(%a6)
1937
1938 clr.l %d0
1939 mov.b FPCR_MODE(%a6),%d0
1940
1941 tst.b %d1
1942 bne.b _L7_2x
1943 bsr.l sasin
1944 bra.b _L7_6x
1945_L7_2x:
1946 cmpi.b %d1,&ZERO
1947 bne.b _L7_3x
1948 bsr.l src_zero
1949 bra.b _L7_6x
1950_L7_3x:
1951 cmpi.b %d1,&INF
1952 bne.b _L7_4x
1953 bsr.l t_operr
1954 bra.b _L7_6x
1955_L7_4x:
1956 cmpi.b %d1,&QNAN
1957 bne.b _L7_5x
1958 bsr.l src_qnan
1959 bra.b _L7_6x
1960_L7_5x:
1961 bsr.l sasind
1962_L7_6x:
1963
1964
1965
1966
1967 movm.l EXC_DREGS(%a6),&0x0303
1968 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
1969 fmovm.x EXC_FP1(%a6),&0x40
1970 unlk %a6
1971 rts
1972
1973
1974
1975
1976
1977 global _fatanhs_
1978_fatanhs_:
1979 link %a6,&-LOCAL_SIZE
1980
1981 movm.l &0x0303,EXC_DREGS(%a6)
1982 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
1983 fmovm.x &0xc0,EXC_FP0(%a6)
1984
1985 fmov.l &0x0,%fpcr
1986
1987
1988
1989
1990 fmov.s 0x8(%a6),%fp0
1991 fmov.x %fp0,FP_SRC(%a6)
1992 lea FP_SRC(%a6),%a0
1993 bsr.l tag
1994 mov.b %d0,STAG(%a6)
1995 mov.b %d0,%d1
1996
1997 andi.l &0x00ff00ff,USER_FPSR(%a6)
1998
1999 clr.l %d0
2000 mov.b FPCR_MODE(%a6),%d0
2001
2002 tst.b %d1
2003 bne.b _L8_2s
2004 bsr.l satanh
2005 bra.b _L8_6s
2006_L8_2s:
2007 cmpi.b %d1,&ZERO
2008 bne.b _L8_3s
2009 bsr.l src_zero
2010 bra.b _L8_6s
2011_L8_3s:
2012 cmpi.b %d1,&INF
2013 bne.b _L8_4s
2014 bsr.l t_operr
2015 bra.b _L8_6s
2016_L8_4s:
2017 cmpi.b %d1,&QNAN
2018 bne.b _L8_5s
2019 bsr.l src_qnan
2020 bra.b _L8_6s
2021_L8_5s:
2022 bsr.l satanhd
2023_L8_6s:
2024
2025
2026
2027
2028 movm.l EXC_DREGS(%a6),&0x0303
2029 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2030 fmovm.x EXC_FP1(%a6),&0x40
2031 unlk %a6
2032 rts
2033
2034 global _fatanhd_
2035_fatanhd_:
2036 link %a6,&-LOCAL_SIZE
2037
2038 movm.l &0x0303,EXC_DREGS(%a6)
2039 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2040 fmovm.x &0xc0,EXC_FP0(%a6)
2041
2042 fmov.l &0x0,%fpcr
2043
2044
2045
2046
2047 fmov.d 0x8(%a6),%fp0
2048 fmov.x %fp0,FP_SRC(%a6)
2049 lea FP_SRC(%a6),%a0
2050 bsr.l tag
2051 mov.b %d0,STAG(%a6)
2052 mov.b %d0,%d1
2053
2054 andi.l &0x00ff00ff,USER_FPSR(%a6)
2055
2056 clr.l %d0
2057 mov.b FPCR_MODE(%a6),%d0
2058
2059 mov.b %d1,STAG(%a6)
2060 tst.b %d1
2061 bne.b _L8_2d
2062 bsr.l satanh
2063 bra.b _L8_6d
2064_L8_2d:
2065 cmpi.b %d1,&ZERO
2066 bne.b _L8_3d
2067 bsr.l src_zero
2068 bra.b _L8_6d
2069_L8_3d:
2070 cmpi.b %d1,&INF
2071 bne.b _L8_4d
2072 bsr.l t_operr
2073 bra.b _L8_6d
2074_L8_4d:
2075 cmpi.b %d1,&QNAN
2076 bne.b _L8_5d
2077 bsr.l src_qnan
2078 bra.b _L8_6d
2079_L8_5d:
2080 bsr.l satanhd
2081_L8_6d:
2082
2083
2084
2085
2086 movm.l EXC_DREGS(%a6),&0x0303
2087 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2088 fmovm.x EXC_FP1(%a6),&0x40
2089 unlk %a6
2090 rts
2091
2092 global _fatanhx_
2093_fatanhx_:
2094 link %a6,&-LOCAL_SIZE
2095
2096 movm.l &0x0303,EXC_DREGS(%a6)
2097 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2098 fmovm.x &0xc0,EXC_FP0(%a6)
2099
2100 fmov.l &0x0,%fpcr
2101
2102
2103
2104
2105 lea FP_SRC(%a6),%a0
2106 mov.l 0x8+0x0(%a6),0x0(%a0)
2107 mov.l 0x8+0x4(%a6),0x4(%a0)
2108 mov.l 0x8+0x8(%a6),0x8(%a0)
2109 bsr.l tag
2110 mov.b %d0,STAG(%a6)
2111 mov.b %d0,%d1
2112
2113 andi.l &0x00ff00ff,USER_FPSR(%a6)
2114
2115 clr.l %d0
2116 mov.b FPCR_MODE(%a6),%d0
2117
2118 tst.b %d1
2119 bne.b _L8_2x
2120 bsr.l satanh
2121 bra.b _L8_6x
2122_L8_2x:
2123 cmpi.b %d1,&ZERO
2124 bne.b _L8_3x
2125 bsr.l src_zero
2126 bra.b _L8_6x
2127_L8_3x:
2128 cmpi.b %d1,&INF
2129 bne.b _L8_4x
2130 bsr.l t_operr
2131 bra.b _L8_6x
2132_L8_4x:
2133 cmpi.b %d1,&QNAN
2134 bne.b _L8_5x
2135 bsr.l src_qnan
2136 bra.b _L8_6x
2137_L8_5x:
2138 bsr.l satanhd
2139_L8_6x:
2140
2141
2142
2143
2144 movm.l EXC_DREGS(%a6),&0x0303
2145 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2146 fmovm.x EXC_FP1(%a6),&0x40
2147 unlk %a6
2148 rts
2149
2150
2151
2152
2153
2154 global _ftans_
2155_ftans_:
2156 link %a6,&-LOCAL_SIZE
2157
2158 movm.l &0x0303,EXC_DREGS(%a6)
2159 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2160 fmovm.x &0xc0,EXC_FP0(%a6)
2161
2162 fmov.l &0x0,%fpcr
2163
2164
2165
2166
2167 fmov.s 0x8(%a6),%fp0
2168 fmov.x %fp0,FP_SRC(%a6)
2169 lea FP_SRC(%a6),%a0
2170 bsr.l tag
2171 mov.b %d0,STAG(%a6)
2172 mov.b %d0,%d1
2173
2174 andi.l &0x00ff00ff,USER_FPSR(%a6)
2175
2176 clr.l %d0
2177 mov.b FPCR_MODE(%a6),%d0
2178
2179 tst.b %d1
2180 bne.b _L9_2s
2181 bsr.l stan
2182 bra.b _L9_6s
2183_L9_2s:
2184 cmpi.b %d1,&ZERO
2185 bne.b _L9_3s
2186 bsr.l src_zero
2187 bra.b _L9_6s
2188_L9_3s:
2189 cmpi.b %d1,&INF
2190 bne.b _L9_4s
2191 bsr.l t_operr
2192 bra.b _L9_6s
2193_L9_4s:
2194 cmpi.b %d1,&QNAN
2195 bne.b _L9_5s
2196 bsr.l src_qnan
2197 bra.b _L9_6s
2198_L9_5s:
2199 bsr.l stand
2200_L9_6s:
2201
2202
2203
2204
2205 movm.l EXC_DREGS(%a6),&0x0303
2206 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2207 fmovm.x EXC_FP1(%a6),&0x40
2208 unlk %a6
2209 rts
2210
2211 global _ftand_
2212_ftand_:
2213 link %a6,&-LOCAL_SIZE
2214
2215 movm.l &0x0303,EXC_DREGS(%a6)
2216 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2217 fmovm.x &0xc0,EXC_FP0(%a6)
2218
2219 fmov.l &0x0,%fpcr
2220
2221
2222
2223
2224 fmov.d 0x8(%a6),%fp0
2225 fmov.x %fp0,FP_SRC(%a6)
2226 lea FP_SRC(%a6),%a0
2227 bsr.l tag
2228 mov.b %d0,STAG(%a6)
2229 mov.b %d0,%d1
2230
2231 andi.l &0x00ff00ff,USER_FPSR(%a6)
2232
2233 clr.l %d0
2234 mov.b FPCR_MODE(%a6),%d0
2235
2236 mov.b %d1,STAG(%a6)
2237 tst.b %d1
2238 bne.b _L9_2d
2239 bsr.l stan
2240 bra.b _L9_6d
2241_L9_2d:
2242 cmpi.b %d1,&ZERO
2243 bne.b _L9_3d
2244 bsr.l src_zero
2245 bra.b _L9_6d
2246_L9_3d:
2247 cmpi.b %d1,&INF
2248 bne.b _L9_4d
2249 bsr.l t_operr
2250 bra.b _L9_6d
2251_L9_4d:
2252 cmpi.b %d1,&QNAN
2253 bne.b _L9_5d
2254 bsr.l src_qnan
2255 bra.b _L9_6d
2256_L9_5d:
2257 bsr.l stand
2258_L9_6d:
2259
2260
2261
2262
2263 movm.l EXC_DREGS(%a6),&0x0303
2264 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2265 fmovm.x EXC_FP1(%a6),&0x40
2266 unlk %a6
2267 rts
2268
2269 global _ftanx_
2270_ftanx_:
2271 link %a6,&-LOCAL_SIZE
2272
2273 movm.l &0x0303,EXC_DREGS(%a6)
2274 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2275 fmovm.x &0xc0,EXC_FP0(%a6)
2276
2277 fmov.l &0x0,%fpcr
2278
2279
2280
2281
2282 lea FP_SRC(%a6),%a0
2283 mov.l 0x8+0x0(%a6),0x0(%a0)
2284 mov.l 0x8+0x4(%a6),0x4(%a0)
2285 mov.l 0x8+0x8(%a6),0x8(%a0)
2286 bsr.l tag
2287 mov.b %d0,STAG(%a6)
2288 mov.b %d0,%d1
2289
2290 andi.l &0x00ff00ff,USER_FPSR(%a6)
2291
2292 clr.l %d0
2293 mov.b FPCR_MODE(%a6),%d0
2294
2295 tst.b %d1
2296 bne.b _L9_2x
2297 bsr.l stan
2298 bra.b _L9_6x
2299_L9_2x:
2300 cmpi.b %d1,&ZERO
2301 bne.b _L9_3x
2302 bsr.l src_zero
2303 bra.b _L9_6x
2304_L9_3x:
2305 cmpi.b %d1,&INF
2306 bne.b _L9_4x
2307 bsr.l t_operr
2308 bra.b _L9_6x
2309_L9_4x:
2310 cmpi.b %d1,&QNAN
2311 bne.b _L9_5x
2312 bsr.l src_qnan
2313 bra.b _L9_6x
2314_L9_5x:
2315 bsr.l stand
2316_L9_6x:
2317
2318
2319
2320
2321 movm.l EXC_DREGS(%a6),&0x0303
2322 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2323 fmovm.x EXC_FP1(%a6),&0x40
2324 unlk %a6
2325 rts
2326
2327
2328
2329
2330
2331 global _fetoxs_
2332_fetoxs_:
2333 link %a6,&-LOCAL_SIZE
2334
2335 movm.l &0x0303,EXC_DREGS(%a6)
2336 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2337 fmovm.x &0xc0,EXC_FP0(%a6)
2338
2339 fmov.l &0x0,%fpcr
2340
2341
2342
2343
2344 fmov.s 0x8(%a6),%fp0
2345 fmov.x %fp0,FP_SRC(%a6)
2346 lea FP_SRC(%a6),%a0
2347 bsr.l tag
2348 mov.b %d0,STAG(%a6)
2349 mov.b %d0,%d1
2350
2351 andi.l &0x00ff00ff,USER_FPSR(%a6)
2352
2353 clr.l %d0
2354 mov.b FPCR_MODE(%a6),%d0
2355
2356 tst.b %d1
2357 bne.b _L10_2s
2358 bsr.l setox
2359 bra.b _L10_6s
2360_L10_2s:
2361 cmpi.b %d1,&ZERO
2362 bne.b _L10_3s
2363 bsr.l ld_pone
2364 bra.b _L10_6s
2365_L10_3s:
2366 cmpi.b %d1,&INF
2367 bne.b _L10_4s
2368 bsr.l szr_inf
2369 bra.b _L10_6s
2370_L10_4s:
2371 cmpi.b %d1,&QNAN
2372 bne.b _L10_5s
2373 bsr.l src_qnan
2374 bra.b _L10_6s
2375_L10_5s:
2376 bsr.l setoxd
2377_L10_6s:
2378
2379
2380
2381
2382 movm.l EXC_DREGS(%a6),&0x0303
2383 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2384 fmovm.x EXC_FP1(%a6),&0x40
2385 unlk %a6
2386 rts
2387
2388 global _fetoxd_
2389_fetoxd_:
2390 link %a6,&-LOCAL_SIZE
2391
2392 movm.l &0x0303,EXC_DREGS(%a6)
2393 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2394 fmovm.x &0xc0,EXC_FP0(%a6)
2395
2396 fmov.l &0x0,%fpcr
2397
2398
2399
2400
2401 fmov.d 0x8(%a6),%fp0
2402 fmov.x %fp0,FP_SRC(%a6)
2403 lea FP_SRC(%a6),%a0
2404 bsr.l tag
2405 mov.b %d0,STAG(%a6)
2406 mov.b %d0,%d1
2407
2408 andi.l &0x00ff00ff,USER_FPSR(%a6)
2409
2410 clr.l %d0
2411 mov.b FPCR_MODE(%a6),%d0
2412
2413 mov.b %d1,STAG(%a6)
2414 tst.b %d1
2415 bne.b _L10_2d
2416 bsr.l setox
2417 bra.b _L10_6d
2418_L10_2d:
2419 cmpi.b %d1,&ZERO
2420 bne.b _L10_3d
2421 bsr.l ld_pone
2422 bra.b _L10_6d
2423_L10_3d:
2424 cmpi.b %d1,&INF
2425 bne.b _L10_4d
2426 bsr.l szr_inf
2427 bra.b _L10_6d
2428_L10_4d:
2429 cmpi.b %d1,&QNAN
2430 bne.b _L10_5d
2431 bsr.l src_qnan
2432 bra.b _L10_6d
2433_L10_5d:
2434 bsr.l setoxd
2435_L10_6d:
2436
2437
2438
2439
2440 movm.l EXC_DREGS(%a6),&0x0303
2441 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2442 fmovm.x EXC_FP1(%a6),&0x40
2443 unlk %a6
2444 rts
2445
2446 global _fetoxx_
2447_fetoxx_:
2448 link %a6,&-LOCAL_SIZE
2449
2450 movm.l &0x0303,EXC_DREGS(%a6)
2451 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2452 fmovm.x &0xc0,EXC_FP0(%a6)
2453
2454 fmov.l &0x0,%fpcr
2455
2456
2457
2458
2459 lea FP_SRC(%a6),%a0
2460 mov.l 0x8+0x0(%a6),0x0(%a0)
2461 mov.l 0x8+0x4(%a6),0x4(%a0)
2462 mov.l 0x8+0x8(%a6),0x8(%a0)
2463 bsr.l tag
2464 mov.b %d0,STAG(%a6)
2465 mov.b %d0,%d1
2466
2467 andi.l &0x00ff00ff,USER_FPSR(%a6)
2468
2469 clr.l %d0
2470 mov.b FPCR_MODE(%a6),%d0
2471
2472 tst.b %d1
2473 bne.b _L10_2x
2474 bsr.l setox
2475 bra.b _L10_6x
2476_L10_2x:
2477 cmpi.b %d1,&ZERO
2478 bne.b _L10_3x
2479 bsr.l ld_pone
2480 bra.b _L10_6x
2481_L10_3x:
2482 cmpi.b %d1,&INF
2483 bne.b _L10_4x
2484 bsr.l szr_inf
2485 bra.b _L10_6x
2486_L10_4x:
2487 cmpi.b %d1,&QNAN
2488 bne.b _L10_5x
2489 bsr.l src_qnan
2490 bra.b _L10_6x
2491_L10_5x:
2492 bsr.l setoxd
2493_L10_6x:
2494
2495
2496
2497
2498 movm.l EXC_DREGS(%a6),&0x0303
2499 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2500 fmovm.x EXC_FP1(%a6),&0x40
2501 unlk %a6
2502 rts
2503
2504
2505
2506
2507
2508 global _ftwotoxs_
2509_ftwotoxs_:
2510 link %a6,&-LOCAL_SIZE
2511
2512 movm.l &0x0303,EXC_DREGS(%a6)
2513 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2514 fmovm.x &0xc0,EXC_FP0(%a6)
2515
2516 fmov.l &0x0,%fpcr
2517
2518
2519
2520
2521 fmov.s 0x8(%a6),%fp0
2522 fmov.x %fp0,FP_SRC(%a6)
2523 lea FP_SRC(%a6),%a0
2524 bsr.l tag
2525 mov.b %d0,STAG(%a6)
2526 mov.b %d0,%d1
2527
2528 andi.l &0x00ff00ff,USER_FPSR(%a6)
2529
2530 clr.l %d0
2531 mov.b FPCR_MODE(%a6),%d0
2532
2533 tst.b %d1
2534 bne.b _L11_2s
2535 bsr.l stwotox
2536 bra.b _L11_6s
2537_L11_2s:
2538 cmpi.b %d1,&ZERO
2539 bne.b _L11_3s
2540 bsr.l ld_pone
2541 bra.b _L11_6s
2542_L11_3s:
2543 cmpi.b %d1,&INF
2544 bne.b _L11_4s
2545 bsr.l szr_inf
2546 bra.b _L11_6s
2547_L11_4s:
2548 cmpi.b %d1,&QNAN
2549 bne.b _L11_5s
2550 bsr.l src_qnan
2551 bra.b _L11_6s
2552_L11_5s:
2553 bsr.l stwotoxd
2554_L11_6s:
2555
2556
2557
2558
2559 movm.l EXC_DREGS(%a6),&0x0303
2560 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2561 fmovm.x EXC_FP1(%a6),&0x40
2562 unlk %a6
2563 rts
2564
2565 global _ftwotoxd_
2566_ftwotoxd_:
2567 link %a6,&-LOCAL_SIZE
2568
2569 movm.l &0x0303,EXC_DREGS(%a6)
2570 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2571 fmovm.x &0xc0,EXC_FP0(%a6)
2572
2573 fmov.l &0x0,%fpcr
2574
2575
2576
2577
2578 fmov.d 0x8(%a6),%fp0
2579 fmov.x %fp0,FP_SRC(%a6)
2580 lea FP_SRC(%a6),%a0
2581 bsr.l tag
2582 mov.b %d0,STAG(%a6)
2583 mov.b %d0,%d1
2584
2585 andi.l &0x00ff00ff,USER_FPSR(%a6)
2586
2587 clr.l %d0
2588 mov.b FPCR_MODE(%a6),%d0
2589
2590 mov.b %d1,STAG(%a6)
2591 tst.b %d1
2592 bne.b _L11_2d
2593 bsr.l stwotox
2594 bra.b _L11_6d
2595_L11_2d:
2596 cmpi.b %d1,&ZERO
2597 bne.b _L11_3d
2598 bsr.l ld_pone
2599 bra.b _L11_6d
2600_L11_3d:
2601 cmpi.b %d1,&INF
2602 bne.b _L11_4d
2603 bsr.l szr_inf
2604 bra.b _L11_6d
2605_L11_4d:
2606 cmpi.b %d1,&QNAN
2607 bne.b _L11_5d
2608 bsr.l src_qnan
2609 bra.b _L11_6d
2610_L11_5d:
2611 bsr.l stwotoxd
2612_L11_6d:
2613
2614
2615
2616
2617 movm.l EXC_DREGS(%a6),&0x0303
2618 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2619 fmovm.x EXC_FP1(%a6),&0x40
2620 unlk %a6
2621 rts
2622
2623 global _ftwotoxx_
2624_ftwotoxx_:
2625 link %a6,&-LOCAL_SIZE
2626
2627 movm.l &0x0303,EXC_DREGS(%a6)
2628 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2629 fmovm.x &0xc0,EXC_FP0(%a6)
2630
2631 fmov.l &0x0,%fpcr
2632
2633
2634
2635
2636 lea FP_SRC(%a6),%a0
2637 mov.l 0x8+0x0(%a6),0x0(%a0)
2638 mov.l 0x8+0x4(%a6),0x4(%a0)
2639 mov.l 0x8+0x8(%a6),0x8(%a0)
2640 bsr.l tag
2641 mov.b %d0,STAG(%a6)
2642 mov.b %d0,%d1
2643
2644 andi.l &0x00ff00ff,USER_FPSR(%a6)
2645
2646 clr.l %d0
2647 mov.b FPCR_MODE(%a6),%d0
2648
2649 tst.b %d1
2650 bne.b _L11_2x
2651 bsr.l stwotox
2652 bra.b _L11_6x
2653_L11_2x:
2654 cmpi.b %d1,&ZERO
2655 bne.b _L11_3x
2656 bsr.l ld_pone
2657 bra.b _L11_6x
2658_L11_3x:
2659 cmpi.b %d1,&INF
2660 bne.b _L11_4x
2661 bsr.l szr_inf
2662 bra.b _L11_6x
2663_L11_4x:
2664 cmpi.b %d1,&QNAN
2665 bne.b _L11_5x
2666 bsr.l src_qnan
2667 bra.b _L11_6x
2668_L11_5x:
2669 bsr.l stwotoxd
2670_L11_6x:
2671
2672
2673
2674
2675 movm.l EXC_DREGS(%a6),&0x0303
2676 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2677 fmovm.x EXC_FP1(%a6),&0x40
2678 unlk %a6
2679 rts
2680
2681
2682
2683
2684
2685 global _ftentoxs_
2686_ftentoxs_:
2687 link %a6,&-LOCAL_SIZE
2688
2689 movm.l &0x0303,EXC_DREGS(%a6)
2690 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2691 fmovm.x &0xc0,EXC_FP0(%a6)
2692
2693 fmov.l &0x0,%fpcr
2694
2695
2696
2697
2698 fmov.s 0x8(%a6),%fp0
2699 fmov.x %fp0,FP_SRC(%a6)
2700 lea FP_SRC(%a6),%a0
2701 bsr.l tag
2702 mov.b %d0,STAG(%a6)
2703 mov.b %d0,%d1
2704
2705 andi.l &0x00ff00ff,USER_FPSR(%a6)
2706
2707 clr.l %d0
2708 mov.b FPCR_MODE(%a6),%d0
2709
2710 tst.b %d1
2711 bne.b _L12_2s
2712 bsr.l stentox
2713 bra.b _L12_6s
2714_L12_2s:
2715 cmpi.b %d1,&ZERO
2716 bne.b _L12_3s
2717 bsr.l ld_pone
2718 bra.b _L12_6s
2719_L12_3s:
2720 cmpi.b %d1,&INF
2721 bne.b _L12_4s
2722 bsr.l szr_inf
2723 bra.b _L12_6s
2724_L12_4s:
2725 cmpi.b %d1,&QNAN
2726 bne.b _L12_5s
2727 bsr.l src_qnan
2728 bra.b _L12_6s
2729_L12_5s:
2730 bsr.l stentoxd
2731_L12_6s:
2732
2733
2734
2735
2736 movm.l EXC_DREGS(%a6),&0x0303
2737 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2738 fmovm.x EXC_FP1(%a6),&0x40
2739 unlk %a6
2740 rts
2741
2742 global _ftentoxd_
2743_ftentoxd_:
2744 link %a6,&-LOCAL_SIZE
2745
2746 movm.l &0x0303,EXC_DREGS(%a6)
2747 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2748 fmovm.x &0xc0,EXC_FP0(%a6)
2749
2750 fmov.l &0x0,%fpcr
2751
2752
2753
2754
2755 fmov.d 0x8(%a6),%fp0
2756 fmov.x %fp0,FP_SRC(%a6)
2757 lea FP_SRC(%a6),%a0
2758 bsr.l tag
2759 mov.b %d0,STAG(%a6)
2760 mov.b %d0,%d1
2761
2762 andi.l &0x00ff00ff,USER_FPSR(%a6)
2763
2764 clr.l %d0
2765 mov.b FPCR_MODE(%a6),%d0
2766
2767 mov.b %d1,STAG(%a6)
2768 tst.b %d1
2769 bne.b _L12_2d
2770 bsr.l stentox
2771 bra.b _L12_6d
2772_L12_2d:
2773 cmpi.b %d1,&ZERO
2774 bne.b _L12_3d
2775 bsr.l ld_pone
2776 bra.b _L12_6d
2777_L12_3d:
2778 cmpi.b %d1,&INF
2779 bne.b _L12_4d
2780 bsr.l szr_inf
2781 bra.b _L12_6d
2782_L12_4d:
2783 cmpi.b %d1,&QNAN
2784 bne.b _L12_5d
2785 bsr.l src_qnan
2786 bra.b _L12_6d
2787_L12_5d:
2788 bsr.l stentoxd
2789_L12_6d:
2790
2791
2792
2793
2794 movm.l EXC_DREGS(%a6),&0x0303
2795 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2796 fmovm.x EXC_FP1(%a6),&0x40
2797 unlk %a6
2798 rts
2799
2800 global _ftentoxx_
2801_ftentoxx_:
2802 link %a6,&-LOCAL_SIZE
2803
2804 movm.l &0x0303,EXC_DREGS(%a6)
2805 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2806 fmovm.x &0xc0,EXC_FP0(%a6)
2807
2808 fmov.l &0x0,%fpcr
2809
2810
2811
2812
2813 lea FP_SRC(%a6),%a0
2814 mov.l 0x8+0x0(%a6),0x0(%a0)
2815 mov.l 0x8+0x4(%a6),0x4(%a0)
2816 mov.l 0x8+0x8(%a6),0x8(%a0)
2817 bsr.l tag
2818 mov.b %d0,STAG(%a6)
2819 mov.b %d0,%d1
2820
2821 andi.l &0x00ff00ff,USER_FPSR(%a6)
2822
2823 clr.l %d0
2824 mov.b FPCR_MODE(%a6),%d0
2825
2826 tst.b %d1
2827 bne.b _L12_2x
2828 bsr.l stentox
2829 bra.b _L12_6x
2830_L12_2x:
2831 cmpi.b %d1,&ZERO
2832 bne.b _L12_3x
2833 bsr.l ld_pone
2834 bra.b _L12_6x
2835_L12_3x:
2836 cmpi.b %d1,&INF
2837 bne.b _L12_4x
2838 bsr.l szr_inf
2839 bra.b _L12_6x
2840_L12_4x:
2841 cmpi.b %d1,&QNAN
2842 bne.b _L12_5x
2843 bsr.l src_qnan
2844 bra.b _L12_6x
2845_L12_5x:
2846 bsr.l stentoxd
2847_L12_6x:
2848
2849
2850
2851
2852 movm.l EXC_DREGS(%a6),&0x0303
2853 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2854 fmovm.x EXC_FP1(%a6),&0x40
2855 unlk %a6
2856 rts
2857
2858
2859
2860
2861
2862 global _flogns_
2863_flogns_:
2864 link %a6,&-LOCAL_SIZE
2865
2866 movm.l &0x0303,EXC_DREGS(%a6)
2867 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2868 fmovm.x &0xc0,EXC_FP0(%a6)
2869
2870 fmov.l &0x0,%fpcr
2871
2872
2873
2874
2875 fmov.s 0x8(%a6),%fp0
2876 fmov.x %fp0,FP_SRC(%a6)
2877 lea FP_SRC(%a6),%a0
2878 bsr.l tag
2879 mov.b %d0,STAG(%a6)
2880 mov.b %d0,%d1
2881
2882 andi.l &0x00ff00ff,USER_FPSR(%a6)
2883
2884 clr.l %d0
2885 mov.b FPCR_MODE(%a6),%d0
2886
2887 tst.b %d1
2888 bne.b _L13_2s
2889 bsr.l slogn
2890 bra.b _L13_6s
2891_L13_2s:
2892 cmpi.b %d1,&ZERO
2893 bne.b _L13_3s
2894 bsr.l t_dz2
2895 bra.b _L13_6s
2896_L13_3s:
2897 cmpi.b %d1,&INF
2898 bne.b _L13_4s
2899 bsr.l sopr_inf
2900 bra.b _L13_6s
2901_L13_4s:
2902 cmpi.b %d1,&QNAN
2903 bne.b _L13_5s
2904 bsr.l src_qnan
2905 bra.b _L13_6s
2906_L13_5s:
2907 bsr.l slognd
2908_L13_6s:
2909
2910
2911
2912
2913 movm.l EXC_DREGS(%a6),&0x0303
2914 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2915 fmovm.x EXC_FP1(%a6),&0x40
2916 unlk %a6
2917 rts
2918
2919 global _flognd_
2920_flognd_:
2921 link %a6,&-LOCAL_SIZE
2922
2923 movm.l &0x0303,EXC_DREGS(%a6)
2924 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2925 fmovm.x &0xc0,EXC_FP0(%a6)
2926
2927 fmov.l &0x0,%fpcr
2928
2929
2930
2931
2932 fmov.d 0x8(%a6),%fp0
2933 fmov.x %fp0,FP_SRC(%a6)
2934 lea FP_SRC(%a6),%a0
2935 bsr.l tag
2936 mov.b %d0,STAG(%a6)
2937 mov.b %d0,%d1
2938
2939 andi.l &0x00ff00ff,USER_FPSR(%a6)
2940
2941 clr.l %d0
2942 mov.b FPCR_MODE(%a6),%d0
2943
2944 mov.b %d1,STAG(%a6)
2945 tst.b %d1
2946 bne.b _L13_2d
2947 bsr.l slogn
2948 bra.b _L13_6d
2949_L13_2d:
2950 cmpi.b %d1,&ZERO
2951 bne.b _L13_3d
2952 bsr.l t_dz2
2953 bra.b _L13_6d
2954_L13_3d:
2955 cmpi.b %d1,&INF
2956 bne.b _L13_4d
2957 bsr.l sopr_inf
2958 bra.b _L13_6d
2959_L13_4d:
2960 cmpi.b %d1,&QNAN
2961 bne.b _L13_5d
2962 bsr.l src_qnan
2963 bra.b _L13_6d
2964_L13_5d:
2965 bsr.l slognd
2966_L13_6d:
2967
2968
2969
2970
2971 movm.l EXC_DREGS(%a6),&0x0303
2972 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
2973 fmovm.x EXC_FP1(%a6),&0x40
2974 unlk %a6
2975 rts
2976
2977 global _flognx_
2978_flognx_:
2979 link %a6,&-LOCAL_SIZE
2980
2981 movm.l &0x0303,EXC_DREGS(%a6)
2982 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
2983 fmovm.x &0xc0,EXC_FP0(%a6)
2984
2985 fmov.l &0x0,%fpcr
2986
2987
2988
2989
2990 lea FP_SRC(%a6),%a0
2991 mov.l 0x8+0x0(%a6),0x0(%a0)
2992 mov.l 0x8+0x4(%a6),0x4(%a0)
2993 mov.l 0x8+0x8(%a6),0x8(%a0)
2994 bsr.l tag
2995 mov.b %d0,STAG(%a6)
2996 mov.b %d0,%d1
2997
2998 andi.l &0x00ff00ff,USER_FPSR(%a6)
2999
3000 clr.l %d0
3001 mov.b FPCR_MODE(%a6),%d0
3002
3003 tst.b %d1
3004 bne.b _L13_2x
3005 bsr.l slogn
3006 bra.b _L13_6x
3007_L13_2x:
3008 cmpi.b %d1,&ZERO
3009 bne.b _L13_3x
3010 bsr.l t_dz2
3011 bra.b _L13_6x
3012_L13_3x:
3013 cmpi.b %d1,&INF
3014 bne.b _L13_4x
3015 bsr.l sopr_inf
3016 bra.b _L13_6x
3017_L13_4x:
3018 cmpi.b %d1,&QNAN
3019 bne.b _L13_5x
3020 bsr.l src_qnan
3021 bra.b _L13_6x
3022_L13_5x:
3023 bsr.l slognd
3024_L13_6x:
3025
3026
3027
3028
3029 movm.l EXC_DREGS(%a6),&0x0303
3030 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3031 fmovm.x EXC_FP1(%a6),&0x40
3032 unlk %a6
3033 rts
3034
3035
3036
3037
3038
3039 global _flog10s_
3040_flog10s_:
3041 link %a6,&-LOCAL_SIZE
3042
3043 movm.l &0x0303,EXC_DREGS(%a6)
3044 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3045 fmovm.x &0xc0,EXC_FP0(%a6)
3046
3047 fmov.l &0x0,%fpcr
3048
3049
3050
3051
3052 fmov.s 0x8(%a6),%fp0
3053 fmov.x %fp0,FP_SRC(%a6)
3054 lea FP_SRC(%a6),%a0
3055 bsr.l tag
3056 mov.b %d0,STAG(%a6)
3057 mov.b %d0,%d1
3058
3059 andi.l &0x00ff00ff,USER_FPSR(%a6)
3060
3061 clr.l %d0
3062 mov.b FPCR_MODE(%a6),%d0
3063
3064 tst.b %d1
3065 bne.b _L14_2s
3066 bsr.l slog10
3067 bra.b _L14_6s
3068_L14_2s:
3069 cmpi.b %d1,&ZERO
3070 bne.b _L14_3s
3071 bsr.l t_dz2
3072 bra.b _L14_6s
3073_L14_3s:
3074 cmpi.b %d1,&INF
3075 bne.b _L14_4s
3076 bsr.l sopr_inf
3077 bra.b _L14_6s
3078_L14_4s:
3079 cmpi.b %d1,&QNAN
3080 bne.b _L14_5s
3081 bsr.l src_qnan
3082 bra.b _L14_6s
3083_L14_5s:
3084 bsr.l slog10d
3085_L14_6s:
3086
3087
3088
3089
3090 movm.l EXC_DREGS(%a6),&0x0303
3091 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3092 fmovm.x EXC_FP1(%a6),&0x40
3093 unlk %a6
3094 rts
3095
3096 global _flog10d_
3097_flog10d_:
3098 link %a6,&-LOCAL_SIZE
3099
3100 movm.l &0x0303,EXC_DREGS(%a6)
3101 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3102 fmovm.x &0xc0,EXC_FP0(%a6)
3103
3104 fmov.l &0x0,%fpcr
3105
3106
3107
3108
3109 fmov.d 0x8(%a6),%fp0
3110 fmov.x %fp0,FP_SRC(%a6)
3111 lea FP_SRC(%a6),%a0
3112 bsr.l tag
3113 mov.b %d0,STAG(%a6)
3114 mov.b %d0,%d1
3115
3116 andi.l &0x00ff00ff,USER_FPSR(%a6)
3117
3118 clr.l %d0
3119 mov.b FPCR_MODE(%a6),%d0
3120
3121 mov.b %d1,STAG(%a6)
3122 tst.b %d1
3123 bne.b _L14_2d
3124 bsr.l slog10
3125 bra.b _L14_6d
3126_L14_2d:
3127 cmpi.b %d1,&ZERO
3128 bne.b _L14_3d
3129 bsr.l t_dz2
3130 bra.b _L14_6d
3131_L14_3d:
3132 cmpi.b %d1,&INF
3133 bne.b _L14_4d
3134 bsr.l sopr_inf
3135 bra.b _L14_6d
3136_L14_4d:
3137 cmpi.b %d1,&QNAN
3138 bne.b _L14_5d
3139 bsr.l src_qnan
3140 bra.b _L14_6d
3141_L14_5d:
3142 bsr.l slog10d
3143_L14_6d:
3144
3145
3146
3147
3148 movm.l EXC_DREGS(%a6),&0x0303
3149 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3150 fmovm.x EXC_FP1(%a6),&0x40
3151 unlk %a6
3152 rts
3153
3154 global _flog10x_
3155_flog10x_:
3156 link %a6,&-LOCAL_SIZE
3157
3158 movm.l &0x0303,EXC_DREGS(%a6)
3159 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3160 fmovm.x &0xc0,EXC_FP0(%a6)
3161
3162 fmov.l &0x0,%fpcr
3163
3164
3165
3166
3167 lea FP_SRC(%a6),%a0
3168 mov.l 0x8+0x0(%a6),0x0(%a0)
3169 mov.l 0x8+0x4(%a6),0x4(%a0)
3170 mov.l 0x8+0x8(%a6),0x8(%a0)
3171 bsr.l tag
3172 mov.b %d0,STAG(%a6)
3173 mov.b %d0,%d1
3174
3175 andi.l &0x00ff00ff,USER_FPSR(%a6)
3176
3177 clr.l %d0
3178 mov.b FPCR_MODE(%a6),%d0
3179
3180 tst.b %d1
3181 bne.b _L14_2x
3182 bsr.l slog10
3183 bra.b _L14_6x
3184_L14_2x:
3185 cmpi.b %d1,&ZERO
3186 bne.b _L14_3x
3187 bsr.l t_dz2
3188 bra.b _L14_6x
3189_L14_3x:
3190 cmpi.b %d1,&INF
3191 bne.b _L14_4x
3192 bsr.l sopr_inf
3193 bra.b _L14_6x
3194_L14_4x:
3195 cmpi.b %d1,&QNAN
3196 bne.b _L14_5x
3197 bsr.l src_qnan
3198 bra.b _L14_6x
3199_L14_5x:
3200 bsr.l slog10d
3201_L14_6x:
3202
3203
3204
3205
3206 movm.l EXC_DREGS(%a6),&0x0303
3207 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3208 fmovm.x EXC_FP1(%a6),&0x40
3209 unlk %a6
3210 rts
3211
3212
3213
3214
3215
3216 global _flog2s_
3217_flog2s_:
3218 link %a6,&-LOCAL_SIZE
3219
3220 movm.l &0x0303,EXC_DREGS(%a6)
3221 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3222 fmovm.x &0xc0,EXC_FP0(%a6)
3223
3224 fmov.l &0x0,%fpcr
3225
3226
3227
3228
3229 fmov.s 0x8(%a6),%fp0
3230 fmov.x %fp0,FP_SRC(%a6)
3231 lea FP_SRC(%a6),%a0
3232 bsr.l tag
3233 mov.b %d0,STAG(%a6)
3234 mov.b %d0,%d1
3235
3236 andi.l &0x00ff00ff,USER_FPSR(%a6)
3237
3238 clr.l %d0
3239 mov.b FPCR_MODE(%a6),%d0
3240
3241 tst.b %d1
3242 bne.b _L15_2s
3243 bsr.l slog2
3244 bra.b _L15_6s
3245_L15_2s:
3246 cmpi.b %d1,&ZERO
3247 bne.b _L15_3s
3248 bsr.l t_dz2
3249 bra.b _L15_6s
3250_L15_3s:
3251 cmpi.b %d1,&INF
3252 bne.b _L15_4s
3253 bsr.l sopr_inf
3254 bra.b _L15_6s
3255_L15_4s:
3256 cmpi.b %d1,&QNAN
3257 bne.b _L15_5s
3258 bsr.l src_qnan
3259 bra.b _L15_6s
3260_L15_5s:
3261 bsr.l slog2d
3262_L15_6s:
3263
3264
3265
3266
3267 movm.l EXC_DREGS(%a6),&0x0303
3268 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3269 fmovm.x EXC_FP1(%a6),&0x40
3270 unlk %a6
3271 rts
3272
3273 global _flog2d_
3274_flog2d_:
3275 link %a6,&-LOCAL_SIZE
3276
3277 movm.l &0x0303,EXC_DREGS(%a6)
3278 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3279 fmovm.x &0xc0,EXC_FP0(%a6)
3280
3281 fmov.l &0x0,%fpcr
3282
3283
3284
3285
3286 fmov.d 0x8(%a6),%fp0
3287 fmov.x %fp0,FP_SRC(%a6)
3288 lea FP_SRC(%a6),%a0
3289 bsr.l tag
3290 mov.b %d0,STAG(%a6)
3291 mov.b %d0,%d1
3292
3293 andi.l &0x00ff00ff,USER_FPSR(%a6)
3294
3295 clr.l %d0
3296 mov.b FPCR_MODE(%a6),%d0
3297
3298 mov.b %d1,STAG(%a6)
3299 tst.b %d1
3300 bne.b _L15_2d
3301 bsr.l slog2
3302 bra.b _L15_6d
3303_L15_2d:
3304 cmpi.b %d1,&ZERO
3305 bne.b _L15_3d
3306 bsr.l t_dz2
3307 bra.b _L15_6d
3308_L15_3d:
3309 cmpi.b %d1,&INF
3310 bne.b _L15_4d
3311 bsr.l sopr_inf
3312 bra.b _L15_6d
3313_L15_4d:
3314 cmpi.b %d1,&QNAN
3315 bne.b _L15_5d
3316 bsr.l src_qnan
3317 bra.b _L15_6d
3318_L15_5d:
3319 bsr.l slog2d
3320_L15_6d:
3321
3322
3323
3324
3325 movm.l EXC_DREGS(%a6),&0x0303
3326 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3327 fmovm.x EXC_FP1(%a6),&0x40
3328 unlk %a6
3329 rts
3330
3331 global _flog2x_
3332_flog2x_:
3333 link %a6,&-LOCAL_SIZE
3334
3335 movm.l &0x0303,EXC_DREGS(%a6)
3336 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3337 fmovm.x &0xc0,EXC_FP0(%a6)
3338
3339 fmov.l &0x0,%fpcr
3340
3341
3342
3343
3344 lea FP_SRC(%a6),%a0
3345 mov.l 0x8+0x0(%a6),0x0(%a0)
3346 mov.l 0x8+0x4(%a6),0x4(%a0)
3347 mov.l 0x8+0x8(%a6),0x8(%a0)
3348 bsr.l tag
3349 mov.b %d0,STAG(%a6)
3350 mov.b %d0,%d1
3351
3352 andi.l &0x00ff00ff,USER_FPSR(%a6)
3353
3354 clr.l %d0
3355 mov.b FPCR_MODE(%a6),%d0
3356
3357 tst.b %d1
3358 bne.b _L15_2x
3359 bsr.l slog2
3360 bra.b _L15_6x
3361_L15_2x:
3362 cmpi.b %d1,&ZERO
3363 bne.b _L15_3x
3364 bsr.l t_dz2
3365 bra.b _L15_6x
3366_L15_3x:
3367 cmpi.b %d1,&INF
3368 bne.b _L15_4x
3369 bsr.l sopr_inf
3370 bra.b _L15_6x
3371_L15_4x:
3372 cmpi.b %d1,&QNAN
3373 bne.b _L15_5x
3374 bsr.l src_qnan
3375 bra.b _L15_6x
3376_L15_5x:
3377 bsr.l slog2d
3378_L15_6x:
3379
3380
3381
3382
3383 movm.l EXC_DREGS(%a6),&0x0303
3384 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3385 fmovm.x EXC_FP1(%a6),&0x40
3386 unlk %a6
3387 rts
3388
3389
3390
3391
3392
3393 global _fcoshs_
3394_fcoshs_:
3395 link %a6,&-LOCAL_SIZE
3396
3397 movm.l &0x0303,EXC_DREGS(%a6)
3398 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3399 fmovm.x &0xc0,EXC_FP0(%a6)
3400
3401 fmov.l &0x0,%fpcr
3402
3403
3404
3405
3406 fmov.s 0x8(%a6),%fp0
3407 fmov.x %fp0,FP_SRC(%a6)
3408 lea FP_SRC(%a6),%a0
3409 bsr.l tag
3410 mov.b %d0,STAG(%a6)
3411 mov.b %d0,%d1
3412
3413 andi.l &0x00ff00ff,USER_FPSR(%a6)
3414
3415 clr.l %d0
3416 mov.b FPCR_MODE(%a6),%d0
3417
3418 tst.b %d1
3419 bne.b _L16_2s
3420 bsr.l scosh
3421 bra.b _L16_6s
3422_L16_2s:
3423 cmpi.b %d1,&ZERO
3424 bne.b _L16_3s
3425 bsr.l ld_pone
3426 bra.b _L16_6s
3427_L16_3s:
3428 cmpi.b %d1,&INF
3429 bne.b _L16_4s
3430 bsr.l ld_pinf
3431 bra.b _L16_6s
3432_L16_4s:
3433 cmpi.b %d1,&QNAN
3434 bne.b _L16_5s
3435 bsr.l src_qnan
3436 bra.b _L16_6s
3437_L16_5s:
3438 bsr.l scoshd
3439_L16_6s:
3440
3441
3442
3443
3444 movm.l EXC_DREGS(%a6),&0x0303
3445 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3446 fmovm.x EXC_FP1(%a6),&0x40
3447 unlk %a6
3448 rts
3449
3450 global _fcoshd_
3451_fcoshd_:
3452 link %a6,&-LOCAL_SIZE
3453
3454 movm.l &0x0303,EXC_DREGS(%a6)
3455 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3456 fmovm.x &0xc0,EXC_FP0(%a6)
3457
3458 fmov.l &0x0,%fpcr
3459
3460
3461
3462
3463 fmov.d 0x8(%a6),%fp0
3464 fmov.x %fp0,FP_SRC(%a6)
3465 lea FP_SRC(%a6),%a0
3466 bsr.l tag
3467 mov.b %d0,STAG(%a6)
3468 mov.b %d0,%d1
3469
3470 andi.l &0x00ff00ff,USER_FPSR(%a6)
3471
3472 clr.l %d0
3473 mov.b FPCR_MODE(%a6),%d0
3474
3475 mov.b %d1,STAG(%a6)
3476 tst.b %d1
3477 bne.b _L16_2d
3478 bsr.l scosh
3479 bra.b _L16_6d
3480_L16_2d:
3481 cmpi.b %d1,&ZERO
3482 bne.b _L16_3d
3483 bsr.l ld_pone
3484 bra.b _L16_6d
3485_L16_3d:
3486 cmpi.b %d1,&INF
3487 bne.b _L16_4d
3488 bsr.l ld_pinf
3489 bra.b _L16_6d
3490_L16_4d:
3491 cmpi.b %d1,&QNAN
3492 bne.b _L16_5d
3493 bsr.l src_qnan
3494 bra.b _L16_6d
3495_L16_5d:
3496 bsr.l scoshd
3497_L16_6d:
3498
3499
3500
3501
3502 movm.l EXC_DREGS(%a6),&0x0303
3503 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3504 fmovm.x EXC_FP1(%a6),&0x40
3505 unlk %a6
3506 rts
3507
3508 global _fcoshx_
3509_fcoshx_:
3510 link %a6,&-LOCAL_SIZE
3511
3512 movm.l &0x0303,EXC_DREGS(%a6)
3513 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3514 fmovm.x &0xc0,EXC_FP0(%a6)
3515
3516 fmov.l &0x0,%fpcr
3517
3518
3519
3520
3521 lea FP_SRC(%a6),%a0
3522 mov.l 0x8+0x0(%a6),0x0(%a0)
3523 mov.l 0x8+0x4(%a6),0x4(%a0)
3524 mov.l 0x8+0x8(%a6),0x8(%a0)
3525 bsr.l tag
3526 mov.b %d0,STAG(%a6)
3527 mov.b %d0,%d1
3528
3529 andi.l &0x00ff00ff,USER_FPSR(%a6)
3530
3531 clr.l %d0
3532 mov.b FPCR_MODE(%a6),%d0
3533
3534 tst.b %d1
3535 bne.b _L16_2x
3536 bsr.l scosh
3537 bra.b _L16_6x
3538_L16_2x:
3539 cmpi.b %d1,&ZERO
3540 bne.b _L16_3x
3541 bsr.l ld_pone
3542 bra.b _L16_6x
3543_L16_3x:
3544 cmpi.b %d1,&INF
3545 bne.b _L16_4x
3546 bsr.l ld_pinf
3547 bra.b _L16_6x
3548_L16_4x:
3549 cmpi.b %d1,&QNAN
3550 bne.b _L16_5x
3551 bsr.l src_qnan
3552 bra.b _L16_6x
3553_L16_5x:
3554 bsr.l scoshd
3555_L16_6x:
3556
3557
3558
3559
3560 movm.l EXC_DREGS(%a6),&0x0303
3561 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3562 fmovm.x EXC_FP1(%a6),&0x40
3563 unlk %a6
3564 rts
3565
3566
3567
3568
3569
3570 global _facoss_
3571_facoss_:
3572 link %a6,&-LOCAL_SIZE
3573
3574 movm.l &0x0303,EXC_DREGS(%a6)
3575 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3576 fmovm.x &0xc0,EXC_FP0(%a6)
3577
3578 fmov.l &0x0,%fpcr
3579
3580
3581
3582
3583 fmov.s 0x8(%a6),%fp0
3584 fmov.x %fp0,FP_SRC(%a6)
3585 lea FP_SRC(%a6),%a0
3586 bsr.l tag
3587 mov.b %d0,STAG(%a6)
3588 mov.b %d0,%d1
3589
3590 andi.l &0x00ff00ff,USER_FPSR(%a6)
3591
3592 clr.l %d0
3593 mov.b FPCR_MODE(%a6),%d0
3594
3595 tst.b %d1
3596 bne.b _L17_2s
3597 bsr.l sacos
3598 bra.b _L17_6s
3599_L17_2s:
3600 cmpi.b %d1,&ZERO
3601 bne.b _L17_3s
3602 bsr.l ld_ppi2
3603 bra.b _L17_6s
3604_L17_3s:
3605 cmpi.b %d1,&INF
3606 bne.b _L17_4s
3607 bsr.l t_operr
3608 bra.b _L17_6s
3609_L17_4s:
3610 cmpi.b %d1,&QNAN
3611 bne.b _L17_5s
3612 bsr.l src_qnan
3613 bra.b _L17_6s
3614_L17_5s:
3615 bsr.l sacosd
3616_L17_6s:
3617
3618
3619
3620
3621 movm.l EXC_DREGS(%a6),&0x0303
3622 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3623 fmovm.x EXC_FP1(%a6),&0x40
3624 unlk %a6
3625 rts
3626
3627 global _facosd_
3628_facosd_:
3629 link %a6,&-LOCAL_SIZE
3630
3631 movm.l &0x0303,EXC_DREGS(%a6)
3632 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3633 fmovm.x &0xc0,EXC_FP0(%a6)
3634
3635 fmov.l &0x0,%fpcr
3636
3637
3638
3639
3640 fmov.d 0x8(%a6),%fp0
3641 fmov.x %fp0,FP_SRC(%a6)
3642 lea FP_SRC(%a6),%a0
3643 bsr.l tag
3644 mov.b %d0,STAG(%a6)
3645 mov.b %d0,%d1
3646
3647 andi.l &0x00ff00ff,USER_FPSR(%a6)
3648
3649 clr.l %d0
3650 mov.b FPCR_MODE(%a6),%d0
3651
3652 mov.b %d1,STAG(%a6)
3653 tst.b %d1
3654 bne.b _L17_2d
3655 bsr.l sacos
3656 bra.b _L17_6d
3657_L17_2d:
3658 cmpi.b %d1,&ZERO
3659 bne.b _L17_3d
3660 bsr.l ld_ppi2
3661 bra.b _L17_6d
3662_L17_3d:
3663 cmpi.b %d1,&INF
3664 bne.b _L17_4d
3665 bsr.l t_operr
3666 bra.b _L17_6d
3667_L17_4d:
3668 cmpi.b %d1,&QNAN
3669 bne.b _L17_5d
3670 bsr.l src_qnan
3671 bra.b _L17_6d
3672_L17_5d:
3673 bsr.l sacosd
3674_L17_6d:
3675
3676
3677
3678
3679 movm.l EXC_DREGS(%a6),&0x0303
3680 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3681 fmovm.x EXC_FP1(%a6),&0x40
3682 unlk %a6
3683 rts
3684
3685 global _facosx_
3686_facosx_:
3687 link %a6,&-LOCAL_SIZE
3688
3689 movm.l &0x0303,EXC_DREGS(%a6)
3690 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3691 fmovm.x &0xc0,EXC_FP0(%a6)
3692
3693 fmov.l &0x0,%fpcr
3694
3695
3696
3697
3698 lea FP_SRC(%a6),%a0
3699 mov.l 0x8+0x0(%a6),0x0(%a0)
3700 mov.l 0x8+0x4(%a6),0x4(%a0)
3701 mov.l 0x8+0x8(%a6),0x8(%a0)
3702 bsr.l tag
3703 mov.b %d0,STAG(%a6)
3704 mov.b %d0,%d1
3705
3706 andi.l &0x00ff00ff,USER_FPSR(%a6)
3707
3708 clr.l %d0
3709 mov.b FPCR_MODE(%a6),%d0
3710
3711 tst.b %d1
3712 bne.b _L17_2x
3713 bsr.l sacos
3714 bra.b _L17_6x
3715_L17_2x:
3716 cmpi.b %d1,&ZERO
3717 bne.b _L17_3x
3718 bsr.l ld_ppi2
3719 bra.b _L17_6x
3720_L17_3x:
3721 cmpi.b %d1,&INF
3722 bne.b _L17_4x
3723 bsr.l t_operr
3724 bra.b _L17_6x
3725_L17_4x:
3726 cmpi.b %d1,&QNAN
3727 bne.b _L17_5x
3728 bsr.l src_qnan
3729 bra.b _L17_6x
3730_L17_5x:
3731 bsr.l sacosd
3732_L17_6x:
3733
3734
3735
3736
3737 movm.l EXC_DREGS(%a6),&0x0303
3738 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3739 fmovm.x EXC_FP1(%a6),&0x40
3740 unlk %a6
3741 rts
3742
3743
3744
3745
3746
3747 global _fgetexps_
3748_fgetexps_:
3749 link %a6,&-LOCAL_SIZE
3750
3751 movm.l &0x0303,EXC_DREGS(%a6)
3752 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3753 fmovm.x &0xc0,EXC_FP0(%a6)
3754
3755 fmov.l &0x0,%fpcr
3756
3757
3758
3759
3760 fmov.s 0x8(%a6),%fp0
3761 fmov.x %fp0,FP_SRC(%a6)
3762 lea FP_SRC(%a6),%a0
3763 bsr.l tag
3764 mov.b %d0,STAG(%a6)
3765 mov.b %d0,%d1
3766
3767 andi.l &0x00ff00ff,USER_FPSR(%a6)
3768
3769 clr.l %d0
3770 mov.b FPCR_MODE(%a6),%d0
3771
3772 tst.b %d1
3773 bne.b _L18_2s
3774 bsr.l sgetexp
3775 bra.b _L18_6s
3776_L18_2s:
3777 cmpi.b %d1,&ZERO
3778 bne.b _L18_3s
3779 bsr.l src_zero
3780 bra.b _L18_6s
3781_L18_3s:
3782 cmpi.b %d1,&INF
3783 bne.b _L18_4s
3784 bsr.l t_operr
3785 bra.b _L18_6s
3786_L18_4s:
3787 cmpi.b %d1,&QNAN
3788 bne.b _L18_5s
3789 bsr.l src_qnan
3790 bra.b _L18_6s
3791_L18_5s:
3792 bsr.l sgetexpd
3793_L18_6s:
3794
3795
3796
3797
3798 movm.l EXC_DREGS(%a6),&0x0303
3799 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3800 fmovm.x EXC_FP1(%a6),&0x40
3801 unlk %a6
3802 rts
3803
3804 global _fgetexpd_
3805_fgetexpd_:
3806 link %a6,&-LOCAL_SIZE
3807
3808 movm.l &0x0303,EXC_DREGS(%a6)
3809 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3810 fmovm.x &0xc0,EXC_FP0(%a6)
3811
3812 fmov.l &0x0,%fpcr
3813
3814
3815
3816
3817 fmov.d 0x8(%a6),%fp0
3818 fmov.x %fp0,FP_SRC(%a6)
3819 lea FP_SRC(%a6),%a0
3820 bsr.l tag
3821 mov.b %d0,STAG(%a6)
3822 mov.b %d0,%d1
3823
3824 andi.l &0x00ff00ff,USER_FPSR(%a6)
3825
3826 clr.l %d0
3827 mov.b FPCR_MODE(%a6),%d0
3828
3829 mov.b %d1,STAG(%a6)
3830 tst.b %d1
3831 bne.b _L18_2d
3832 bsr.l sgetexp
3833 bra.b _L18_6d
3834_L18_2d:
3835 cmpi.b %d1,&ZERO
3836 bne.b _L18_3d
3837 bsr.l src_zero
3838 bra.b _L18_6d
3839_L18_3d:
3840 cmpi.b %d1,&INF
3841 bne.b _L18_4d
3842 bsr.l t_operr
3843 bra.b _L18_6d
3844_L18_4d:
3845 cmpi.b %d1,&QNAN
3846 bne.b _L18_5d
3847 bsr.l src_qnan
3848 bra.b _L18_6d
3849_L18_5d:
3850 bsr.l sgetexpd
3851_L18_6d:
3852
3853
3854
3855
3856 movm.l EXC_DREGS(%a6),&0x0303
3857 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3858 fmovm.x EXC_FP1(%a6),&0x40
3859 unlk %a6
3860 rts
3861
3862 global _fgetexpx_
3863_fgetexpx_:
3864 link %a6,&-LOCAL_SIZE
3865
3866 movm.l &0x0303,EXC_DREGS(%a6)
3867 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3868 fmovm.x &0xc0,EXC_FP0(%a6)
3869
3870 fmov.l &0x0,%fpcr
3871
3872
3873
3874
3875 lea FP_SRC(%a6),%a0
3876 mov.l 0x8+0x0(%a6),0x0(%a0)
3877 mov.l 0x8+0x4(%a6),0x4(%a0)
3878 mov.l 0x8+0x8(%a6),0x8(%a0)
3879 bsr.l tag
3880 mov.b %d0,STAG(%a6)
3881 mov.b %d0,%d1
3882
3883 andi.l &0x00ff00ff,USER_FPSR(%a6)
3884
3885 clr.l %d0
3886 mov.b FPCR_MODE(%a6),%d0
3887
3888 tst.b %d1
3889 bne.b _L18_2x
3890 bsr.l sgetexp
3891 bra.b _L18_6x
3892_L18_2x:
3893 cmpi.b %d1,&ZERO
3894 bne.b _L18_3x
3895 bsr.l src_zero
3896 bra.b _L18_6x
3897_L18_3x:
3898 cmpi.b %d1,&INF
3899 bne.b _L18_4x
3900 bsr.l t_operr
3901 bra.b _L18_6x
3902_L18_4x:
3903 cmpi.b %d1,&QNAN
3904 bne.b _L18_5x
3905 bsr.l src_qnan
3906 bra.b _L18_6x
3907_L18_5x:
3908 bsr.l sgetexpd
3909_L18_6x:
3910
3911
3912
3913
3914 movm.l EXC_DREGS(%a6),&0x0303
3915 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3916 fmovm.x EXC_FP1(%a6),&0x40
3917 unlk %a6
3918 rts
3919
3920
3921
3922
3923
3924 global _fgetmans_
3925_fgetmans_:
3926 link %a6,&-LOCAL_SIZE
3927
3928 movm.l &0x0303,EXC_DREGS(%a6)
3929 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3930 fmovm.x &0xc0,EXC_FP0(%a6)
3931
3932 fmov.l &0x0,%fpcr
3933
3934
3935
3936
3937 fmov.s 0x8(%a6),%fp0
3938 fmov.x %fp0,FP_SRC(%a6)
3939 lea FP_SRC(%a6),%a0
3940 bsr.l tag
3941 mov.b %d0,STAG(%a6)
3942 mov.b %d0,%d1
3943
3944 andi.l &0x00ff00ff,USER_FPSR(%a6)
3945
3946 clr.l %d0
3947 mov.b FPCR_MODE(%a6),%d0
3948
3949 tst.b %d1
3950 bne.b _L19_2s
3951 bsr.l sgetman
3952 bra.b _L19_6s
3953_L19_2s:
3954 cmpi.b %d1,&ZERO
3955 bne.b _L19_3s
3956 bsr.l src_zero
3957 bra.b _L19_6s
3958_L19_3s:
3959 cmpi.b %d1,&INF
3960 bne.b _L19_4s
3961 bsr.l t_operr
3962 bra.b _L19_6s
3963_L19_4s:
3964 cmpi.b %d1,&QNAN
3965 bne.b _L19_5s
3966 bsr.l src_qnan
3967 bra.b _L19_6s
3968_L19_5s:
3969 bsr.l sgetmand
3970_L19_6s:
3971
3972
3973
3974
3975 movm.l EXC_DREGS(%a6),&0x0303
3976 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
3977 fmovm.x EXC_FP1(%a6),&0x40
3978 unlk %a6
3979 rts
3980
3981 global _fgetmand_
3982_fgetmand_:
3983 link %a6,&-LOCAL_SIZE
3984
3985 movm.l &0x0303,EXC_DREGS(%a6)
3986 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
3987 fmovm.x &0xc0,EXC_FP0(%a6)
3988
3989 fmov.l &0x0,%fpcr
3990
3991
3992
3993
3994 fmov.d 0x8(%a6),%fp0
3995 fmov.x %fp0,FP_SRC(%a6)
3996 lea FP_SRC(%a6),%a0
3997 bsr.l tag
3998 mov.b %d0,STAG(%a6)
3999 mov.b %d0,%d1
4000
4001 andi.l &0x00ff00ff,USER_FPSR(%a6)
4002
4003 clr.l %d0
4004 mov.b FPCR_MODE(%a6),%d0
4005
4006 mov.b %d1,STAG(%a6)
4007 tst.b %d1
4008 bne.b _L19_2d
4009 bsr.l sgetman
4010 bra.b _L19_6d
4011_L19_2d:
4012 cmpi.b %d1,&ZERO
4013 bne.b _L19_3d
4014 bsr.l src_zero
4015 bra.b _L19_6d
4016_L19_3d:
4017 cmpi.b %d1,&INF
4018 bne.b _L19_4d
4019 bsr.l t_operr
4020 bra.b _L19_6d
4021_L19_4d:
4022 cmpi.b %d1,&QNAN
4023 bne.b _L19_5d
4024 bsr.l src_qnan
4025 bra.b _L19_6d
4026_L19_5d:
4027 bsr.l sgetmand
4028_L19_6d:
4029
4030
4031
4032
4033 movm.l EXC_DREGS(%a6),&0x0303
4034 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4035 fmovm.x EXC_FP1(%a6),&0x40
4036 unlk %a6
4037 rts
4038
4039 global _fgetmanx_
4040_fgetmanx_:
4041 link %a6,&-LOCAL_SIZE
4042
4043 movm.l &0x0303,EXC_DREGS(%a6)
4044 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4045 fmovm.x &0xc0,EXC_FP0(%a6)
4046
4047 fmov.l &0x0,%fpcr
4048
4049
4050
4051
4052 lea FP_SRC(%a6),%a0
4053 mov.l 0x8+0x0(%a6),0x0(%a0)
4054 mov.l 0x8+0x4(%a6),0x4(%a0)
4055 mov.l 0x8+0x8(%a6),0x8(%a0)
4056 bsr.l tag
4057 mov.b %d0,STAG(%a6)
4058 mov.b %d0,%d1
4059
4060 andi.l &0x00ff00ff,USER_FPSR(%a6)
4061
4062 clr.l %d0
4063 mov.b FPCR_MODE(%a6),%d0
4064
4065 tst.b %d1
4066 bne.b _L19_2x
4067 bsr.l sgetman
4068 bra.b _L19_6x
4069_L19_2x:
4070 cmpi.b %d1,&ZERO
4071 bne.b _L19_3x
4072 bsr.l src_zero
4073 bra.b _L19_6x
4074_L19_3x:
4075 cmpi.b %d1,&INF
4076 bne.b _L19_4x
4077 bsr.l t_operr
4078 bra.b _L19_6x
4079_L19_4x:
4080 cmpi.b %d1,&QNAN
4081 bne.b _L19_5x
4082 bsr.l src_qnan
4083 bra.b _L19_6x
4084_L19_5x:
4085 bsr.l sgetmand
4086_L19_6x:
4087
4088
4089
4090
4091 movm.l EXC_DREGS(%a6),&0x0303
4092 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4093 fmovm.x EXC_FP1(%a6),&0x40
4094 unlk %a6
4095 rts
4096
4097
4098
4099
4100
4101 global _fsincoss_
4102_fsincoss_:
4103 link %a6,&-LOCAL_SIZE
4104
4105 movm.l &0x0303,EXC_DREGS(%a6)
4106 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4107 fmovm.x &0xc0,EXC_FP0(%a6)
4108
4109 fmov.l &0x0,%fpcr
4110
4111
4112
4113
4114 fmov.s 0x8(%a6),%fp0
4115 fmov.x %fp0,FP_SRC(%a6)
4116 lea FP_SRC(%a6),%a0
4117 bsr.l tag
4118 mov.b %d0,STAG(%a6)
4119 mov.b %d0,%d1
4120
4121 andi.l &0x00ff00ff,USER_FPSR(%a6)
4122
4123 clr.l %d0
4124 mov.b FPCR_MODE(%a6),%d0
4125
4126 tst.b %d1
4127 bne.b _L20_2s
4128 bsr.l ssincos
4129 bra.b _L20_6s
4130_L20_2s:
4131 cmpi.b %d1,&ZERO
4132 bne.b _L20_3s
4133 bsr.l ssincosz
4134 bra.b _L20_6s
4135_L20_3s:
4136 cmpi.b %d1,&INF
4137 bne.b _L20_4s
4138 bsr.l ssincosi
4139 bra.b _L20_6s
4140_L20_4s:
4141 cmpi.b %d1,&QNAN
4142 bne.b _L20_5s
4143 bsr.l ssincosqnan
4144 bra.b _L20_6s
4145_L20_5s:
4146 bsr.l ssincosd
4147_L20_6s:
4148
4149
4150
4151
4152 movm.l EXC_DREGS(%a6),&0x0303
4153 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4154 fmovm.x &0x03,-(%sp)
4155 fmovm.x (%sp)+,&0x40
4156 fmovm.x (%sp)+,&0x80
4157 unlk %a6
4158 rts
4159
4160 global _fsincosd_
4161_fsincosd_:
4162 link %a6,&-LOCAL_SIZE
4163
4164 movm.l &0x0303,EXC_DREGS(%a6)
4165 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4166 fmovm.x &0xc0,EXC_FP0(%a6)
4167
4168 fmov.l &0x0,%fpcr
4169
4170
4171
4172
4173 fmov.d 0x8(%a6),%fp0
4174 fmov.x %fp0,FP_SRC(%a6)
4175 lea FP_SRC(%a6),%a0
4176 bsr.l tag
4177 mov.b %d0,STAG(%a6)
4178 mov.b %d0,%d1
4179
4180 andi.l &0x00ff00ff,USER_FPSR(%a6)
4181
4182 clr.l %d0
4183 mov.b FPCR_MODE(%a6),%d0
4184
4185 mov.b %d1,STAG(%a6)
4186 tst.b %d1
4187 bne.b _L20_2d
4188 bsr.l ssincos
4189 bra.b _L20_6d
4190_L20_2d:
4191 cmpi.b %d1,&ZERO
4192 bne.b _L20_3d
4193 bsr.l ssincosz
4194 bra.b _L20_6d
4195_L20_3d:
4196 cmpi.b %d1,&INF
4197 bne.b _L20_4d
4198 bsr.l ssincosi
4199 bra.b _L20_6d
4200_L20_4d:
4201 cmpi.b %d1,&QNAN
4202 bne.b _L20_5d
4203 bsr.l ssincosqnan
4204 bra.b _L20_6d
4205_L20_5d:
4206 bsr.l ssincosd
4207_L20_6d:
4208
4209
4210
4211
4212 movm.l EXC_DREGS(%a6),&0x0303
4213 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4214 fmovm.x &0x03,-(%sp)
4215 fmovm.x (%sp)+,&0x40
4216 fmovm.x (%sp)+,&0x80
4217 unlk %a6
4218 rts
4219
4220 global _fsincosx_
4221_fsincosx_:
4222 link %a6,&-LOCAL_SIZE
4223
4224 movm.l &0x0303,EXC_DREGS(%a6)
4225 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4226 fmovm.x &0xc0,EXC_FP0(%a6)
4227
4228 fmov.l &0x0,%fpcr
4229
4230
4231
4232
4233 lea FP_SRC(%a6),%a0
4234 mov.l 0x8+0x0(%a6),0x0(%a0)
4235 mov.l 0x8+0x4(%a6),0x4(%a0)
4236 mov.l 0x8+0x8(%a6),0x8(%a0)
4237 bsr.l tag
4238 mov.b %d0,STAG(%a6)
4239 mov.b %d0,%d1
4240
4241 andi.l &0x00ff00ff,USER_FPSR(%a6)
4242
4243 clr.l %d0
4244 mov.b FPCR_MODE(%a6),%d0
4245
4246 tst.b %d1
4247 bne.b _L20_2x
4248 bsr.l ssincos
4249 bra.b _L20_6x
4250_L20_2x:
4251 cmpi.b %d1,&ZERO
4252 bne.b _L20_3x
4253 bsr.l ssincosz
4254 bra.b _L20_6x
4255_L20_3x:
4256 cmpi.b %d1,&INF
4257 bne.b _L20_4x
4258 bsr.l ssincosi
4259 bra.b _L20_6x
4260_L20_4x:
4261 cmpi.b %d1,&QNAN
4262 bne.b _L20_5x
4263 bsr.l ssincosqnan
4264 bra.b _L20_6x
4265_L20_5x:
4266 bsr.l ssincosd
4267_L20_6x:
4268
4269
4270
4271
4272 movm.l EXC_DREGS(%a6),&0x0303
4273 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4274 fmovm.x &0x03,-(%sp)
4275 fmovm.x (%sp)+,&0x40
4276 fmovm.x (%sp)+,&0x80
4277 unlk %a6
4278 rts
4279
4280
4281
4282
4283
4284 global _frems_
4285_frems_:
4286 link %a6,&-LOCAL_SIZE
4287
4288 movm.l &0x0303,EXC_DREGS(%a6)
4289 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4290 fmovm.x &0xc0,EXC_FP0(%a6)
4291
4292 fmov.l &0x0,%fpcr
4293
4294
4295
4296
4297 fmov.s 0x8(%a6),%fp0
4298 fmov.x %fp0,FP_DST(%a6)
4299 lea FP_DST(%a6),%a0
4300 bsr.l tag
4301 mov.b %d0,DTAG(%a6)
4302
4303 fmov.s 0xc(%a6),%fp0
4304 fmov.x %fp0,FP_SRC(%a6)
4305 lea FP_SRC(%a6),%a0
4306 bsr.l tag
4307 mov.b %d0,STAG(%a6)
4308 mov.l %d0,%d1
4309
4310 andi.l &0x00ff00ff,USER_FPSR(%a6)
4311
4312 clr.l %d0
4313 mov.b FPCR_MODE(%a6),%d0
4314
4315 lea FP_SRC(%a6),%a0
4316 lea FP_DST(%a6),%a1
4317
4318 tst.b %d1
4319 bne.b _L21_2s
4320 bsr.l srem_snorm
4321 bra.b _L21_6s
4322_L21_2s:
4323 cmpi.b %d1,&ZERO
4324 bne.b _L21_3s
4325 bsr.l srem_szero
4326 bra.b _L21_6s
4327_L21_3s:
4328 cmpi.b %d1,&INF
4329 bne.b _L21_4s
4330 bsr.l srem_sinf
4331 bra.b _L21_6s
4332_L21_4s:
4333 cmpi.b %d1,&QNAN
4334 bne.b _L21_5s
4335 bsr.l sop_sqnan
4336 bra.b _L21_6s
4337_L21_5s:
4338 bsr.l srem_sdnrm
4339_L21_6s:
4340
4341
4342
4343
4344 movm.l EXC_DREGS(%a6),&0x0303
4345 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4346 fmovm.x EXC_FP1(%a6),&0x40
4347 unlk %a6
4348 rts
4349
4350 global _fremd_
4351_fremd_:
4352 link %a6,&-LOCAL_SIZE
4353
4354 movm.l &0x0303,EXC_DREGS(%a6)
4355 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4356 fmovm.x &0xc0,EXC_FP0(%a6)
4357
4358 fmov.l &0x0,%fpcr
4359
4360
4361
4362
4363 fmov.d 0x8(%a6),%fp0
4364 fmov.x %fp0,FP_DST(%a6)
4365 lea FP_DST(%a6),%a0
4366 bsr.l tag
4367 mov.b %d0,DTAG(%a6)
4368
4369 fmov.d 0x10(%a6),%fp0
4370 fmov.x %fp0,FP_SRC(%a6)
4371 lea FP_SRC(%a6),%a0
4372 bsr.l tag
4373 mov.b %d0,STAG(%a6)
4374 mov.l %d0,%d1
4375
4376 andi.l &0x00ff00ff,USER_FPSR(%a6)
4377
4378 clr.l %d0
4379 mov.b FPCR_MODE(%a6),%d0
4380
4381 lea FP_SRC(%a6),%a0
4382 lea FP_DST(%a6),%a1
4383
4384 tst.b %d1
4385 bne.b _L21_2d
4386 bsr.l srem_snorm
4387 bra.b _L21_6d
4388_L21_2d:
4389 cmpi.b %d1,&ZERO
4390 bne.b _L21_3d
4391 bsr.l srem_szero
4392 bra.b _L21_6d
4393_L21_3d:
4394 cmpi.b %d1,&INF
4395 bne.b _L21_4d
4396 bsr.l srem_sinf
4397 bra.b _L21_6d
4398_L21_4d:
4399 cmpi.b %d1,&QNAN
4400 bne.b _L21_5d
4401 bsr.l sop_sqnan
4402 bra.b _L21_6d
4403_L21_5d:
4404 bsr.l srem_sdnrm
4405_L21_6d:
4406
4407
4408
4409
4410 movm.l EXC_DREGS(%a6),&0x0303
4411 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4412 fmovm.x EXC_FP1(%a6),&0x40
4413 unlk %a6
4414 rts
4415
4416 global _fremx_
4417_fremx_:
4418 link %a6,&-LOCAL_SIZE
4419
4420 movm.l &0x0303,EXC_DREGS(%a6)
4421 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4422 fmovm.x &0xc0,EXC_FP0(%a6)
4423
4424 fmov.l &0x0,%fpcr
4425
4426
4427
4428
4429 lea FP_DST(%a6),%a0
4430 mov.l 0x8+0x0(%a6),0x0(%a0)
4431 mov.l 0x8+0x4(%a6),0x4(%a0)
4432 mov.l 0x8+0x8(%a6),0x8(%a0)
4433 bsr.l tag
4434 mov.b %d0,DTAG(%a6)
4435
4436 lea FP_SRC(%a6),%a0
4437 mov.l 0x14+0x0(%a6),0x0(%a0)
4438 mov.l 0x14+0x4(%a6),0x4(%a0)
4439 mov.l 0x14+0x8(%a6),0x8(%a0)
4440 bsr.l tag
4441 mov.b %d0,STAG(%a6)
4442 mov.l %d0,%d1
4443
4444 andi.l &0x00ff00ff,USER_FPSR(%a6)
4445
4446 clr.l %d0
4447 mov.b FPCR_MODE(%a6),%d0
4448
4449 lea FP_SRC(%a6),%a0
4450 lea FP_DST(%a6),%a1
4451
4452 tst.b %d1
4453 bne.b _L21_2x
4454 bsr.l srem_snorm
4455 bra.b _L21_6x
4456_L21_2x:
4457 cmpi.b %d1,&ZERO
4458 bne.b _L21_3x
4459 bsr.l srem_szero
4460 bra.b _L21_6x
4461_L21_3x:
4462 cmpi.b %d1,&INF
4463 bne.b _L21_4x
4464 bsr.l srem_sinf
4465 bra.b _L21_6x
4466_L21_4x:
4467 cmpi.b %d1,&QNAN
4468 bne.b _L21_5x
4469 bsr.l sop_sqnan
4470 bra.b _L21_6x
4471_L21_5x:
4472 bsr.l srem_sdnrm
4473_L21_6x:
4474
4475
4476
4477
4478 movm.l EXC_DREGS(%a6),&0x0303
4479 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4480 fmovm.x EXC_FP1(%a6),&0x40
4481 unlk %a6
4482 rts
4483
4484
4485
4486
4487
4488 global _fmods_
4489_fmods_:
4490 link %a6,&-LOCAL_SIZE
4491
4492 movm.l &0x0303,EXC_DREGS(%a6)
4493 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4494 fmovm.x &0xc0,EXC_FP0(%a6)
4495
4496 fmov.l &0x0,%fpcr
4497
4498
4499
4500
4501 fmov.s 0x8(%a6),%fp0
4502 fmov.x %fp0,FP_DST(%a6)
4503 lea FP_DST(%a6),%a0
4504 bsr.l tag
4505 mov.b %d0,DTAG(%a6)
4506
4507 fmov.s 0xc(%a6),%fp0
4508 fmov.x %fp0,FP_SRC(%a6)
4509 lea FP_SRC(%a6),%a0
4510 bsr.l tag
4511 mov.b %d0,STAG(%a6)
4512 mov.l %d0,%d1
4513
4514 andi.l &0x00ff00ff,USER_FPSR(%a6)
4515
4516 clr.l %d0
4517 mov.b FPCR_MODE(%a6),%d0
4518
4519 lea FP_SRC(%a6),%a0
4520 lea FP_DST(%a6),%a1
4521
4522 tst.b %d1
4523 bne.b _L22_2s
4524 bsr.l smod_snorm
4525 bra.b _L22_6s
4526_L22_2s:
4527 cmpi.b %d1,&ZERO
4528 bne.b _L22_3s
4529 bsr.l smod_szero
4530 bra.b _L22_6s
4531_L22_3s:
4532 cmpi.b %d1,&INF
4533 bne.b _L22_4s
4534 bsr.l smod_sinf
4535 bra.b _L22_6s
4536_L22_4s:
4537 cmpi.b %d1,&QNAN
4538 bne.b _L22_5s
4539 bsr.l sop_sqnan
4540 bra.b _L22_6s
4541_L22_5s:
4542 bsr.l smod_sdnrm
4543_L22_6s:
4544
4545
4546
4547
4548 movm.l EXC_DREGS(%a6),&0x0303
4549 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4550 fmovm.x EXC_FP1(%a6),&0x40
4551 unlk %a6
4552 rts
4553
4554 global _fmodd_
4555_fmodd_:
4556 link %a6,&-LOCAL_SIZE
4557
4558 movm.l &0x0303,EXC_DREGS(%a6)
4559 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4560 fmovm.x &0xc0,EXC_FP0(%a6)
4561
4562 fmov.l &0x0,%fpcr
4563
4564
4565
4566
4567 fmov.d 0x8(%a6),%fp0
4568 fmov.x %fp0,FP_DST(%a6)
4569 lea FP_DST(%a6),%a0
4570 bsr.l tag
4571 mov.b %d0,DTAG(%a6)
4572
4573 fmov.d 0x10(%a6),%fp0
4574 fmov.x %fp0,FP_SRC(%a6)
4575 lea FP_SRC(%a6),%a0
4576 bsr.l tag
4577 mov.b %d0,STAG(%a6)
4578 mov.l %d0,%d1
4579
4580 andi.l &0x00ff00ff,USER_FPSR(%a6)
4581
4582 clr.l %d0
4583 mov.b FPCR_MODE(%a6),%d0
4584
4585 lea FP_SRC(%a6),%a0
4586 lea FP_DST(%a6),%a1
4587
4588 tst.b %d1
4589 bne.b _L22_2d
4590 bsr.l smod_snorm
4591 bra.b _L22_6d
4592_L22_2d:
4593 cmpi.b %d1,&ZERO
4594 bne.b _L22_3d
4595 bsr.l smod_szero
4596 bra.b _L22_6d
4597_L22_3d:
4598 cmpi.b %d1,&INF
4599 bne.b _L22_4d
4600 bsr.l smod_sinf
4601 bra.b _L22_6d
4602_L22_4d:
4603 cmpi.b %d1,&QNAN
4604 bne.b _L22_5d
4605 bsr.l sop_sqnan
4606 bra.b _L22_6d
4607_L22_5d:
4608 bsr.l smod_sdnrm
4609_L22_6d:
4610
4611
4612
4613
4614 movm.l EXC_DREGS(%a6),&0x0303
4615 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4616 fmovm.x EXC_FP1(%a6),&0x40
4617 unlk %a6
4618 rts
4619
4620 global _fmodx_
4621_fmodx_:
4622 link %a6,&-LOCAL_SIZE
4623
4624 movm.l &0x0303,EXC_DREGS(%a6)
4625 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4626 fmovm.x &0xc0,EXC_FP0(%a6)
4627
4628 fmov.l &0x0,%fpcr
4629
4630
4631
4632
4633 lea FP_DST(%a6),%a0
4634 mov.l 0x8+0x0(%a6),0x0(%a0)
4635 mov.l 0x8+0x4(%a6),0x4(%a0)
4636 mov.l 0x8+0x8(%a6),0x8(%a0)
4637 bsr.l tag
4638 mov.b %d0,DTAG(%a6)
4639
4640 lea FP_SRC(%a6),%a0
4641 mov.l 0x14+0x0(%a6),0x0(%a0)
4642 mov.l 0x14+0x4(%a6),0x4(%a0)
4643 mov.l 0x14+0x8(%a6),0x8(%a0)
4644 bsr.l tag
4645 mov.b %d0,STAG(%a6)
4646 mov.l %d0,%d1
4647
4648 andi.l &0x00ff00ff,USER_FPSR(%a6)
4649
4650 clr.l %d0
4651 mov.b FPCR_MODE(%a6),%d0
4652
4653 lea FP_SRC(%a6),%a0
4654 lea FP_DST(%a6),%a1
4655
4656 tst.b %d1
4657 bne.b _L22_2x
4658 bsr.l smod_snorm
4659 bra.b _L22_6x
4660_L22_2x:
4661 cmpi.b %d1,&ZERO
4662 bne.b _L22_3x
4663 bsr.l smod_szero
4664 bra.b _L22_6x
4665_L22_3x:
4666 cmpi.b %d1,&INF
4667 bne.b _L22_4x
4668 bsr.l smod_sinf
4669 bra.b _L22_6x
4670_L22_4x:
4671 cmpi.b %d1,&QNAN
4672 bne.b _L22_5x
4673 bsr.l sop_sqnan
4674 bra.b _L22_6x
4675_L22_5x:
4676 bsr.l smod_sdnrm
4677_L22_6x:
4678
4679
4680
4681
4682 movm.l EXC_DREGS(%a6),&0x0303
4683 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4684 fmovm.x EXC_FP1(%a6),&0x40
4685 unlk %a6
4686 rts
4687
4688
4689
4690
4691
4692 global _fscales_
4693_fscales_:
4694 link %a6,&-LOCAL_SIZE
4695
4696 movm.l &0x0303,EXC_DREGS(%a6)
4697 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4698 fmovm.x &0xc0,EXC_FP0(%a6)
4699
4700 fmov.l &0x0,%fpcr
4701
4702
4703
4704
4705 fmov.s 0x8(%a6),%fp0
4706 fmov.x %fp0,FP_DST(%a6)
4707 lea FP_DST(%a6),%a0
4708 bsr.l tag
4709 mov.b %d0,DTAG(%a6)
4710
4711 fmov.s 0xc(%a6),%fp0
4712 fmov.x %fp0,FP_SRC(%a6)
4713 lea FP_SRC(%a6),%a0
4714 bsr.l tag
4715 mov.b %d0,STAG(%a6)
4716 mov.l %d0,%d1
4717
4718 andi.l &0x00ff00ff,USER_FPSR(%a6)
4719
4720 clr.l %d0
4721 mov.b FPCR_MODE(%a6),%d0
4722
4723 lea FP_SRC(%a6),%a0
4724 lea FP_DST(%a6),%a1
4725
4726 tst.b %d1
4727 bne.b _L23_2s
4728 bsr.l sscale_snorm
4729 bra.b _L23_6s
4730_L23_2s:
4731 cmpi.b %d1,&ZERO
4732 bne.b _L23_3s
4733 bsr.l sscale_szero
4734 bra.b _L23_6s
4735_L23_3s:
4736 cmpi.b %d1,&INF
4737 bne.b _L23_4s
4738 bsr.l sscale_sinf
4739 bra.b _L23_6s
4740_L23_4s:
4741 cmpi.b %d1,&QNAN
4742 bne.b _L23_5s
4743 bsr.l sop_sqnan
4744 bra.b _L23_6s
4745_L23_5s:
4746 bsr.l sscale_sdnrm
4747_L23_6s:
4748
4749
4750
4751
4752 movm.l EXC_DREGS(%a6),&0x0303
4753 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4754 fmovm.x EXC_FP1(%a6),&0x40
4755 unlk %a6
4756 rts
4757
4758 global _fscaled_
4759_fscaled_:
4760 link %a6,&-LOCAL_SIZE
4761
4762 movm.l &0x0303,EXC_DREGS(%a6)
4763 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4764 fmovm.x &0xc0,EXC_FP0(%a6)
4765
4766 fmov.l &0x0,%fpcr
4767
4768
4769
4770
4771 fmov.d 0x8(%a6),%fp0
4772 fmov.x %fp0,FP_DST(%a6)
4773 lea FP_DST(%a6),%a0
4774 bsr.l tag
4775 mov.b %d0,DTAG(%a6)
4776
4777 fmov.d 0x10(%a6),%fp0
4778 fmov.x %fp0,FP_SRC(%a6)
4779 lea FP_SRC(%a6),%a0
4780 bsr.l tag
4781 mov.b %d0,STAG(%a6)
4782 mov.l %d0,%d1
4783
4784 andi.l &0x00ff00ff,USER_FPSR(%a6)
4785
4786 clr.l %d0
4787 mov.b FPCR_MODE(%a6),%d0
4788
4789 lea FP_SRC(%a6),%a0
4790 lea FP_DST(%a6),%a1
4791
4792 tst.b %d1
4793 bne.b _L23_2d
4794 bsr.l sscale_snorm
4795 bra.b _L23_6d
4796_L23_2d:
4797 cmpi.b %d1,&ZERO
4798 bne.b _L23_3d
4799 bsr.l sscale_szero
4800 bra.b _L23_6d
4801_L23_3d:
4802 cmpi.b %d1,&INF
4803 bne.b _L23_4d
4804 bsr.l sscale_sinf
4805 bra.b _L23_6d
4806_L23_4d:
4807 cmpi.b %d1,&QNAN
4808 bne.b _L23_5d
4809 bsr.l sop_sqnan
4810 bra.b _L23_6d
4811_L23_5d:
4812 bsr.l sscale_sdnrm
4813_L23_6d:
4814
4815
4816
4817
4818 movm.l EXC_DREGS(%a6),&0x0303
4819 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4820 fmovm.x EXC_FP1(%a6),&0x40
4821 unlk %a6
4822 rts
4823
4824 global _fscalex_
4825_fscalex_:
4826 link %a6,&-LOCAL_SIZE
4827
4828 movm.l &0x0303,EXC_DREGS(%a6)
4829 fmovm.l %fpcr,%fpsr,USER_FPCR(%a6)
4830 fmovm.x &0xc0,EXC_FP0(%a6)
4831
4832 fmov.l &0x0,%fpcr
4833
4834
4835
4836
4837 lea FP_DST(%a6),%a0
4838 mov.l 0x8+0x0(%a6),0x0(%a0)
4839 mov.l 0x8+0x4(%a6),0x4(%a0)
4840 mov.l 0x8+0x8(%a6),0x8(%a0)
4841 bsr.l tag
4842 mov.b %d0,DTAG(%a6)
4843
4844 lea FP_SRC(%a6),%a0
4845 mov.l 0x14+0x0(%a6),0x0(%a0)
4846 mov.l 0x14+0x4(%a6),0x4(%a0)
4847 mov.l 0x14+0x8(%a6),0x8(%a0)
4848 bsr.l tag
4849 mov.b %d0,STAG(%a6)
4850 mov.l %d0,%d1
4851
4852 andi.l &0x00ff00ff,USER_FPSR(%a6)
4853
4854 clr.l %d0
4855 mov.b FPCR_MODE(%a6),%d0
4856
4857 lea FP_SRC(%a6),%a0
4858 lea FP_DST(%a6),%a1
4859
4860 tst.b %d1
4861 bne.b _L23_2x
4862 bsr.l sscale_snorm
4863 bra.b _L23_6x
4864_L23_2x:
4865 cmpi.b %d1,&ZERO
4866 bne.b _L23_3x
4867 bsr.l sscale_szero
4868 bra.b _L23_6x
4869_L23_3x:
4870 cmpi.b %d1,&INF
4871 bne.b _L23_4x
4872 bsr.l sscale_sinf
4873 bra.b _L23_6x
4874_L23_4x:
4875 cmpi.b %d1,&QNAN
4876 bne.b _L23_5x
4877 bsr.l sop_sqnan
4878 bra.b _L23_6x
4879_L23_5x:
4880 bsr.l sscale_sdnrm
4881_L23_6x:
4882
4883
4884
4885
4886 movm.l EXC_DREGS(%a6),&0x0303
4887 fmovm.l USER_FPCR(%a6),%fpcr,%fpsr
4888 fmovm.x EXC_FP1(%a6),&0x40
4889 unlk %a6
4890 rts
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979SINA7: long 0xBD6AAA77,0xCCC994F5
4980SINA6: long 0x3DE61209,0x7AAE8DA1
4981SINA5: long 0xBE5AE645,0x2A118AE4
4982SINA4: long 0x3EC71DE3,0xA5341531
4983SINA3: long 0xBF2A01A0,0x1A018B59,0x00000000,0x00000000
4984SINA2: long 0x3FF80000,0x88888888,0x888859AF,0x00000000
4985SINA1: long 0xBFFC0000,0xAAAAAAAA,0xAAAAAA99,0x00000000
4986
4987COSB8: long 0x3D2AC4D0,0xD6011EE3
4988COSB7: long 0xBDA9396F,0x9F45AC19
4989COSB6: long 0x3E21EED9,0x0612C972
4990COSB5: long 0xBE927E4F,0xB79D9FCF
4991COSB4: long 0x3EFA01A0,0x1A01D423,0x00000000,0x00000000
4992COSB3: long 0xBFF50000,0xB60B60B6,0x0B61D438,0x00000000
4993COSB2: long 0x3FFA0000,0xAAAAAAAA,0xAAAAAB5E
4994COSB1: long 0xBF000000
4995
4996 set INARG,FP_SCR0
4997
4998 set X,FP_SCR0
4999
5000 set XFRAC,X+4
5001
5002 set RPRIME,FP_SCR0
5003 set SPRIME,FP_SCR1
5004
5005 set POSNEG1,L_SCR1
5006 set TWOTO63,L_SCR1
5007
5008 set ENDFLAG,L_SCR2
5009 set INT,L_SCR2
5010
5011 set ADJN,L_SCR3
5012
5013
5014 global ssin
5015ssin:
5016 mov.l &0,ADJN(%a6)
5017 bra.b SINBGN
5018
5019
5020 global scos
5021scos:
5022 mov.l &1,ADJN(%a6)
5023
5024
5025SINBGN:
5026
5027
5028 fmov.x (%a0),%fp0
5029 fmov.x %fp0,X(%a6)
5030
5031
5032 mov.l (%a0),%d1
5033 mov.w 4(%a0),%d1
5034 and.l &0x7FFFFFFF,%d1
5035
5036 cmpi.l %d1,&0x3FD78000
5037 bge.b SOK1
5038 bra.w SINSM
5039
5040SOK1:
5041 cmp.l %d1,&0x4004BC7E
5042 blt.b SINMAIN
5043 bra.w SREDUCEX
5044
5045
5046
5047SINMAIN:
5048 fmov.x %fp0,%fp1
5049 fmul.d TWOBYPI(%pc),%fp1
5050
5051 lea PITBL+0x200(%pc),%a1
5052
5053 fmov.l %fp1,INT(%a6)
5054
5055 mov.l INT(%a6),%d1
5056 asl.l &4,%d1
5057 add.l %d1,%a1
5058
5059
5060
5061 fsub.x (%a1)+,%fp0
5062 fsub.s (%a1),%fp0
5063
5064SINCONT:
5065
5066
5067
5068 mov.l INT(%a6),%d1
5069 add.l ADJN(%a6),%d1
5070 ror.l &1,%d1
5071 cmp.l %d1,&0
5072 blt.w COSPOLY
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082SINPOLY:
5083 fmovm.x &0x0c,-(%sp)
5084
5085 fmov.x %fp0,X(%a6)
5086 fmul.x %fp0,%fp0
5087
5088 fmov.d SINA7(%pc),%fp3
5089 fmov.d SINA6(%pc),%fp2
5090
5091 fmov.x %fp0,%fp1
5092 fmul.x %fp1,%fp1
5093
5094 ror.l &1,%d1
5095 and.l &0x80000000,%d1
5096
5097 eor.l %d1,X(%a6)
5098
5099 fmul.x %fp1,%fp3
5100 fmul.x %fp1,%fp2
5101
5102 fadd.d SINA5(%pc),%fp3
5103 fadd.d SINA4(%pc),%fp2
5104
5105 fmul.x %fp1,%fp3
5106 fmul.x %fp1,%fp2
5107
5108 fadd.d SINA3(%pc),%fp3
5109 fadd.x SINA2(%pc),%fp2
5110
5111 fmul.x %fp3,%fp1
5112
5113 fmul.x %fp0,%fp2
5114 fadd.x SINA1(%pc),%fp1
5115 fmul.x X(%a6),%fp0
5116
5117 fadd.x %fp2,%fp1
5118
5119 fmul.x %fp1,%fp0
5120
5121 fmovm.x (%sp)+,&0x30
5122
5123 fmov.l %d0,%fpcr
5124 fadd.x X(%a6),%fp0
5125 bra t_inx2
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136COSPOLY:
5137 fmovm.x &0x0c,-(%sp)
5138
5139 fmul.x %fp0,%fp0
5140
5141 fmov.d COSB8(%pc),%fp2
5142 fmov.d COSB7(%pc),%fp3
5143
5144 fmov.x %fp0,%fp1
5145 fmul.x %fp1,%fp1
5146
5147 fmov.x %fp0,X(%a6)
5148 ror.l &1,%d1
5149 and.l &0x80000000,%d1
5150
5151
5152 fmul.x %fp1,%fp2
5153
5154 eor.l %d1,X(%a6)
5155 and.l &0x80000000,%d1
5156
5157 fmul.x %fp1,%fp3
5158
5159 or.l &0x3F800000,%d1
5160 mov.l %d1,POSNEG1(%a6)
5161
5162 fadd.d COSB6(%pc),%fp2
5163 fadd.d COSB5(%pc),%fp3
5164
5165 fmul.x %fp1,%fp2
5166 fmul.x %fp1,%fp3
5167
5168 fadd.d COSB4(%pc),%fp2
5169 fadd.x COSB3(%pc),%fp3
5170
5171 fmul.x %fp1,%fp2
5172 fmul.x %fp3,%fp1
5173
5174 fadd.x COSB2(%pc),%fp2
5175 fadd.s COSB1(%pc),%fp1
5176
5177 fmul.x %fp2,%fp0
5178
5179 fadd.x %fp1,%fp0
5180
5181 fmul.x X(%a6),%fp0
5182
5183 fmovm.x (%sp)+,&0x30
5184
5185 fmov.l %d0,%fpcr
5186 fadd.s POSNEG1(%a6),%fp0
5187 bra t_inx2
5188
5189
5190
5191
5192
5193
5194SINBORS:
5195 cmp.l %d1,&0x3FFF8000
5196 bgt.l SREDUCEX
5197
5198SINSM:
5199 mov.l ADJN(%a6),%d1
5200 cmp.l %d1,&0
5201 bgt.b COSTINY
5202
5203
5204
5205SINTINY:
5206
5207
5208 fmov.l %d0,%fpcr
5209 mov.b &FMOV_OP,%d1
5210 fmov.x X(%a6),%fp0
5211 bra t_catch
5212
5213COSTINY:
5214 fmov.s &0x3F800000,%fp0
5215 fmov.l %d0,%fpcr
5216 fadd.s &0x80800000,%fp0
5217 bra t_pinx2
5218
5219
5220 global ssind
5221
5222ssind:
5223 bra t_extdnrm
5224
5225
5226 global scosd
5227
5228scosd:
5229 fmov.s &0x3F800000,%fp0
5230 bra t_pinx2
5231
5232
5233
5234 global ssincos
5235ssincos:
5236
5237 mov.l &4,ADJN(%a6)
5238
5239 fmov.x (%a0),%fp0
5240 fmov.x %fp0,X(%a6)
5241
5242 mov.l (%a0),%d1
5243 mov.w 4(%a0),%d1
5244 and.l &0x7FFFFFFF,%d1
5245
5246 cmp.l %d1,&0x3FD78000
5247 bge.b SCOK1
5248 bra.w SCSM
5249
5250SCOK1:
5251 cmp.l %d1,&0x4004BC7E
5252 blt.b SCMAIN
5253 bra.w SREDUCEX
5254
5255
5256
5257
5258SCMAIN:
5259 fmov.x %fp0,%fp1
5260
5261 fmul.d TWOBYPI(%pc),%fp1
5262
5263 lea PITBL+0x200(%pc),%a1
5264
5265 fmov.l %fp1,INT(%a6)
5266
5267 mov.l INT(%a6),%d1
5268 asl.l &4,%d1
5269 add.l %d1,%a1
5270
5271 fsub.x (%a1)+,%fp0
5272 fsub.s (%a1),%fp0
5273
5274SCCONT:
5275
5276
5277 mov.l INT(%a6),%d1
5278 ror.l &1,%d1
5279 cmp.l %d1,&0
5280 bge.w NEVEN
5281
5282SNODD:
5283
5284 fmovm.x &0x04,-(%sp)
5285
5286 fmov.x %fp0,RPRIME(%a6)
5287 fmul.x %fp0,%fp0
5288 fmov.d SINA7(%pc),%fp1
5289 fmov.d COSB8(%pc),%fp2
5290 fmul.x %fp0,%fp1
5291 fmul.x %fp0,%fp2
5292
5293 mov.l %d2,-(%sp)
5294 mov.l %d1,%d2
5295 ror.l &1,%d2
5296 and.l &0x80000000,%d2
5297 eor.l %d1,%d2
5298 and.l &0x80000000,%d2
5299
5300 fadd.d SINA6(%pc),%fp1
5301 fadd.d COSB7(%pc),%fp2
5302
5303 fmul.x %fp0,%fp1
5304 eor.l %d2,RPRIME(%a6)
5305 mov.l (%sp)+,%d2
5306 fmul.x %fp0,%fp2
5307 ror.l &1,%d1
5308 and.l &0x80000000,%d1
5309 mov.l &0x3F800000,POSNEG1(%a6)
5310 eor.l %d1,POSNEG1(%a6)
5311
5312 fadd.d SINA5(%pc),%fp1
5313 fadd.d COSB6(%pc),%fp2
5314
5315 fmul.x %fp0,%fp1
5316 fmul.x %fp0,%fp2
5317 fmov.x %fp0,SPRIME(%a6)
5318
5319 fadd.d SINA4(%pc),%fp1
5320 eor.l %d1,SPRIME(%a6)
5321 fadd.d COSB5(%pc),%fp2
5322
5323 fmul.x %fp0,%fp1
5324 fmul.x %fp0,%fp2
5325
5326 fadd.d SINA3(%pc),%fp1
5327 fadd.d COSB4(%pc),%fp2
5328
5329 fmul.x %fp0,%fp1
5330 fmul.x %fp0,%fp2
5331
5332 fadd.x SINA2(%pc),%fp1
5333 fadd.x COSB3(%pc),%fp2
5334
5335 fmul.x %fp0,%fp1
5336 fmul.x %fp0,%fp2
5337
5338 fadd.x SINA1(%pc),%fp1
5339 fadd.x COSB2(%pc),%fp2
5340
5341 fmul.x %fp0,%fp1
5342 fmul.x %fp2,%fp0
5343
5344 fmul.x RPRIME(%a6),%fp1
5345 fadd.s COSB1(%pc),%fp0
5346 fmul.x SPRIME(%a6),%fp0
5347
5348 fmovm.x (%sp)+,&0x20
5349
5350 fmov.l %d0,%fpcr
5351 fadd.x RPRIME(%a6),%fp1
5352 bsr sto_cos
5353 fadd.s POSNEG1(%a6),%fp0
5354 bra t_inx2
5355
5356NEVEN:
5357
5358 fmovm.x &0x04,-(%sp)
5359
5360 fmov.x %fp0,RPRIME(%a6)
5361 fmul.x %fp0,%fp0
5362
5363 fmov.d COSB8(%pc),%fp1
5364 fmov.d SINA7(%pc),%fp2
5365
5366 fmul.x %fp0,%fp1
5367 fmov.x %fp0,SPRIME(%a6)
5368 fmul.x %fp0,%fp2
5369
5370 ror.l &1,%d1
5371 and.l &0x80000000,%d1
5372
5373 fadd.d COSB7(%pc),%fp1
5374 fadd.d SINA6(%pc),%fp2
5375
5376 eor.l %d1,RPRIME(%a6)
5377 eor.l %d1,SPRIME(%a6)
5378
5379 fmul.x %fp0,%fp1
5380
5381 or.l &0x3F800000,%d1
5382 mov.l %d1,POSNEG1(%a6)
5383
5384 fmul.x %fp0,%fp2
5385
5386 fadd.d COSB6(%pc),%fp1
5387 fadd.d SINA5(%pc),%fp2
5388
5389 fmul.x %fp0,%fp1
5390 fmul.x %fp0,%fp2
5391
5392 fadd.d COSB5(%pc),%fp1
5393 fadd.d SINA4(%pc),%fp2
5394
5395 fmul.x %fp0,%fp1
5396 fmul.x %fp0,%fp2
5397
5398 fadd.d COSB4(%pc),%fp1
5399 fadd.d SINA3(%pc),%fp2
5400
5401 fmul.x %fp0,%fp1
5402 fmul.x %fp0,%fp2
5403
5404 fadd.x COSB3(%pc),%fp1
5405 fadd.x SINA2(%pc),%fp2
5406
5407 fmul.x %fp0,%fp1
5408 fmul.x %fp0,%fp2
5409
5410 fadd.x COSB2(%pc),%fp1
5411 fadd.x SINA1(%pc),%fp2
5412
5413 fmul.x %fp0,%fp1
5414 fmul.x %fp2,%fp0
5415
5416
5417 fadd.s COSB1(%pc),%fp1
5418 fmul.x RPRIME(%a6),%fp0
5419 fmul.x SPRIME(%a6),%fp1
5420
5421 fmovm.x (%sp)+,&0x20
5422
5423 fmov.l %d0,%fpcr
5424 fadd.s POSNEG1(%a6),%fp1
5425 bsr sto_cos
5426 fadd.x RPRIME(%a6),%fp0
5427 bra t_inx2
5428
5429
5430
5431SCBORS:
5432 cmp.l %d1,&0x3FFF8000
5433 bgt.w SREDUCEX
5434
5435
5436
5437SCSM:
5438
5439 fmov.s &0x3F800000,%fp1
5440
5441 fmov.l %d0,%fpcr
5442 fsub.s &0x00800000,%fp1
5443 bsr sto_cos
5444 fmov.l %fpcr,%d0
5445 mov.b &FMOV_OP,%d1
5446 fmov.x X(%a6),%fp0
5447 bra t_catch
5448
5449
5450
5451 global ssincosd
5452
5453ssincosd:
5454 mov.l %d0,-(%sp)
5455 fmov.s &0x3F800000,%fp1
5456 bsr sto_cos
5457 mov.l (%sp)+,%d0
5458 bra t_extdnrm
5459
5460
5461
5462
5463
5464
5465SREDUCEX:
5466 fmovm.x &0x3c,-(%sp)
5467 mov.l %d2,-(%sp)
5468 fmov.s &0x00000000,%fp1
5469
5470
5471
5472
5473
5474 cmp.l %d1,&0x7ffeffff
5475 bne.b SLOOP
5476
5477
5478 mov.w &0x7ffe,FP_SCR0_EX(%a6)
5479 mov.l &0xc90fdaa2,FP_SCR0_HI(%a6)
5480 clr.l FP_SCR0_LO(%a6)
5481
5482
5483 mov.w &0x7fdc,FP_SCR1_EX(%a6)
5484 mov.l &0x85a308d3,FP_SCR1_HI(%a6)
5485 clr.l FP_SCR1_LO(%a6)
5486
5487 ftest.x %fp0
5488 fblt.w sred_neg
5489
5490 or.b &0x80,FP_SCR0_EX(%a6)
5491 or.b &0x80,FP_SCR1_EX(%a6)
5492sred_neg:
5493 fadd.x FP_SCR0(%a6),%fp0
5494 fmov.x %fp0,%fp1
5495 fadd.x FP_SCR1(%a6),%fp0
5496 fsub.x %fp0,%fp1
5497 fadd.x FP_SCR1(%a6),%fp1
5498
5499
5500
5501
5502SLOOP:
5503 fmov.x %fp0,INARG(%a6)
5504 mov.w INARG(%a6),%d1
5505 mov.l %d1,%a1
5506 and.l &0x00007FFF,%d1
5507 sub.l &0x00003FFF,%d1
5508 cmp.l %d1,&28
5509 ble.b SLASTLOOP
5510SCONTLOOP:
5511 sub.l &27,%d1
5512 mov.b &0,ENDFLAG(%a6)
5513 bra.b SWORK
5514SLASTLOOP:
5515 clr.l %d1
5516 mov.b &1,ENDFLAG(%a6)
5517
5518SWORK:
5519
5520
5521
5522
5523
5524
5525 mov.l &0x00003FFE,%d2
5526 sub.l %d1,%d2
5527
5528 mov.l &0xA2F9836E,FP_SCR0_HI(%a6)
5529 mov.l &0x4E44152A,FP_SCR0_LO(%a6)
5530 mov.w %d2,FP_SCR0_EX(%a6)
5531
5532 fmov.x %fp0,%fp2
5533 fmul.x FP_SCR0(%a6),%fp2
5534
5535
5536
5537
5538
5539
5540 mov.l %a1,%d2
5541 swap %d2
5542 and.l &0x80000000,%d2
5543 or.l &0x5F000000,%d2
5544 mov.l %d2,TWOTO63(%a6)
5545 fadd.s TWOTO63(%a6),%fp2
5546 fsub.s TWOTO63(%a6),%fp2
5547
5548
5549
5550 mov.l %d1,%d2
5551
5552 add.l &0x00003FFF,%d2
5553 mov.w %d2,FP_SCR0_EX(%a6)
5554 mov.l &0xC90FDAA2,FP_SCR0_HI(%a6)
5555 clr.l FP_SCR0_LO(%a6)
5556
5557 add.l &0x00003FDD,%d1
5558 mov.w %d1,FP_SCR1_EX(%a6)
5559 mov.l &0x85A308D3,FP_SCR1_HI(%a6)
5560 clr.l FP_SCR1_LO(%a6)
5561
5562 mov.b ENDFLAG(%a6),%d1
5563
5564
5565
5566 fmov.x %fp2,%fp4
5567 fmul.x FP_SCR0(%a6),%fp4
5568 fmov.x %fp2,%fp5
5569 fmul.x FP_SCR1(%a6),%fp5
5570 fmov.x %fp4,%fp3
5571
5572
5573
5574 fadd.x %fp5,%fp3
5575 fsub.x %fp3,%fp4
5576
5577 fsub.x %fp3,%fp0
5578 fadd.x %fp5,%fp4
5579
5580 fmov.x %fp0,%fp3
5581 fsub.x %fp4,%fp1
5582
5583
5584
5585 fadd.x %fp1,%fp0
5586
5587 cmp.b %d1,&0
5588 bgt.w SRESTORE
5589
5590
5591 fsub.x %fp0,%fp3
5592 fadd.x %fp3,%fp1
5593 bra.w SLOOP
5594
5595SRESTORE:
5596 fmov.l %fp2,INT(%a6)
5597 mov.l (%sp)+,%d2
5598 fmovm.x (%sp)+,&0x3c
5599
5600 mov.l ADJN(%a6),%d1
5601 cmp.l %d1,&4
5602
5603 blt.w SINCONT
5604 bra.w SCCONT
5605
5606
5607
5608
5609
5610
5611
5612
5613
5614
5615
5616
5617
5618
5619
5620
5621
5622
5623
5624
5625
5626
5627
5628
5629
5630
5631
5632
5633
5634
5635
5636
5637
5638
5639
5640
5641
5642
5643
5644
5645
5646
5647
5648
5649
5650
5651
5652
5653TANQ4:
5654 long 0x3EA0B759,0xF50F8688
5655TANP3:
5656 long 0xBEF2BAA5,0xA8924F04
5657
5658TANQ3:
5659 long 0xBF346F59,0xB39BA65F,0x00000000,0x00000000
5660
5661TANP2:
5662 long 0x3FF60000,0xE073D3FC,0x199C4A00,0x00000000
5663
5664TANQ2:
5665 long 0x3FF90000,0xD23CD684,0x15D95FA1,0x00000000
5666
5667TANP1:
5668 long 0xBFFC0000,0x8895A6C5,0xFB423BCA,0x00000000
5669
5670TANQ1:
5671 long 0xBFFD0000,0xEEF57E0D,0xA84BC8CE,0x00000000
5672
5673INVTWOPI:
5674 long 0x3FFC0000,0xA2F9836E,0x4E44152A,0x00000000
5675
5676TWOPI1:
5677 long 0x40010000,0xC90FDAA2,0x00000000,0x00000000
5678TWOPI2:
5679 long 0x3FDF0000,0x85A308D4,0x00000000,0x00000000
5680
5681
5682
5683
5684
5685PITBL:
5686 long 0xC0040000,0xC90FDAA2,0x2168C235,0x21800000
5687 long 0xC0040000,0xC2C75BCD,0x105D7C23,0xA0D00000
5688 long 0xC0040000,0xBC7EDCF7,0xFF523611,0xA1E80000
5689 long 0xC0040000,0xB6365E22,0xEE46F000,0x21480000
5690 long 0xC0040000,0xAFEDDF4D,0xDD3BA9EE,0xA1200000
5691 long 0xC0040000,0xA9A56078,0xCC3063DD,0x21FC0000
5692 long 0xC0040000,0xA35CE1A3,0xBB251DCB,0x21100000
5693 long 0xC0040000,0x9D1462CE,0xAA19D7B9,0xA1580000
5694 long 0xC0040000,0x96CBE3F9,0x990E91A8,0x21E00000
5695 long 0xC0040000,0x90836524,0x88034B96,0x20B00000
5696 long 0xC0040000,0x8A3AE64F,0x76F80584,0xA1880000
5697 long 0xC0040000,0x83F2677A,0x65ECBF73,0x21C40000
5698 long 0xC0030000,0xFB53D14A,0xA9C2F2C2,0x20000000
5699 long 0xC0030000,0xEEC2D3A0,0x87AC669F,0x21380000
5700 long 0xC0030000,0xE231D5F6,0x6595DA7B,0xA1300000
5701 long 0xC0030000,0xD5A0D84C,0x437F4E58,0x9FC00000
5702 long 0xC0030000,0xC90FDAA2,0x2168C235,0x21000000
5703 long 0xC0030000,0xBC7EDCF7,0xFF523611,0xA1680000
5704 long 0xC0030000,0xAFEDDF4D,0xDD3BA9EE,0xA0A00000
5705 long 0xC0030000,0xA35CE1A3,0xBB251DCB,0x20900000
5706 long 0xC0030000,0x96CBE3F9,0x990E91A8,0x21600000
5707 long 0xC0030000,0x8A3AE64F,0x76F80584,0xA1080000
5708 long 0xC0020000,0xFB53D14A,0xA9C2F2C2,0x1F800000
5709 long 0xC0020000,0xE231D5F6,0x6595DA7B,0xA0B00000
5710 long 0xC0020000,0xC90FDAA2,0x2168C235,0x20800000
5711 long 0xC0020000,0xAFEDDF4D,0xDD3BA9EE,0xA0200000
5712 long 0xC0020000,0x96CBE3F9,0x990E91A8,0x20E00000
5713 long 0xC0010000,0xFB53D14A,0xA9C2F2C2,0x1F000000
5714 long 0xC0010000,0xC90FDAA2,0x2168C235,0x20000000
5715 long 0xC0010000,0x96CBE3F9,0x990E91A8,0x20600000
5716 long 0xC0000000,0xC90FDAA2,0x2168C235,0x1F800000
5717 long 0xBFFF0000,0xC90FDAA2,0x2168C235,0x1F000000
5718 long 0x00000000,0x00000000,0x00000000,0x00000000
5719 long 0x3FFF0000,0xC90FDAA2,0x2168C235,0x9F000000
5720 long 0x40000000,0xC90FDAA2,0x2168C235,0x9F800000
5721 long 0x40010000,0x96CBE3F9,0x990E91A8,0xA0600000
5722 long 0x40010000,0xC90FDAA2,0x2168C235,0xA0000000
5723 long 0x40010000,0xFB53D14A,0xA9C2F2C2,0x9F000000
5724 long 0x40020000,0x96CBE3F9,0x990E91A8,0xA0E00000
5725 long 0x40020000,0xAFEDDF4D,0xDD3BA9EE,0x20200000
5726 long 0x40020000,0xC90FDAA2,0x2168C235,0xA0800000
5727 long 0x40020000,0xE231D5F6,0x6595DA7B,0x20B00000
5728 long 0x40020000,0xFB53D14A,0xA9C2F2C2,0x9F800000
5729 long 0x40030000,0x8A3AE64F,0x76F80584,0x21080000
5730 long 0x40030000,0x96CBE3F9,0x990E91A8,0xA1600000
5731 long 0x40030000,0xA35CE1A3,0xBB251DCB,0xA0900000
5732 long 0x40030000,0xAFEDDF4D,0xDD3BA9EE,0x20A00000
5733 long 0x40030000,0xBC7EDCF7,0xFF523611,0x21680000
5734 long 0x40030000,0xC90FDAA2,0x2168C235,0xA1000000
5735 long 0x40030000,0xD5A0D84C,0x437F4E58,0x1FC00000
5736 long 0x40030000,0xE231D5F6,0x6595DA7B,0x21300000
5737 long 0x40030000,0xEEC2D3A0,0x87AC669F,0xA1380000
5738 long 0x40030000,0xFB53D14A,0xA9C2F2C2,0xA0000000
5739 long 0x40040000,0x83F2677A,0x65ECBF73,0xA1C40000
5740 long 0x40040000,0x8A3AE64F,0x76F80584,0x21880000
5741 long 0x40040000,0x90836524,0x88034B96,0xA0B00000
5742 long 0x40040000,0x96CBE3F9,0x990E91A8,0xA1E00000
5743 long 0x40040000,0x9D1462CE,0xAA19D7B9,0x21580000
5744 long 0x40040000,0xA35CE1A3,0xBB251DCB,0xA1100000
5745 long 0x40040000,0xA9A56078,0xCC3063DD,0xA1FC0000
5746 long 0x40040000,0xAFEDDF4D,0xDD3BA9EE,0x21200000
5747 long 0x40040000,0xB6365E22,0xEE46F000,0xA1480000
5748 long 0x40040000,0xBC7EDCF7,0xFF523611,0x21E80000
5749 long 0x40040000,0xC2C75BCD,0x105D7C23,0x20D00000
5750 long 0x40040000,0xC90FDAA2,0x2168C235,0xA1800000
5751
5752 set INARG,FP_SCR0
5753
5754 set TWOTO63,L_SCR1
5755 set INT,L_SCR1
5756 set ENDFLAG,L_SCR2
5757
5758 global stan
5759stan:
5760 fmov.x (%a0),%fp0
5761
5762 mov.l (%a0),%d1
5763 mov.w 4(%a0),%d1
5764 and.l &0x7FFFFFFF,%d1
5765
5766 cmp.l %d1,&0x3FD78000
5767 bge.b TANOK1
5768 bra.w TANSM
5769TANOK1:
5770 cmp.l %d1,&0x4004BC7E
5771 blt.b TANMAIN
5772 bra.w REDUCEX
5773
5774TANMAIN:
5775
5776
5777 fmov.x %fp0,%fp1
5778 fmul.d TWOBYPI(%pc),%fp1
5779
5780 lea.l PITBL+0x200(%pc),%a1
5781
5782 fmov.l %fp1,%d1
5783
5784 asl.l &4,%d1
5785 add.l %d1,%a1
5786
5787 fsub.x (%a1)+,%fp0
5788
5789 fsub.s (%a1),%fp0
5790
5791 ror.l &5,%d1
5792 and.l &0x80000000,%d1
5793
5794TANCONT:
5795 fmovm.x &0x0c,-(%sp)
5796
5797 cmp.l %d1,&0
5798 blt.w NODD
5799
5800 fmov.x %fp0,%fp1
5801 fmul.x %fp1,%fp1
5802
5803 fmov.d TANQ4(%pc),%fp3
5804 fmov.d TANP3(%pc),%fp2
5805
5806 fmul.x %fp1,%fp3
5807 fmul.x %fp1,%fp2
5808
5809 fadd.d TANQ3(%pc),%fp3
5810 fadd.x TANP2(%pc),%fp2
5811
5812 fmul.x %fp1,%fp3
5813 fmul.x %fp1,%fp2
5814
5815 fadd.x TANQ2(%pc),%fp3
5816 fadd.x TANP1(%pc),%fp2
5817
5818 fmul.x %fp1,%fp3
5819 fmul.x %fp1,%fp2
5820
5821 fadd.x TANQ1(%pc),%fp3
5822 fmul.x %fp0,%fp2
5823
5824 fmul.x %fp3,%fp1
5825
5826 fadd.x %fp2,%fp0
5827
5828 fadd.s &0x3F800000,%fp1
5829
5830 fmovm.x (%sp)+,&0x30
5831
5832 fmov.l %d0,%fpcr
5833 fdiv.x %fp1,%fp0
5834 bra t_inx2
5835
5836NODD:
5837 fmov.x %fp0,%fp1
5838 fmul.x %fp0,%fp0
5839
5840 fmov.d TANQ4(%pc),%fp3
5841 fmov.d TANP3(%pc),%fp2
5842
5843 fmul.x %fp0,%fp3
5844 fmul.x %fp0,%fp2
5845
5846 fadd.d TANQ3(%pc),%fp3
5847 fadd.x TANP2(%pc),%fp2
5848
5849 fmul.x %fp0,%fp3
5850 fmul.x %fp0,%fp2
5851
5852 fadd.x TANQ2(%pc),%fp3
5853 fadd.x TANP1(%pc),%fp2
5854
5855 fmul.x %fp0,%fp3
5856 fmul.x %fp0,%fp2
5857
5858 fadd.x TANQ1(%pc),%fp3
5859 fmul.x %fp1,%fp2
5860
5861 fmul.x %fp3,%fp0
5862
5863 fadd.x %fp2,%fp1
5864 fadd.s &0x3F800000,%fp0
5865
5866 fmovm.x (%sp)+,&0x30
5867
5868 fmov.x %fp1,-(%sp)
5869 eor.l &0x80000000,(%sp)
5870
5871 fmov.l %d0,%fpcr
5872 fdiv.x (%sp)+,%fp0
5873 bra t_inx2
5874
5875TANBORS:
5876
5877
5878 cmp.l %d1,&0x3FFF8000
5879 bgt.b REDUCEX
5880
5881TANSM:
5882 fmov.x %fp0,-(%sp)
5883 fmov.l %d0,%fpcr
5884 mov.b &FMOV_OP,%d1
5885 fmov.x (%sp)+,%fp0
5886 bra t_catch
5887
5888 global stand
5889
5890stand:
5891 bra t_extdnrm
5892
5893
5894
5895
5896REDUCEX:
5897 fmovm.x &0x3c,-(%sp)
5898 mov.l %d2,-(%sp)
5899 fmov.s &0x00000000,%fp1
5900
5901
5902
5903
5904
5905 cmp.l %d1,&0x7ffeffff
5906 bne.b LOOP
5907
5908
5909 mov.w &0x7ffe,FP_SCR0_EX(%a6)
5910 mov.l &0xc90fdaa2,FP_SCR0_HI(%a6)
5911 clr.l FP_SCR0_LO(%a6)
5912
5913
5914 mov.w &0x7fdc,FP_SCR1_EX(%a6)
5915 mov.l &0x85a308d3,FP_SCR1_HI(%a6)
5916 clr.l FP_SCR1_LO(%a6)
5917
5918 ftest.x %fp0
5919 fblt.w red_neg
5920
5921 or.b &0x80,FP_SCR0_EX(%a6)
5922 or.b &0x80,FP_SCR1_EX(%a6)
5923red_neg:
5924 fadd.x FP_SCR0(%a6),%fp0
5925 fmov.x %fp0,%fp1
5926 fadd.x FP_SCR1(%a6),%fp0
5927 fsub.x %fp0,%fp1
5928 fadd.x FP_SCR1(%a6),%fp1
5929
5930
5931
5932
5933LOOP:
5934 fmov.x %fp0,INARG(%a6)
5935 mov.w INARG(%a6),%d1
5936 mov.l %d1,%a1
5937 and.l &0x00007FFF,%d1
5938 sub.l &0x00003FFF,%d1
5939 cmp.l %d1,&28
5940 ble.b LASTLOOP
5941CONTLOOP:
5942 sub.l &27,%d1
5943 mov.b &0,ENDFLAG(%a6)
5944 bra.b WORK
5945LASTLOOP:
5946 clr.l %d1
5947 mov.b &1,ENDFLAG(%a6)
5948
5949WORK:
5950
5951
5952
5953
5954
5955
5956 mov.l &0x00003FFE,%d2
5957 sub.l %d1,%d2
5958
5959 mov.l &0xA2F9836E,FP_SCR0_HI(%a6)
5960 mov.l &0x4E44152A,FP_SCR0_LO(%a6)
5961 mov.w %d2,FP_SCR0_EX(%a6)
5962
5963 fmov.x %fp0,%fp2
5964 fmul.x FP_SCR0(%a6),%fp2
5965
5966
5967
5968
5969
5970
5971 mov.l %a1,%d2
5972 swap %d2
5973 and.l &0x80000000,%d2
5974 or.l &0x5F000000,%d2
5975 mov.l %d2,TWOTO63(%a6)
5976 fadd.s TWOTO63(%a6),%fp2
5977 fsub.s TWOTO63(%a6),%fp2
5978
5979
5980
5981 mov.l %d1,%d2
5982
5983 add.l &0x00003FFF,%d2
5984 mov.w %d2,FP_SCR0_EX(%a6)
5985 mov.l &0xC90FDAA2,FP_SCR0_HI(%a6)
5986 clr.l FP_SCR0_LO(%a6)
5987
5988 add.l &0x00003FDD,%d1
5989 mov.w %d1,FP_SCR1_EX(%a6)
5990 mov.l &0x85A308D3,FP_SCR1_HI(%a6)
5991 clr.l FP_SCR1_LO(%a6)
5992
5993 mov.b ENDFLAG(%a6),%d1
5994
5995
5996
5997 fmov.x %fp2,%fp4
5998 fmul.x FP_SCR0(%a6),%fp4
5999 fmov.x %fp2,%fp5
6000 fmul.x FP_SCR1(%a6),%fp5
6001 fmov.x %fp4,%fp3
6002
6003
6004
6005 fadd.x %fp5,%fp3
6006 fsub.x %fp3,%fp4
6007
6008 fsub.x %fp3,%fp0
6009 fadd.x %fp5,%fp4
6010
6011 fmov.x %fp0,%fp3
6012 fsub.x %fp4,%fp1
6013
6014
6015
6016 fadd.x %fp1,%fp0
6017
6018 cmp.b %d1,&0
6019 bgt.w RESTORE
6020
6021
6022 fsub.x %fp0,%fp3
6023 fadd.x %fp3,%fp1
6024 bra.w LOOP
6025
6026RESTORE:
6027 fmov.l %fp2,INT(%a6)
6028 mov.l (%sp)+,%d2
6029 fmovm.x (%sp)+,&0x3c
6030
6031 mov.l INT(%a6),%d1
6032 ror.l &1,%d1
6033
6034 bra.w TANCONT
6035
6036
6037
6038
6039
6040
6041
6042
6043
6044
6045
6046
6047
6048
6049
6050
6051
6052
6053
6054
6055
6056
6057
6058
6059
6060
6061
6062
6063
6064
6065
6066
6067
6068
6069
6070
6071
6072
6073
6074
6075
6076
6077ATANA3: long 0xBFF6687E,0x314987D8
6078ATANA2: long 0x4002AC69,0x34A26DB3
6079ATANA1: long 0xBFC2476F,0x4E1DA28E
6080
6081ATANB6: long 0x3FB34444,0x7F876989
6082ATANB5: long 0xBFB744EE,0x7FAF45DB
6083ATANB4: long 0x3FBC71C6,0x46940220
6084ATANB3: long 0xBFC24924,0x921872F9
6085ATANB2: long 0x3FC99999,0x99998FA9
6086ATANB1: long 0xBFD55555,0x55555555
6087
6088ATANC5: long 0xBFB70BF3,0x98539E6A
6089ATANC4: long 0x3FBC7187,0x962D1D7D
6090ATANC3: long 0xBFC24924,0x827107B8
6091ATANC2: long 0x3FC99999,0x9996263E
6092ATANC1: long 0xBFD55555,0x55555536
6093
6094PPIBY2: long 0x3FFF0000,0xC90FDAA2,0x2168C235,0x00000000
6095NPIBY2: long 0xBFFF0000,0xC90FDAA2,0x2168C235,0x00000000
6096
6097PTINY: long 0x00010000,0x80000000,0x00000000,0x00000000
6098NTINY: long 0x80010000,0x80000000,0x00000000,0x00000000
6099
6100ATANTBL:
6101 long 0x3FFB0000,0x83D152C5,0x060B7A51,0x00000000
6102 long 0x3FFB0000,0x8BC85445,0x65498B8B,0x00000000
6103 long 0x3FFB0000,0x93BE4060,0x17626B0D,0x00000000
6104 long 0x3FFB0000,0x9BB3078D,0x35AEC202,0x00000000
6105 long 0x3FFB0000,0xA3A69A52,0x5DDCE7DE,0x00000000
6106 long 0x3FFB0000,0xAB98E943,0x62765619,0x00000000
6107 long 0x3FFB0000,0xB389E502,0xF9C59862,0x00000000
6108 long 0x3FFB0000,0xBB797E43,0x6B09E6FB,0x00000000
6109 long 0x3FFB0000,0xC367A5C7,0x39E5F446,0x00000000
6110 long 0x3FFB0000,0xCB544C61,0xCFF7D5C6,0x00000000
6111 long 0x3FFB0000,0xD33F62F8,0x2488533E,0x00000000
6112 long 0x3FFB0000,0xDB28DA81,0x62404C77,0x00000000
6113 long 0x3FFB0000,0xE310A407,0x8AD34F18,0x00000000
6114 long 0x3FFB0000,0xEAF6B0A8,0x188EE1EB,0x00000000
6115 long 0x3FFB0000,0xF2DAF194,0x9DBE79D5,0x00000000
6116 long 0x3FFB0000,0xFABD5813,0x61D47E3E,0x00000000
6117 long 0x3FFC0000,0x8346AC21,0x0959ECC4,0x00000000
6118 long 0x3FFC0000,0x8B232A08,0x304282D8,0x00000000
6119 long 0x3FFC0000,0x92FB70B8,0xD29AE2F9,0x00000000
6120 long 0x3FFC0000,0x9ACF476F,0x5CCD1CB4,0x00000000
6121 long 0x3FFC0000,0xA29E7630,0x4954F23F,0x00000000
6122 long 0x3FFC0000,0xAA68C5D0,0x8AB85230,0x00000000
6123 long 0x3FFC0000,0xB22DFFFD,0x9D539F83,0x00000000
6124 long 0x3FFC0000,0xB9EDEF45,0x3E900EA5,0x00000000
6125 long 0x3FFC0000,0xC1A85F1C,0xC75E3EA5,0x00000000
6126 long 0x3FFC0000,0xC95D1BE8,0x28138DE6,0x00000000
6127 long 0x3FFC0000,0xD10BF300,0x840D2DE4,0x00000000
6128 long 0x3FFC0000,0xD8B4B2BA,0x6BC05E7A,0x00000000
6129 long 0x3FFC0000,0xE0572A6B,0xB42335F6,0x00000000
6130 long 0x3FFC0000,0xE7F32A70,0xEA9CAA8F,0x00000000
6131 long 0x3FFC0000,0xEF888432,0x64ECEFAA,0x00000000
6132 long 0x3FFC0000,0xF7170A28,0xECC06666,0x00000000
6133 long 0x3FFD0000,0x812FD288,0x332DAD32,0x00000000
6134 long 0x3FFD0000,0x88A8D1B1,0x218E4D64,0x00000000
6135 long 0x3FFD0000,0x9012AB3F,0x23E4AEE8,0x00000000
6136 long 0x3FFD0000,0x976CC3D4,0x11E7F1B9,0x00000000
6137 long 0x3FFD0000,0x9EB68949,0x3889A227,0x00000000
6138 long 0x3FFD0000,0xA5EF72C3,0x4487361B,0x00000000
6139 long 0x3FFD0000,0xAD1700BA,0xF07A7227,0x00000000
6140 long 0x3FFD0000,0xB42CBCFA,0xFD37EFB7,0x00000000
6141 long 0x3FFD0000,0xBB303A94,0x0BA80F89,0x00000000
6142 long 0x3FFD0000,0xC22115C6,0xFCAEBBAF,0x00000000
6143 long 0x3FFD0000,0xC8FEF3E6,0x86331221,0x00000000
6144 long 0x3FFD0000,0xCFC98330,0xB4000C70,0x00000000
6145 long 0x3FFD0000,0xD6807AA1,0x102C5BF9,0x00000000
6146 long 0x3FFD0000,0xDD2399BC,0x31252AA3,0x00000000
6147 long 0x3FFD0000,0xE3B2A855,0x6B8FC517,0x00000000
6148 long 0x3FFD0000,0xEA2D764F,0x64315989,0x00000000
6149 long 0x3FFD0000,0xF3BF5BF8,0xBAD1A21D,0x00000000
6150 long 0x3FFE0000,0x801CE39E,0x0D205C9A,0x00000000
6151 long 0x3FFE0000,0x8630A2DA,0xDA1ED066,0x00000000
6152 long 0x3FFE0000,0x8C1AD445,0xF3E09B8C,0x00000000
6153 long 0x3FFE0000,0x91DB8F16,0x64F350E2,0x00000000
6154 long 0x3FFE0000,0x97731420,0x365E538C,0x00000000
6155 long 0x3FFE0000,0x9CE1C8E6,0xA0B8CDBA,0x00000000
6156 long 0x3FFE0000,0xA22832DB,0xCADAAE09,0x00000000
6157 long 0x3FFE0000,0xA746F2DD,0xB7602294,0x00000000
6158 long 0x3FFE0000,0xAC3EC0FB,0x997DD6A2,0x00000000
6159 long 0x3FFE0000,0xB110688A,0xEBDC6F6A,0x00000000
6160 long 0x3FFE0000,0xB5BCC490,0x59ECC4B0,0x00000000
6161 long 0x3FFE0000,0xBA44BC7D,0xD470782F,0x00000000
6162 long 0x3FFE0000,0xBEA94144,0xFD049AAC,0x00000000
6163 long 0x3FFE0000,0xC2EB4ABB,0x661628B6,0x00000000
6164 long 0x3FFE0000,0xC70BD54C,0xE602EE14,0x00000000
6165 long 0x3FFE0000,0xCD000549,0xADEC7159,0x00000000
6166 long 0x3FFE0000,0xD48457D2,0xD8EA4EA3,0x00000000
6167 long 0x3FFE0000,0xDB948DA7,0x12DECE3B,0x00000000
6168 long 0x3FFE0000,0xE23855F9,0x69E8096A,0x00000000
6169 long 0x3FFE0000,0xE8771129,0xC4353259,0x00000000
6170 long 0x3FFE0000,0xEE57C16E,0x0D379C0D,0x00000000
6171 long 0x3FFE0000,0xF3E10211,0xA87C3779,0x00000000
6172 long 0x3FFE0000,0xF919039D,0x758B8D41,0x00000000
6173 long 0x3FFE0000,0xFE058B8F,0x64935FB3,0x00000000
6174 long 0x3FFF0000,0x8155FB49,0x7B685D04,0x00000000
6175 long 0x3FFF0000,0x83889E35,0x49D108E1,0x00000000
6176 long 0x3FFF0000,0x859CFA76,0x511D724B,0x00000000
6177 long 0x3FFF0000,0x87952ECF,0xFF8131E7,0x00000000
6178 long 0x3FFF0000,0x89732FD1,0x9557641B,0x00000000
6179 long 0x3FFF0000,0x8B38CAD1,0x01932A35,0x00000000
6180 long 0x3FFF0000,0x8CE7A8D8,0x301EE6B5,0x00000000
6181 long 0x3FFF0000,0x8F46A39E,0x2EAE5281,0x00000000
6182 long 0x3FFF0000,0x922DA7D7,0x91888487,0x00000000
6183 long 0x3FFF0000,0x94D19FCB,0xDEDF5241,0x00000000
6184 long 0x3FFF0000,0x973AB944,0x19D2A08B,0x00000000
6185 long 0x3FFF0000,0x996FF00E,0x08E10B96,0x00000000
6186 long 0x3FFF0000,0x9B773F95,0x12321DA7,0x00000000
6187 long 0x3FFF0000,0x9D55CC32,0x0F935624,0x00000000
6188 long 0x3FFF0000,0x9F100575,0x006CC571,0x00000000
6189 long 0x3FFF0000,0xA0A9C290,0xD97CC06C,0x00000000
6190 long 0x3FFF0000,0xA22659EB,0xEBC0630A,0x00000000
6191 long 0x3FFF0000,0xA388B4AF,0xF6EF0EC9,0x00000000
6192 long 0x3FFF0000,0xA4D35F10,0x61D292C4,0x00000000
6193 long 0x3FFF0000,0xA60895DC,0xFBE3187E,0x00000000
6194 long 0x3FFF0000,0xA72A51DC,0x7367BEAC,0x00000000
6195 long 0x3FFF0000,0xA83A5153,0x0956168F,0x00000000
6196 long 0x3FFF0000,0xA93A2007,0x7539546E,0x00000000
6197 long 0x3FFF0000,0xAA9E7245,0x023B2605,0x00000000
6198 long 0x3FFF0000,0xAC4C84BA,0x6FE4D58F,0x00000000
6199 long 0x3FFF0000,0xADCE4A4A,0x606B9712,0x00000000
6200 long 0x3FFF0000,0xAF2A2DCD,0x8D263C9C,0x00000000
6201 long 0x3FFF0000,0xB0656F81,0xF22265C7,0x00000000
6202 long 0x3FFF0000,0xB1846515,0x0F71496A,0x00000000
6203 long 0x3FFF0000,0xB28AAA15,0x6F9ADA35,0x00000000
6204 long 0x3FFF0000,0xB37B44FF,0x3766B895,0x00000000
6205 long 0x3FFF0000,0xB458C3DC,0xE9630433,0x00000000
6206 long 0x3FFF0000,0xB525529D,0x562246BD,0x00000000
6207 long 0x3FFF0000,0xB5E2CCA9,0x5F9D88CC,0x00000000
6208 long 0x3FFF0000,0xB692CADA,0x7ACA1ADA,0x00000000
6209 long 0x3FFF0000,0xB736AEA7,0xA6925838,0x00000000
6210 long 0x3FFF0000,0xB7CFAB28,0x7E9F7B36,0x00000000
6211 long 0x3FFF0000,0xB85ECC66,0xCB219835,0x00000000
6212 long 0x3FFF0000,0xB8E4FD5A,0x20A593DA,0x00000000
6213 long 0x3FFF0000,0xB99F41F6,0x4AFF9BB5,0x00000000
6214 long 0x3FFF0000,0xBA7F1E17,0x842BBE7B,0x00000000
6215 long 0x3FFF0000,0xBB471285,0x7637E17D,0x00000000
6216 long 0x3FFF0000,0xBBFABE8A,0x4788DF6F,0x00000000
6217 long 0x3FFF0000,0xBC9D0FAD,0x2B689D79,0x00000000
6218 long 0x3FFF0000,0xBD306A39,0x471ECD86,0x00000000
6219 long 0x3FFF0000,0xBDB6C731,0x856AF18A,0x00000000
6220 long 0x3FFF0000,0xBE31CAC5,0x02E80D70,0x00000000
6221 long 0x3FFF0000,0xBEA2D55C,0xE33194E2,0x00000000
6222 long 0x3FFF0000,0xBF0B10B7,0xC03128F0,0x00000000
6223 long 0x3FFF0000,0xBF6B7A18,0xDACB778D,0x00000000
6224 long 0x3FFF0000,0xBFC4EA46,0x63FA18F6,0x00000000
6225 long 0x3FFF0000,0xC0181BDE,0x8B89A454,0x00000000
6226 long 0x3FFF0000,0xC065B066,0xCFBF6439,0x00000000
6227 long 0x3FFF0000,0xC0AE345F,0x56340AE6,0x00000000
6228 long 0x3FFF0000,0xC0F22291,0x9CB9E6A7,0x00000000
6229
6230 set X,FP_SCR0
6231 set XDCARE,X+2
6232 set XFRAC,X+4
6233 set XFRACLO,X+8
6234
6235 set ATANF,FP_SCR1
6236 set ATANFHI,ATANF+4
6237 set ATANFLO,ATANF+8
6238
6239 global satan
6240
6241satan:
6242 fmov.x (%a0),%fp0
6243
6244 mov.l (%a0),%d1
6245 mov.w 4(%a0),%d1
6246 fmov.x %fp0,X(%a6)
6247 and.l &0x7FFFFFFF,%d1
6248
6249 cmp.l %d1,&0x3FFB8000
6250 bge.b ATANOK1
6251 bra.w ATANSM
6252
6253ATANOK1:
6254 cmp.l %d1,&0x4002FFFF
6255 ble.b ATANMAIN
6256 bra.w ATANBIG
6257
6258
6259
6260
6261
6262
6263
6264
6265
6266
6267
6268
6269
6270
6271
6272
6273
6274
6275
6276
6277
6278
6279ATANMAIN:
6280
6281 and.l &0xF8000000,XFRAC(%a6)
6282 or.l &0x04000000,XFRAC(%a6)
6283 mov.l &0x00000000,XFRACLO(%a6)
6284
6285 fmov.x %fp0,%fp1
6286 fmul.x X(%a6),%fp1
6287 fsub.x X(%a6),%fp0
6288 fadd.s &0x3F800000,%fp1
6289 fdiv.x %fp1,%fp0
6290
6291
6292
6293
6294
6295 mov.l %d2,-(%sp)
6296 mov.l %d1,%d2
6297 and.l &0x00007800,%d1
6298 and.l &0x7FFF0000,%d2
6299 sub.l &0x3FFB0000,%d2
6300 asr.l &1,%d2
6301 add.l %d2,%d1
6302 asr.l &7,%d1
6303 lea ATANTBL(%pc),%a1
6304 add.l %d1,%a1
6305 mov.l (%a1)+,ATANF(%a6)
6306 mov.l (%a1)+,ATANFHI(%a6)
6307 mov.l (%a1)+,ATANFLO(%a6)
6308 mov.l X(%a6),%d1
6309 and.l &0x80000000,%d1
6310 or.l %d1,ATANF(%a6)
6311 mov.l (%sp)+,%d2
6312
6313
6314
6315
6316
6317
6318
6319
6320
6321
6322
6323
6324 fmovm.x &0x04,-(%sp)
6325
6326 fmov.x %fp0,%fp1
6327 fmul.x %fp1,%fp1
6328 fmov.d ATANA3(%pc),%fp2
6329 fadd.x %fp1,%fp2
6330 fmul.x %fp1,%fp2
6331 fmul.x %fp0,%fp1
6332 fadd.d ATANA2(%pc),%fp2
6333 fmul.d ATANA1(%pc),%fp1
6334 fmul.x %fp2,%fp1
6335 fadd.x %fp1,%fp0
6336
6337 fmovm.x (%sp)+,&0x20
6338
6339 fmov.l %d0,%fpcr
6340 fadd.x ATANF(%a6),%fp0
6341 bra t_inx2
6342
6343ATANBORS:
6344
6345
6346 cmp.l %d1,&0x3FFF8000
6347 bgt.w ATANBIG
6348
6349ATANSM:
6350
6351
6352
6353
6354
6355
6356 cmp.l %d1,&0x3FD78000
6357 blt.w ATANTINY
6358
6359
6360 fmovm.x &0x0c,-(%sp)
6361
6362 fmul.x %fp0,%fp0
6363
6364 fmov.x %fp0,%fp1
6365 fmul.x %fp1,%fp1
6366
6367 fmov.d ATANB6(%pc),%fp2
6368 fmov.d ATANB5(%pc),%fp3
6369
6370 fmul.x %fp1,%fp2
6371 fmul.x %fp1,%fp3
6372
6373 fadd.d ATANB4(%pc),%fp2
6374 fadd.d ATANB3(%pc),%fp3
6375
6376 fmul.x %fp1,%fp2
6377 fmul.x %fp3,%fp1
6378
6379 fadd.d ATANB2(%pc),%fp2
6380 fadd.d ATANB1(%pc),%fp1
6381
6382 fmul.x %fp0,%fp2
6383 fmul.x X(%a6),%fp0
6384
6385 fadd.x %fp2,%fp1
6386
6387 fmul.x %fp1,%fp0
6388
6389 fmovm.x (%sp)+,&0x30
6390
6391 fmov.l %d0,%fpcr
6392 fadd.x X(%a6),%fp0
6393 bra t_inx2
6394
6395ATANTINY:
6396
6397
6398 fmov.l %d0,%fpcr
6399 mov.b &FMOV_OP,%d1
6400 fmov.x X(%a6),%fp0
6401
6402 bra t_catch
6403
6404ATANBIG:
6405
6406
6407 cmp.l %d1,&0x40638000
6408 bgt.w ATANHUGE
6409
6410
6411
6412
6413
6414
6415 fmovm.x &0x0c,-(%sp)
6416
6417 fmov.s &0xBF800000,%fp1
6418 fdiv.x %fp0,%fp1
6419
6420
6421
6422 fmov.x %fp1,%fp0
6423 fmul.x %fp0,%fp0
6424 fmov.x %fp1,X(%a6)
6425
6426 fmov.x %fp0,%fp1
6427 fmul.x %fp1,%fp1
6428
6429 fmov.d ATANC5(%pc),%fp3
6430 fmov.d ATANC4(%pc),%fp2
6431
6432 fmul.x %fp1,%fp3
6433 fmul.x %fp1,%fp2
6434
6435 fadd.d ATANC3(%pc),%fp3
6436 fadd.d ATANC2(%pc),%fp2
6437
6438 fmul.x %fp3,%fp1
6439 fmul.x %fp0,%fp2
6440
6441 fadd.d ATANC1(%pc),%fp1
6442 fmul.x X(%a6),%fp0
6443
6444 fadd.x %fp2,%fp1
6445
6446 fmul.x %fp1,%fp0
6447
6448 fadd.x X(%a6),%fp0
6449
6450 fmovm.x (%sp)+,&0x30
6451
6452 fmov.l %d0,%fpcr
6453 tst.b (%a0)
6454 bpl.b pos_big
6455
6456neg_big:
6457 fadd.x NPIBY2(%pc),%fp0
6458 bra t_minx2
6459
6460pos_big:
6461 fadd.x PPIBY2(%pc),%fp0
6462 bra t_pinx2
6463
6464ATANHUGE:
6465
6466 tst.b (%a0)
6467 bpl.b pos_huge
6468
6469neg_huge:
6470 fmov.x NPIBY2(%pc),%fp0
6471 fmov.l %d0,%fpcr
6472 fadd.x PTINY(%pc),%fp0
6473 bra t_minx2
6474
6475pos_huge:
6476 fmov.x PPIBY2(%pc),%fp0
6477 fmov.l %d0,%fpcr
6478 fadd.x NTINY(%pc),%fp0
6479 bra t_pinx2
6480
6481 global satand
6482
6483satand:
6484 bra t_extdnrm
6485
6486
6487
6488
6489
6490
6491
6492
6493
6494
6495
6496
6497
6498
6499
6500
6501
6502
6503
6504
6505
6506
6507
6508
6509
6510
6511
6512
6513
6514
6515
6516
6517
6518
6519
6520
6521
6522 global sasin
6523sasin:
6524 fmov.x (%a0),%fp0
6525
6526 mov.l (%a0),%d1
6527 mov.w 4(%a0),%d1
6528 and.l &0x7FFFFFFF,%d1
6529 cmp.l %d1,&0x3FFF8000
6530 bge.b ASINBIG
6531
6532
6533
6534
6535
6536
6537 cmp.l %d1,&0x3FD78000
6538 blt.w ASINTINY
6539
6540
6541
6542
6543ASINMAIN:
6544 fmov.s &0x3F800000,%fp1
6545 fsub.x %fp0,%fp1
6546 fmovm.x &0x4,-(%sp)
6547 fmov.s &0x3F800000,%fp2
6548 fadd.x %fp0,%fp2
6549 fmul.x %fp2,%fp1
6550 fmovm.x (%sp)+,&0x20
6551 fsqrt.x %fp1
6552 fdiv.x %fp1,%fp0
6553 fmovm.x &0x01,-(%sp)
6554 lea (%sp),%a0
6555 bsr satan
6556 add.l &0xc,%sp
6557 bra t_inx2
6558
6559ASINBIG:
6560 fabs.x %fp0
6561 fcmp.s %fp0,&0x3F800000
6562 fbgt t_operr
6563
6564
6565ASINONE:
6566 fmov.x PIBY2(%pc),%fp0
6567 mov.l (%a0),%d1
6568 and.l &0x80000000,%d1
6569 or.l &0x3F800000,%d1
6570 mov.l %d1,-(%sp)
6571 fmov.l %d0,%fpcr
6572 fmul.s (%sp)+,%fp0
6573 bra t_inx2
6574
6575
6576ASINTINY:
6577 fmov.l %d0,%fpcr
6578 mov.b &FMOV_OP,%d1
6579 fmov.x (%a0),%fp0
6580 bra t_catch
6581
6582 global sasind
6583
6584sasind:
6585 bra t_extdnrm
6586
6587
6588
6589
6590
6591
6592
6593
6594
6595
6596
6597
6598
6599
6600
6601
6602
6603
6604
6605
6606
6607
6608
6609
6610
6611
6612
6613
6614
6615
6616
6617
6618
6619
6620
6621
6622
6623 global sacos
6624sacos:
6625 fmov.x (%a0),%fp0
6626
6627 mov.l (%a0),%d1
6628 mov.w 4(%a0),%d1
6629 and.l &0x7FFFFFFF,%d1
6630 cmp.l %d1,&0x3FFF8000
6631 bge.b ACOSBIG
6632
6633
6634
6635
6636ACOSMAIN:
6637 fmov.s &0x3F800000,%fp1
6638 fadd.x %fp0,%fp1
6639 fneg.x %fp0
6640 fadd.s &0x3F800000,%fp0
6641 fdiv.x %fp1,%fp0
6642 fsqrt.x %fp0
6643 mov.l %d0,-(%sp)
6644 clr.l %d0
6645 fmovm.x &0x01,-(%sp)
6646 lea (%sp),%a0
6647 bsr satan
6648 add.l &0xc,%sp
6649
6650 fmov.l (%sp)+,%fpcr
6651 fadd.x %fp0,%fp0
6652 bra t_pinx2
6653
6654ACOSBIG:
6655 fabs.x %fp0
6656 fcmp.s %fp0,&0x3F800000
6657 fbgt t_operr
6658
6659
6660 tst.b (%a0)
6661 bpl.b ACOSP1
6662
6663
6664
6665ACOSM1:
6666 fmov.x PI(%pc),%fp0
6667 fmov.l %d0,%fpcr
6668 fadd.s &0x00800000,%fp0
6669 bra t_pinx2
6670
6671ACOSP1:
6672 bra ld_pzero
6673
6674 global sacosd
6675
6676sacosd:
6677 fmov.l %d0,%fpcr
6678 fmov.x PIBY2(%pc),%fp0
6679 bra t_pinx2
6680
6681
6682
6683
6684
6685
6686
6687
6688
6689
6690
6691
6692
6693
6694
6695
6696
6697
6698
6699
6700
6701
6702
6703
6704
6705
6706
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742
6743
6744
6745
6746
6747
6748
6749
6750
6751
6752
6753
6754
6755
6756
6757
6758
6759
6760
6761
6762
6763
6764
6765
6766
6767
6768
6769
6770
6771
6772
6773
6774
6775
6776
6777
6778
6779
6780
6781
6782
6783
6784
6785
6786
6787
6788
6789
6790
6791
6792
6793
6794
6795
6796
6797
6798
6799
6800
6801
6802
6803
6804
6805
6806
6807
6808
6809
6810
6811
6812
6813
6814
6815
6816
6817
6818
6819
6820
6821
6822
6823
6824
6825
6826
6827
6828
6829
6830
6831
6832
6833
6834
6835
6836
6837
6838
6839
6840
6841
6842
6843
6844
6845
6846
6847
6848
6849
6850
6851
6852
6853
6854
6855
6856
6857
6858
6859
6860
6861
6862
6863
6864
6865
6866
6867
6868
6869
6870
6871
6872
6873
6874
6875
6876
6877
6878
6879
6880
6881
6882
6883
6884
6885
6886
6887
6888
6889
6890
6891
6892
6893
6894
6895
6896
6897
6898
6899
6900
6901
6902
6903
6904
6905
6906
6907
6908
6909
6910
6911
6912
6913
6914
6915
6916
6917
6918
6919
6920
6921
6922
6923
6924
6925
6926
6927
6928
6929
6930
6931
6932
6933
6934
6935
6936
6937
6938
6939
6940
6941
6942
6943
6944
6945
6946
6947
6948
6949
6950
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960
6961
6962
6963
6964
6965
6966
6967
6968
6969
6970
6971
6972
6973
6974
6975
6976
6977
6978
6979
6980
6981
6982
6983
6984
6985
6986
6987
6988
6989
6990
6991
6992
6993
6994
6995
6996
6997
6998
6999
7000
7001
7002L2: long 0x3FDC0000,0x82E30865,0x4361C4C6,0x00000000
7003
7004EEXPA3: long 0x3FA55555,0x55554CC1
7005EEXPA2: long 0x3FC55555,0x55554A54
7006
7007EM1A4: long 0x3F811111,0x11174385
7008EM1A3: long 0x3FA55555,0x55554F5A
7009
7010EM1A2: long 0x3FC55555,0x55555555,0x00000000,0x00000000
7011
7012EM1B8: long 0x3EC71DE3,0xA5774682
7013EM1B7: long 0x3EFA01A0,0x19D7CB68
7014
7015EM1B6: long 0x3F2A01A0,0x1A019DF3
7016EM1B5: long 0x3F56C16C,0x16C170E2
7017
7018EM1B4: long 0x3F811111,0x11111111
7019EM1B3: long 0x3FA55555,0x55555555
7020
7021EM1B2: long 0x3FFC0000,0xAAAAAAAA,0xAAAAAAAB
7022 long 0x00000000
7023
7024TWO140: long 0x48B00000,0x00000000
7025TWON140:
7026 long 0x37300000,0x00000000
7027
7028EEXPTBL:
7029 long 0x3FFF0000,0x80000000,0x00000000,0x00000000
7030 long 0x3FFF0000,0x8164D1F3,0xBC030774,0x9F841A9B
7031 long 0x3FFF0000,0x82CD8698,0xAC2BA1D8,0x9FC1D5B9
7032 long 0x3FFF0000,0x843A28C3,0xACDE4048,0xA0728369
7033 long 0x3FFF0000,0x85AAC367,0xCC487B14,0x1FC5C95C
7034 long 0x3FFF0000,0x871F6196,0x9E8D1010,0x1EE85C9F
7035 long 0x3FFF0000,0x88980E80,0x92DA8528,0x9FA20729
7036 long 0x3FFF0000,0x8A14D575,0x496EFD9C,0xA07BF9AF
7037 long 0x3FFF0000,0x8B95C1E3,0xEA8BD6E8,0xA0020DCF
7038 long 0x3FFF0000,0x8D1ADF5B,0x7E5BA9E4,0x205A63DA
7039 long 0x3FFF0000,0x8EA4398B,0x45CD53C0,0x1EB70051
7040 long 0x3FFF0000,0x9031DC43,0x1466B1DC,0x1F6EB029
7041 long 0x3FFF0000,0x91C3D373,0xAB11C338,0xA0781494
7042 long 0x3FFF0000,0x935A2B2F,0x13E6E92C,0x9EB319B0
7043 long 0x3FFF0000,0x94F4EFA8,0xFEF70960,0x2017457D
7044 long 0x3FFF0000,0x96942D37,0x20185A00,0x1F11D537
7045 long 0x3FFF0000,0x9837F051,0x8DB8A970,0x9FB952DD
7046 long 0x3FFF0000,0x99E04593,0x20B7FA64,0x1FE43087
7047 long 0x3FFF0000,0x9B8D39B9,0xD54E5538,0x1FA2A818
7048 long 0x3FFF0000,0x9D3ED9A7,0x2CFFB750,0x1FDE494D
7049 long 0x3FFF0000,0x9EF53260,0x91A111AC,0x20504890
7050 long 0x3FFF0000,0xA0B0510F,0xB9714FC4,0xA073691C
7051 long 0x3FFF0000,0xA2704303,0x0C496818,0x1F9B7A05
7052 long 0x3FFF0000,0xA43515AE,0x09E680A0,0xA0797126
7053 long 0x3FFF0000,0xA5FED6A9,0xB15138EC,0xA071A140
7054 long 0x3FFF0000,0xA7CD93B4,0xE9653568,0x204F62DA
7055 long 0x3FFF0000,0xA9A15AB4,0xEA7C0EF8,0x1F283C4A
7056 long 0x3FFF0000,0xAB7A39B5,0xA93ED338,0x9F9A7FDC
7057 long 0x3FFF0000,0xAD583EEA,0x42A14AC8,0xA05B3FAC
7058 long 0x3FFF0000,0xAF3B78AD,0x690A4374,0x1FDF2610
7059 long 0x3FFF0000,0xB123F581,0xD2AC2590,0x9F705F90
7060 long 0x3FFF0000,0xB311C412,0xA9112488,0x201F678A
7061 long 0x3FFF0000,0xB504F333,0xF9DE6484,0x1F32FB13
7062 long 0x3FFF0000,0xB6FD91E3,0x28D17790,0x20038B30
7063 long 0x3FFF0000,0xB8FBAF47,0x62FB9EE8,0x200DC3CC
7064 long 0x3FFF0000,0xBAFF5AB2,0x133E45FC,0x9F8B2AE6
7065 long 0x3FFF0000,0xBD08A39F,0x580C36C0,0xA02BBF70
7066 long 0x3FFF0000,0xBF1799B6,0x7A731084,0xA00BF518
7067 long 0x3FFF0000,0xC12C4CCA,0x66709458,0xA041DD41
7068 long 0x3FFF0000,0xC346CCDA,0x24976408,0x9FDF137B
7069 long 0x3FFF0000,0xC5672A11,0x5506DADC,0x201F1568
7070 long 0x3FFF0000,0xC78D74C8,0xABB9B15C,0x1FC13A2E
7071 long 0x3FFF0000,0xC9B9BD86,0x6E2F27A4,0xA03F8F03
7072 long 0x3FFF0000,0xCBEC14FE,0xF2727C5C,0x1FF4907D
7073 long 0x3FFF0000,0xCE248C15,0x1F8480E4,0x9E6E53E4
7074 long 0x3FFF0000,0xD06333DA,0xEF2B2594,0x1FD6D45C
7075 long 0x3FFF0000,0xD2A81D91,0xF12AE45C,0xA076EDB9
7076 long 0x3FFF0000,0xD4F35AAB,0xCFEDFA20,0x9FA6DE21
7077 long 0x3FFF0000,0xD744FCCA,0xD69D6AF4,0x1EE69A2F
7078 long 0x3FFF0000,0xD99D15C2,0x78AFD7B4,0x207F439F
7079 long 0x3FFF0000,0xDBFBB797,0xDAF23754,0x201EC207
7080 long 0x3FFF0000,0xDE60F482,0x5E0E9124,0x9E8BE175
7081 long 0x3FFF0000,0xE0CCDEEC,0x2A94E110,0x20032C4B
7082 long 0x3FFF0000,0xE33F8972,0xBE8A5A50,0x2004DFF5
7083 long 0x3FFF0000,0xE5B906E7,0x7C8348A8,0x1E72F47A
7084 long 0x3FFF0000,0xE8396A50,0x3C4BDC68,0x1F722F22
7085 long 0x3FFF0000,0xEAC0C6E7,0xDD243930,0xA017E945
7086 long 0x3FFF0000,0xED4F301E,0xD9942B84,0x1F401A5B
7087 long 0x3FFF0000,0xEFE4B99B,0xDCDAF5CC,0x9FB9A9E3
7088 long 0x3FFF0000,0xF281773C,0x59FFB138,0x20744C05
7089 long 0x3FFF0000,0xF5257D15,0x2486CC2C,0x1F773A19
7090 long 0x3FFF0000,0xF7D0DF73,0x0AD13BB8,0x1FFE90D5
7091 long 0x3FFF0000,0xFA83B2DB,0x722A033C,0xA041ED22
7092 long 0x3FFF0000,0xFD3E0C0C,0xF486C174,0x1F853F3A
7093
7094 set ADJFLAG,L_SCR2
7095 set SCALE,FP_SCR0
7096 set ADJSCALE,FP_SCR1
7097 set SC,FP_SCR0
7098 set ONEBYSC,FP_SCR1
7099
7100 global setox
7101setox:
7102
7103
7104
7105 mov.l (%a0),%d1
7106 and.l &0x7FFF0000,%d1
7107 cmp.l %d1,&0x3FBE0000
7108 bge.b EXPC1
7109 bra EXPSM
7110
7111EXPC1:
7112
7113 mov.w 4(%a0),%d1
7114 cmp.l %d1,&0x400CB167
7115 blt.b EXPMAIN
7116 bra EEXPBIG
7117
7118EXPMAIN:
7119
7120
7121 fmov.x (%a0),%fp0
7122
7123 fmov.x %fp0,%fp1
7124 fmul.s &0x42B8AA3B,%fp0
7125 fmovm.x &0xc,-(%sp)
7126 mov.l &0,ADJFLAG(%a6)
7127 fmov.l %fp0,%d1
7128 lea EEXPTBL(%pc),%a1
7129 fmov.l %d1,%fp0
7130
7131 mov.l %d1,L_SCR1(%a6)
7132 and.l &0x3F,%d1
7133 lsl.l &4,%d1
7134 add.l %d1,%a1
7135 mov.l L_SCR1(%a6),%d1
7136 asr.l &6,%d1
7137 add.w &0x3FFF,%d1
7138 mov.w L2(%pc),L_SCR1(%a6)
7139
7140EXPCONT1:
7141
7142
7143
7144 fmov.x %fp0,%fp2
7145 fmul.s &0xBC317218,%fp0
7146 fmul.x L2(%pc),%fp2
7147 fadd.x %fp1,%fp0
7148 fadd.x %fp2,%fp0
7149
7150
7151
7152
7153
7154
7155
7156 fmov.x %fp0,%fp1
7157 fmul.x %fp1,%fp1
7158
7159 fmov.s &0x3AB60B70,%fp2
7160
7161 fmul.x %fp1,%fp2
7162 fmov.x %fp1,%fp3
7163 fmul.s &0x3C088895,%fp3
7164
7165 fadd.d EEXPA3(%pc),%fp2
7166 fadd.d EEXPA2(%pc),%fp3
7167
7168 fmul.x %fp1,%fp2
7169 mov.w %d1,SCALE(%a6)
7170 mov.l &0x80000000,SCALE+4(%a6)
7171 clr.l SCALE+8(%a6)
7172
7173 fmul.x %fp1,%fp3
7174
7175 fadd.s &0x3F000000,%fp2
7176 fmul.x %fp0,%fp3
7177
7178 fmul.x %fp1,%fp2
7179 fadd.x %fp3,%fp0
7180
7181 fmov.x (%a1)+,%fp1
7182 fadd.x %fp2,%fp0
7183
7184
7185
7186
7187
7188 fmul.x %fp1,%fp0
7189 fmovm.x (%sp)+,&0x30
7190 fadd.s (%a1),%fp0
7191
7192 fadd.x %fp1,%fp0
7193 mov.l ADJFLAG(%a6),%d1
7194
7195
7196 tst.l %d1
7197 beq.b NORMAL
7198ADJUST:
7199 fmul.x ADJSCALE(%a6),%fp0
7200NORMAL:
7201 fmov.l %d0,%fpcr
7202 mov.b &FMUL_OP,%d1
7203 fmul.x SCALE(%a6),%fp0
7204 bra t_catch
7205
7206EXPSM:
7207
7208 fmovm.x (%a0),&0x80
7209 fmov.l %d0,%fpcr
7210 fadd.s &0x3F800000,%fp0
7211 bra t_pinx2
7212
7213EEXPBIG:
7214
7215 cmp.l %d1,&0x400CB27C
7216 bgt.b EXP2BIG
7217
7218 fmov.x (%a0),%fp0
7219
7220 fmov.x %fp0,%fp1
7221 fmul.s &0x42B8AA3B,%fp0
7222 fmovm.x &0xc,-(%sp)
7223 mov.l &1,ADJFLAG(%a6)
7224 fmov.l %fp0,%d1
7225 lea EEXPTBL(%pc),%a1
7226 fmov.l %d1,%fp0
7227 mov.l %d1,L_SCR1(%a6)
7228 and.l &0x3F,%d1
7229 lsl.l &4,%d1
7230 add.l %d1,%a1
7231 mov.l L_SCR1(%a6),%d1
7232 asr.l &6,%d1
7233 mov.l %d1,L_SCR1(%a6)
7234 asr.l &1,%d1
7235 sub.l %d1,L_SCR1(%a6)
7236 add.w &0x3FFF,%d1
7237 mov.w %d1,ADJSCALE(%a6)
7238 mov.l &0x80000000,ADJSCALE+4(%a6)
7239 clr.l ADJSCALE+8(%a6)
7240 mov.l L_SCR1(%a6),%d1
7241 add.w &0x3FFF,%d1
7242 bra.w EXPCONT1
7243
7244EXP2BIG:
7245
7246 tst.b (%a0)
7247 bmi t_unfl2
7248 bra t_ovfl2
7249
7250 global setoxd
7251setoxd:
7252
7253 mov.l (%a0),-(%sp)
7254 andi.l &0x80000000,(%sp)
7255 ori.l &0x00800000,(%sp)
7256
7257 fmov.s &0x3F800000,%fp0
7258
7259 fmov.l %d0,%fpcr
7260 fadd.s (%sp)+,%fp0
7261 bra t_pinx2
7262
7263 global setoxm1
7264setoxm1:
7265
7266
7267
7268
7269 mov.l (%a0),%d1
7270 and.l &0x7FFF0000,%d1
7271 cmp.l %d1,&0x3FFD0000
7272 bge.b EM1CON1
7273 bra EM1SM
7274
7275EM1CON1:
7276
7277
7278 mov.w 4(%a0),%d1
7279 cmp.l %d1,&0x4004C215
7280 ble.b EM1MAIN
7281 bra EM1BIG
7282
7283EM1MAIN:
7284
7285
7286 fmov.x (%a0),%fp0
7287
7288 fmov.x %fp0,%fp1
7289 fmul.s &0x42B8AA3B,%fp0
7290 fmovm.x &0xc,-(%sp)
7291 fmov.l %fp0,%d1
7292 lea EEXPTBL(%pc),%a1
7293 fmov.l %d1,%fp0
7294
7295 mov.l %d1,L_SCR1(%a6)
7296 and.l &0x3F,%d1
7297 lsl.l &4,%d1
7298 add.l %d1,%a1
7299 mov.l L_SCR1(%a6),%d1
7300 asr.l &6,%d1
7301 mov.l %d1,L_SCR1(%a6)
7302
7303
7304
7305
7306 fmov.x %fp0,%fp2
7307 fmul.s &0xBC317218,%fp0
7308 fmul.x L2(%pc),%fp2
7309 fadd.x %fp1,%fp0
7310 fadd.x %fp2,%fp0
7311 add.w &0x3FFF,%d1
7312
7313
7314
7315
7316
7317
7318
7319 fmov.x %fp0,%fp1
7320 fmul.x %fp1,%fp1
7321
7322 fmov.s &0x3950097B,%fp2
7323
7324 fmul.x %fp1,%fp2
7325 fmov.x %fp1,%fp3
7326 fmul.s &0x3AB60B6A,%fp3
7327
7328 fadd.d EM1A4(%pc),%fp2
7329 fadd.d EM1A3(%pc),%fp3
7330 mov.w %d1,SC(%a6)
7331 mov.l &0x80000000,SC+4(%a6)
7332 clr.l SC+8(%a6)
7333
7334 fmul.x %fp1,%fp2
7335 mov.l L_SCR1(%a6),%d1
7336 neg.w %d1
7337 fmul.x %fp1,%fp3
7338 add.w &0x3FFF,%d1
7339 fadd.d EM1A2(%pc),%fp2
7340 fadd.s &0x3F000000,%fp3
7341
7342 fmul.x %fp1,%fp2
7343 or.w &0x8000,%d1
7344 mov.w %d1,ONEBYSC(%a6)
7345 mov.l &0x80000000,ONEBYSC+4(%a6)
7346 clr.l ONEBYSC+8(%a6)
7347 fmul.x %fp3,%fp1
7348
7349 fmul.x %fp0,%fp2
7350 fadd.x %fp1,%fp0
7351
7352 fadd.x %fp2,%fp0
7353
7354 fmovm.x (%sp)+,&0x30
7355
7356
7357
7358
7359 fmul.x (%a1),%fp0
7360
7361
7362
7363 mov.l L_SCR1(%a6),%d1
7364 cmp.l %d1,&63
7365 ble.b MLE63
7366
7367 fmov.s 12(%a1),%fp1
7368 fadd.x ONEBYSC(%a6),%fp1
7369 fadd.x %fp1,%fp0
7370 fadd.x (%a1),%fp0
7371 bra EM1SCALE
7372MLE63:
7373
7374 cmp.l %d1,&-3
7375 bge.b MGEN3
7376MLTN3:
7377
7378 fadd.s 12(%a1),%fp0
7379 fadd.x (%a1),%fp0
7380 fadd.x ONEBYSC(%a6),%fp0
7381 bra EM1SCALE
7382MGEN3:
7383
7384 fmov.x (%a1)+,%fp1
7385 fadd.s (%a1),%fp0
7386 fadd.x ONEBYSC(%a6),%fp1
7387 fadd.x %fp1,%fp0
7388
7389EM1SCALE:
7390
7391 fmov.l %d0,%fpcr
7392 fmul.x SC(%a6),%fp0
7393 bra t_inx2
7394
7395EM1SM:
7396
7397 cmp.l %d1,&0x3FBE0000
7398 bge.b EM1POLY
7399
7400EM1TINY:
7401
7402 cmp.l %d1,&0x00330000
7403 blt.b EM12TINY
7404
7405 mov.l &0x80010000,SC(%a6)
7406 mov.l &0x80000000,SC+4(%a6)
7407 clr.l SC+8(%a6)
7408 fmov.x (%a0),%fp0
7409 fmov.l %d0,%fpcr
7410 mov.b &FADD_OP,%d1
7411 fadd.x SC(%a6),%fp0
7412 bra t_catch
7413
7414EM12TINY:
7415
7416 fmov.x (%a0),%fp0
7417 fmul.d TWO140(%pc),%fp0
7418 mov.l &0x80010000,SC(%a6)
7419 mov.l &0x80000000,SC+4(%a6)
7420 clr.l SC+8(%a6)
7421 fadd.x SC(%a6),%fp0
7422 fmov.l %d0,%fpcr
7423 mov.b &FMUL_OP,%d1
7424 fmul.d TWON140(%pc),%fp0
7425 bra t_catch
7426
7427EM1POLY:
7428
7429 fmov.x (%a0),%fp0
7430 fmul.x %fp0,%fp0
7431 fmovm.x &0xc,-(%sp)
7432 fmov.s &0x2F30CAA8,%fp1
7433 fmul.x %fp0,%fp1
7434 fmov.s &0x310F8290,%fp2
7435 fadd.s &0x32D73220,%fp1
7436
7437 fmul.x %fp0,%fp2
7438 fmul.x %fp0,%fp1
7439
7440 fadd.s &0x3493F281,%fp2
7441 fadd.d EM1B8(%pc),%fp1
7442
7443 fmul.x %fp0,%fp2
7444 fmul.x %fp0,%fp1
7445
7446 fadd.d EM1B7(%pc),%fp2
7447 fadd.d EM1B6(%pc),%fp1
7448
7449 fmul.x %fp0,%fp2
7450 fmul.x %fp0,%fp1
7451
7452 fadd.d EM1B5(%pc),%fp2
7453 fadd.d EM1B4(%pc),%fp1
7454
7455 fmul.x %fp0,%fp2
7456 fmul.x %fp0,%fp1
7457
7458 fadd.d EM1B3(%pc),%fp2
7459 fadd.x EM1B2(%pc),%fp1
7460
7461 fmul.x %fp0,%fp2
7462 fmul.x %fp0,%fp1
7463
7464 fmul.x %fp0,%fp2
7465 fmul.x (%a0),%fp1
7466
7467 fmul.s &0x3F000000,%fp0
7468 fadd.x %fp2,%fp1
7469
7470 fmovm.x (%sp)+,&0x30
7471
7472 fadd.x %fp1,%fp0
7473
7474 fmov.l %d0,%fpcr
7475 fadd.x (%a0),%fp0
7476 bra t_inx2
7477
7478EM1BIG:
7479
7480 mov.l (%a0),%d1
7481 cmp.l %d1,&0
7482 bgt.w EXPC1
7483
7484 fmov.s &0xBF800000,%fp0
7485 fmov.l %d0,%fpcr
7486 fadd.s &0x00800000,%fp0
7487 bra t_minx2
7488
7489 global setoxm1d
7490setoxm1d:
7491
7492
7493 bra t_extdnrm
7494
7495
7496
7497
7498
7499
7500
7501
7502
7503
7504
7505
7506
7507
7508
7509
7510
7511
7512
7513
7514
7515 global sgetexp
7516sgetexp:
7517 mov.w SRC_EX(%a0),%d0
7518 bclr &0xf,%d0
7519 subi.w &0x3fff,%d0
7520 fmov.w %d0,%fp0
7521 blt.b sgetexpn
7522 rts
7523
7524sgetexpn:
7525 mov.b &neg_bmask,FPSR_CC(%a6)
7526 rts
7527
7528 global sgetexpd
7529sgetexpd:
7530 bsr.l norm
7531 neg.w %d0
7532 subi.w &0x3fff,%d0
7533 fmov.w %d0,%fp0
7534 mov.b &neg_bmask,FPSR_CC(%a6)
7535 rts
7536
7537 global sgetman
7538sgetman:
7539 mov.w SRC_EX(%a0),%d0
7540 ori.w &0x7fff,%d0
7541 bclr &0xe,%d0
7542
7543
7544 mov.l SRC_HI(%a0),FP_SCR0_HI(%a6)
7545 mov.l SRC_LO(%a0),FP_SCR0_LO(%a6)
7546 mov.w %d0,FP_SCR0_EX(%a6)
7547 fmov.x FP_SCR0(%a6),%fp0
7548 bmi.b sgetmann
7549 rts
7550
7551sgetmann:
7552 mov.b &neg_bmask,FPSR_CC(%a6)
7553 rts
7554
7555
7556
7557
7558
7559 global sgetmand
7560sgetmand:
7561 bsr.l norm
7562 bra.b sgetman
7563
7564
7565
7566
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579
7580
7581
7582
7583
7584
7585
7586
7587
7588
7589
7590
7591
7592
7593
7594
7595
7596
7597
7598
7599
7600
7601
7602
7603
7604
7605
7606
7607
7608
7609
7610TWO16380:
7611 long 0x7FFB0000,0x80000000,0x00000000,0x00000000
7612
7613 global scosh
7614scosh:
7615 fmov.x (%a0),%fp0
7616
7617 mov.l (%a0),%d1
7618 mov.w 4(%a0),%d1
7619 and.l &0x7FFFFFFF,%d1
7620 cmp.l %d1,&0x400CB167
7621 bgt.b COSHBIG
7622
7623
7624
7625
7626 fabs.x %fp0
7627
7628 mov.l %d0,-(%sp)
7629 clr.l %d0
7630 fmovm.x &0x01,-(%sp)
7631 lea (%sp),%a0
7632 bsr setox
7633 add.l &0xc,%sp
7634 fmul.s &0x3F000000,%fp0
7635 mov.l (%sp)+,%d0
7636
7637 fmov.s &0x3E800000,%fp1
7638 fdiv.x %fp0,%fp1
7639
7640 fmov.l %d0,%fpcr
7641 mov.b &FADD_OP,%d1
7642 fadd.x %fp1,%fp0
7643 bra t_catch
7644
7645COSHBIG:
7646 cmp.l %d1,&0x400CB2B3
7647 bgt.b COSHHUGE
7648
7649 fabs.x %fp0
7650 fsub.d T1(%pc),%fp0
7651 fsub.d T2(%pc),%fp0
7652
7653 mov.l %d0,-(%sp)
7654 clr.l %d0
7655 fmovm.x &0x01,-(%sp)
7656 lea (%sp),%a0
7657 bsr setox
7658 add.l &0xc,%sp
7659 mov.l (%sp)+,%d0
7660
7661 fmov.l %d0,%fpcr
7662 mov.b &FMUL_OP,%d1
7663 fmul.x TWO16380(%pc),%fp0
7664 bra t_catch
7665
7666COSHHUGE:
7667 bra t_ovfl2
7668
7669 global scoshd
7670
7671scoshd:
7672 fmov.s &0x3F800000,%fp0
7673
7674 fmov.l %d0,%fpcr
7675 fadd.s &0x00800000,%fp0
7676 bra t_pinx2
7677
7678
7679
7680
7681
7682
7683
7684
7685
7686
7687
7688
7689
7690
7691
7692
7693
7694
7695
7696
7697
7698
7699
7700
7701
7702
7703
7704
7705
7706
7707
7708
7709
7710
7711
7712
7713
7714
7715
7716
7717
7718
7719
7720
7721
7722
7723
7724
7725 global ssinh
7726ssinh:
7727 fmov.x (%a0),%fp0
7728
7729 mov.l (%a0),%d1
7730 mov.w 4(%a0),%d1
7731 mov.l %d1,%a1
7732 and.l &0x7FFFFFFF,%d1
7733 cmp.l %d1,&0x400CB167
7734 bgt.b SINHBIG
7735
7736
7737
7738
7739 fabs.x %fp0
7740
7741 movm.l &0x8040,-(%sp)
7742 fmovm.x &0x01,-(%sp)
7743 lea (%sp),%a0
7744 clr.l %d0
7745 bsr setoxm1
7746 add.l &0xc,%sp
7747 fmov.l &0,%fpcr
7748 movm.l (%sp)+,&0x0201
7749
7750 fmov.x %fp0,%fp1
7751 fadd.s &0x3F800000,%fp1
7752 fmov.x %fp0,-(%sp)
7753 fdiv.x %fp1,%fp0
7754 mov.l %a1,%d1
7755 and.l &0x80000000,%d1
7756 or.l &0x3F000000,%d1
7757 fadd.x (%sp)+,%fp0
7758 mov.l %d1,-(%sp)
7759
7760 fmov.l %d0,%fpcr
7761 mov.b &FMUL_OP,%d1
7762 fmul.s (%sp)+,%fp0
7763 bra t_catch
7764
7765SINHBIG:
7766 cmp.l %d1,&0x400CB2B3
7767 bgt t_ovfl
7768 fabs.x %fp0
7769 fsub.d T1(%pc),%fp0
7770 mov.l &0,-(%sp)
7771 mov.l &0x80000000,-(%sp)
7772 mov.l %a1,%d1
7773 and.l &0x80000000,%d1
7774 or.l &0x7FFB0000,%d1
7775 mov.l %d1,-(%sp)
7776 fsub.d T2(%pc),%fp0
7777
7778 mov.l %d0,-(%sp)
7779 clr.l %d0
7780 fmovm.x &0x01,-(%sp)
7781 lea (%sp),%a0
7782 bsr setox
7783 add.l &0xc,%sp
7784
7785 mov.l (%sp)+,%d0
7786 fmov.l %d0,%fpcr
7787 mov.b &FMUL_OP,%d1
7788 fmul.x (%sp)+,%fp0
7789 bra t_catch
7790
7791 global ssinhd
7792
7793ssinhd:
7794 bra t_extdnrm
7795
7796
7797
7798
7799
7800
7801
7802
7803
7804
7805
7806
7807
7808
7809
7810
7811
7812
7813
7814
7815
7816
7817
7818
7819
7820
7821
7822
7823
7824
7825
7826
7827
7828
7829
7830
7831
7832
7833
7834
7835
7836
7837
7838
7839
7840
7841
7842
7843 set X,FP_SCR0
7844 set XFRAC,X+4
7845
7846 set SGN,L_SCR3
7847
7848 set V,FP_SCR0
7849
7850 global stanh
7851stanh:
7852 fmov.x (%a0),%fp0
7853
7854 fmov.x %fp0,X(%a6)
7855 mov.l (%a0),%d1
7856 mov.w 4(%a0),%d1
7857 mov.l %d1,X(%a6)
7858 and.l &0x7FFFFFFF,%d1
7859 cmp.l %d1, &0x3fd78000
7860 blt.w TANHBORS
7861 cmp.l %d1, &0x3fffddce
7862 bgt.w TANHBORS
7863
7864
7865
7866
7867 mov.l X(%a6),%d1
7868 mov.l %d1,SGN(%a6)
7869 and.l &0x7FFF0000,%d1
7870 add.l &0x00010000,%d1
7871 mov.l %d1,X(%a6)
7872 and.l &0x80000000,SGN(%a6)
7873 fmov.x X(%a6),%fp0
7874
7875 mov.l %d0,-(%sp)
7876 clr.l %d0
7877 fmovm.x &0x1,-(%sp)
7878 lea (%sp),%a0
7879 bsr setoxm1
7880 add.l &0xc,%sp
7881 mov.l (%sp)+,%d0
7882
7883 fmov.x %fp0,%fp1
7884 fadd.s &0x40000000,%fp1
7885 mov.l SGN(%a6),%d1
7886 fmov.x %fp1,V(%a6)
7887 eor.l %d1,V(%a6)
7888
7889 fmov.l %d0,%fpcr
7890 fdiv.x V(%a6),%fp0
7891 bra t_inx2
7892
7893TANHBORS:
7894 cmp.l %d1,&0x3FFF8000
7895 blt.w TANHSM
7896
7897 cmp.l %d1,&0x40048AA1
7898 bgt.w TANHHUGE
7899
7900
7901
7902
7903
7904 mov.l X(%a6),%d1
7905 mov.l %d1,SGN(%a6)
7906 and.l &0x7FFF0000,%d1
7907 add.l &0x00010000,%d1
7908 mov.l %d1,X(%a6)
7909 and.l &0x80000000,SGN(%a6)
7910 mov.l SGN(%a6),%d1
7911 fmov.x X(%a6),%fp0
7912
7913 mov.l %d0,-(%sp)
7914 clr.l %d0
7915 fmovm.x &0x01,-(%sp)
7916 lea (%sp),%a0
7917 bsr setox
7918 add.l &0xc,%sp
7919 mov.l (%sp)+,%d0
7920 mov.l SGN(%a6),%d1
7921 fadd.s &0x3F800000,%fp0
7922
7923 eor.l &0xC0000000,%d1
7924 fmov.s %d1,%fp1
7925 fdiv.x %fp0,%fp1
7926
7927 mov.l SGN(%a6),%d1
7928 or.l &0x3F800000,%d1
7929 fmov.s %d1,%fp0
7930
7931 fmov.l %d0,%fpcr
7932 mov.b &FADD_OP,%d1
7933 fadd.x %fp1,%fp0
7934 bra t_inx2
7935
7936TANHSM:
7937 fmov.l %d0,%fpcr
7938 mov.b &FMOV_OP,%d1
7939 fmov.x X(%a6),%fp0
7940 bra t_catch
7941
7942
7943TANHHUGE:
7944 mov.l X(%a6),%d1
7945 and.l &0x80000000,%d1
7946 or.l &0x3F800000,%d1
7947 fmov.s %d1,%fp0
7948 and.l &0x80000000,%d1
7949 eor.l &0x80800000,%d1
7950
7951 fmov.l %d0,%fpcr
7952 fadd.s %d1,%fp0
7953 bra t_inx2
7954
7955 global stanhd
7956
7957stanhd:
7958 bra t_extdnrm
7959
7960
7961
7962
7963
7964
7965
7966
7967
7968
7969
7970
7971
7972
7973
7974
7975
7976
7977
7978
7979
7980
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990
7991
7992
7993
7994
7995
7996
7997
7998
7999
8000
8001
8002
8003
8004
8005
8006
8007
8008
8009
8010
8011
8012
8013
8014
8015
8016
8017
8018
8019
8020
8021
8022
8023LOGOF2:
8024 long 0x3FFE0000,0xB17217F7,0xD1CF79AC,0x00000000
8025
8026one:
8027 long 0x3F800000
8028zero:
8029 long 0x00000000
8030infty:
8031 long 0x7F800000
8032negone:
8033 long 0xBF800000
8034
8035LOGA6:
8036 long 0x3FC2499A,0xB5E4040B
8037LOGA5:
8038 long 0xBFC555B5,0x848CB7DB
8039
8040LOGA4:
8041 long 0x3FC99999,0x987D8730
8042LOGA3:
8043 long 0xBFCFFFFF,0xFF6F7E97
8044
8045LOGA2:
8046 long 0x3FD55555,0x555555A4
8047LOGA1:
8048 long 0xBFE00000,0x00000008
8049
8050LOGB5:
8051 long 0x3F175496,0xADD7DAD6
8052LOGB4:
8053 long 0x3F3C71C2,0xFE80C7E0
8054
8055LOGB3:
8056 long 0x3F624924,0x928BCCFF
8057LOGB2:
8058 long 0x3F899999,0x999995EC
8059
8060LOGB1:
8061 long 0x3FB55555,0x55555555
8062TWO:
8063 long 0x40000000,0x00000000
8064
8065LTHOLD:
8066 long 0x3f990000,0x80000000,0x00000000,0x00000000
8067
8068LOGTBL:
8069 long 0x3FFE0000,0xFE03F80F,0xE03F80FE,0x00000000
8070 long 0x3FF70000,0xFF015358,0x833C47E2,0x00000000
8071 long 0x3FFE0000,0xFA232CF2,0x52138AC0,0x00000000
8072 long 0x3FF90000,0xBDC8D83E,0xAD88D549,0x00000000
8073 long 0x3FFE0000,0xF6603D98,0x0F6603DA,0x00000000
8074 long 0x3FFA0000,0x9CF43DCF,0xF5EAFD48,0x00000000
8075 long 0x3FFE0000,0xF2B9D648,0x0F2B9D65,0x00000000
8076 long 0x3FFA0000,0xDA16EB88,0xCB8DF614,0x00000000
8077 long 0x3FFE0000,0xEF2EB71F,0xC4345238,0x00000000
8078 long 0x3FFB0000,0x8B29B775,0x1BD70743,0x00000000
8079 long 0x3FFE0000,0xEBBDB2A5,0xC1619C8C,0x00000000
8080 long 0x3FFB0000,0xA8D839F8,0x30C1FB49,0x00000000
8081 long 0x3FFE0000,0xE865AC7B,0x7603A197,0x00000000
8082 long 0x3FFB0000,0xC61A2EB1,0x8CD907AD,0x00000000
8083 long 0x3FFE0000,0xE525982A,0xF70C880E,0x00000000
8084 long 0x3FFB0000,0xE2F2A47A,0xDE3A18AF,0x00000000
8085 long 0x3FFE0000,0xE1FC780E,0x1FC780E2,0x00000000
8086 long 0x3FFB0000,0xFF64898E,0xDF55D551,0x00000000
8087 long 0x3FFE0000,0xDEE95C4C,0xA037BA57,0x00000000
8088 long 0x3FFC0000,0x8DB956A9,0x7B3D0148,0x00000000
8089 long 0x3FFE0000,0xDBEB61EE,0xD19C5958,0x00000000
8090 long 0x3FFC0000,0x9B8FE100,0xF47BA1DE,0x00000000
8091 long 0x3FFE0000,0xD901B203,0x6406C80E,0x00000000
8092 long 0x3FFC0000,0xA9372F1D,0x0DA1BD17,0x00000000
8093 long 0x3FFE0000,0xD62B80D6,0x2B80D62C,0x00000000
8094 long 0x3FFC0000,0xB6B07F38,0xCE90E46B,0x00000000
8095 long 0x3FFE0000,0xD3680D36,0x80D3680D,0x00000000
8096 long 0x3FFC0000,0xC3FD0329,0x06488481,0x00000000
8097 long 0x3FFE0000,0xD0B69FCB,0xD2580D0B,0x00000000
8098 long 0x3FFC0000,0xD11DE0FF,0x15AB18CA,0x00000000
8099 long 0x3FFE0000,0xCE168A77,0x25080CE1,0x00000000
8100 long 0x3FFC0000,0xDE1433A1,0x6C66B150,0x00000000
8101 long 0x3FFE0000,0xCB8727C0,0x65C393E0,0x00000000
8102 long 0x3FFC0000,0xEAE10B5A,0x7DDC8ADD,0x00000000
8103 long 0x3FFE0000,0xC907DA4E,0x871146AD,0x00000000
8104 long 0x3FFC0000,0xF7856E5E,0xE2C9B291,0x00000000
8105 long 0x3FFE0000,0xC6980C69,0x80C6980C,0x00000000
8106 long 0x3FFD0000,0x82012CA5,0xA68206D7,0x00000000
8107 long 0x3FFE0000,0xC4372F85,0x5D824CA6,0x00000000
8108 long 0x3FFD0000,0x882C5FCD,0x7256A8C5,0x00000000
8109 long 0x3FFE0000,0xC1E4BBD5,0x95F6E947,0x00000000
8110 long 0x3FFD0000,0x8E44C60B,0x4CCFD7DE,0x00000000
8111 long 0x3FFE0000,0xBFA02FE8,0x0BFA02FF,0x00000000
8112 long 0x3FFD0000,0x944AD09E,0xF4351AF6,0x00000000
8113 long 0x3FFE0000,0xBD691047,0x07661AA3,0x00000000
8114 long 0x3FFD0000,0x9A3EECD4,0xC3EAA6B2,0x00000000
8115 long 0x3FFE0000,0xBB3EE721,0xA54D880C,0x00000000
8116 long 0x3FFD0000,0xA0218434,0x353F1DE8,0x00000000
8117 long 0x3FFE0000,0xB92143FA,0x36F5E02E,0x00000000
8118 long 0x3FFD0000,0xA5F2FCAB,0xBBC506DA,0x00000000
8119 long 0x3FFE0000,0xB70FBB5A,0x19BE3659,0x00000000
8120 long 0x3FFD0000,0xABB3B8BA,0x2AD362A5,0x00000000
8121 long 0x3FFE0000,0xB509E68A,0x9B94821F,0x00000000
8122 long 0x3FFD0000,0xB1641795,0xCE3CA97B,0x00000000
8123 long 0x3FFE0000,0xB30F6352,0x8917C80B,0x00000000
8124 long 0x3FFD0000,0xB7047551,0x5D0F1C61,0x00000000
8125 long 0x3FFE0000,0xB11FD3B8,0x0B11FD3C,0x00000000
8126 long 0x3FFD0000,0xBC952AFE,0xEA3D13E1,0x00000000
8127 long 0x3FFE0000,0xAF3ADDC6,0x80AF3ADE,0x00000000
8128 long 0x3FFD0000,0xC2168ED0,0xF458BA4A,0x00000000
8129 long 0x3FFE0000,0xAD602B58,0x0AD602B6,0x00000000
8130 long 0x3FFD0000,0xC788F439,0xB3163BF1,0x00000000
8131 long 0x3FFE0000,0xAB8F69E2,0x8359CD11,0x00000000
8132 long 0x3FFD0000,0xCCECAC08,0xBF04565D,0x00000000
8133 long 0x3FFE0000,0xA9C84A47,0xA07F5638,0x00000000
8134 long 0x3FFD0000,0xD2420487,0x2DD85160,0x00000000
8135 long 0x3FFE0000,0xA80A80A8,0x0A80A80B,0x00000000
8136 long 0x3FFD0000,0xD7894992,0x3BC3588A,0x00000000
8137 long 0x3FFE0000,0xA655C439,0x2D7B73A8,0x00000000
8138 long 0x3FFD0000,0xDCC2C4B4,0x9887DACC,0x00000000
8139 long 0x3FFE0000,0xA4A9CF1D,0x96833751,0x00000000
8140 long 0x3FFD0000,0xE1EEBD3E,0x6D6A6B9E,0x00000000
8141 long 0x3FFE0000,0xA3065E3F,0xAE7CD0E0,0x00000000
8142 long 0x3FFD0000,0xE70D785C,0x2F9F5BDC,0x00000000
8143 long 0x3FFE0000,0xA16B312E,0xA8FC377D,0x00000000
8144 long 0x3FFD0000,0xEC1F392C,0x5179F283,0x00000000
8145 long 0x3FFE0000,0x9FD809FD,0x809FD80A,0x00000000
8146 long 0x3FFD0000,0xF12440D3,0xE36130E6,0x00000000
8147 long 0x3FFE0000,0x9E4CAD23,0xDD5F3A20,0x00000000
8148 long 0x3FFD0000,0xF61CCE92,0x346600BB,0x00000000
8149 long 0x3FFE0000,0x9CC8E160,0xC3FB19B9,0x00000000
8150 long 0x3FFD0000,0xFB091FD3,0x8145630A,0x00000000
8151 long 0x3FFE0000,0x9B4C6F9E,0xF03A3CAA,0x00000000
8152 long 0x3FFD0000,0xFFE97042,0xBFA4C2AD,0x00000000
8153 long 0x3FFE0000,0x99D722DA,0xBDE58F06,0x00000000
8154 long 0x3FFE0000,0x825EFCED,0x49369330,0x00000000
8155 long 0x3FFE0000,0x9868C809,0x868C8098,0x00000000
8156 long 0x3FFE0000,0x84C37A7A,0xB9A905C9,0x00000000
8157 long 0x3FFE0000,0x97012E02,0x5C04B809,0x00000000
8158 long 0x3FFE0000,0x87224C2E,0x8E645FB7,0x00000000
8159 long 0x3FFE0000,0x95A02568,0x095A0257,0x00000000
8160 long 0x3FFE0000,0x897B8CAC,0x9F7DE298,0x00000000
8161 long 0x3FFE0000,0x94458094,0x45809446,0x00000000
8162 long 0x3FFE0000,0x8BCF55DE,0xC4CD05FE,0x00000000
8163 long 0x3FFE0000,0x92F11384,0x0497889C,0x00000000
8164 long 0x3FFE0000,0x8E1DC0FB,0x89E125E5,0x00000000
8165 long 0x3FFE0000,0x91A2B3C4,0xD5E6F809,0x00000000
8166 long 0x3FFE0000,0x9066E68C,0x955B6C9B,0x00000000
8167 long 0x3FFE0000,0x905A3863,0x3E06C43B,0x00000000
8168 long 0x3FFE0000,0x92AADE74,0xC7BE59E0,0x00000000
8169 long 0x3FFE0000,0x8F1779D9,0xFDC3A219,0x00000000
8170 long 0x3FFE0000,0x94E9BFF6,0x15845643,0x00000000
8171 long 0x3FFE0000,0x8DDA5202,0x37694809,0x00000000
8172 long 0x3FFE0000,0x9723A1B7,0x20134203,0x00000000
8173 long 0x3FFE0000,0x8CA29C04,0x6514E023,0x00000000
8174 long 0x3FFE0000,0x995899C8,0x90EB8990,0x00000000
8175 long 0x3FFE0000,0x8B70344A,0x139BC75A,0x00000000
8176 long 0x3FFE0000,0x9B88BDAA,0x3A3DAE2F,0x00000000
8177 long 0x3FFE0000,0x8A42F870,0x5669DB46,0x00000000
8178 long 0x3FFE0000,0x9DB4224F,0xFFE1157C,0x00000000
8179 long 0x3FFE0000,0x891AC73A,0xE9819B50,0x00000000
8180 long 0x3FFE0000,0x9FDADC26,0x8B7A12DA,0x00000000
8181 long 0x3FFE0000,0x87F78087,0xF78087F8,0x00000000
8182 long 0x3FFE0000,0xA1FCFF17,0xCE733BD4,0x00000000
8183 long 0x3FFE0000,0x86D90544,0x7A34ACC6,0x00000000
8184 long 0x3FFE0000,0xA41A9E8F,0x5446FB9F,0x00000000
8185 long 0x3FFE0000,0x85BF3761,0x2CEE3C9B,0x00000000
8186 long 0x3FFE0000,0xA633CD7E,0x6771CD8B,0x00000000
8187 long 0x3FFE0000,0x84A9F9C8,0x084A9F9D,0x00000000
8188 long 0x3FFE0000,0xA8489E60,0x0B435A5E,0x00000000
8189 long 0x3FFE0000,0x83993052,0x3FBE3368,0x00000000
8190 long 0x3FFE0000,0xAA59233C,0xCCA4BD49,0x00000000
8191 long 0x3FFE0000,0x828CBFBE,0xB9A020A3,0x00000000
8192 long 0x3FFE0000,0xAC656DAE,0x6BCC4985,0x00000000
8193 long 0x3FFE0000,0x81848DA8,0xFAF0D277,0x00000000
8194 long 0x3FFE0000,0xAE6D8EE3,0x60BB2468,0x00000000
8195 long 0x3FFE0000,0x80808080,0x80808081,0x00000000
8196 long 0x3FFE0000,0xB07197A2,0x3C46C654,0x00000000
8197
8198 set ADJK,L_SCR1
8199
8200 set X,FP_SCR0
8201 set XDCARE,X+2
8202 set XFRAC,X+4
8203
8204 set F,FP_SCR1
8205 set FFRAC,F+4
8206
8207 set KLOG2,FP_SCR0
8208
8209 set SAVEU,FP_SCR0
8210
8211 global slogn
8212
8213slogn:
8214 fmov.x (%a0),%fp0
8215 mov.l &0x00000000,ADJK(%a6)
8216
8217LOGBGN:
8218
8219
8220
8221 mov.l (%a0),%d1
8222 mov.w 4(%a0),%d1
8223
8224 mov.l (%a0),X(%a6)
8225 mov.l 4(%a0),X+4(%a6)
8226 mov.l 8(%a0),X+8(%a6)
8227
8228 cmp.l %d1,&0
8229 blt.w LOGNEG
8230
8231 cmp.l %d1,&0x3ffef07d
8232 blt.b LOGMAIN
8233 cmp.l %d1,&0x3fff8841
8234 ble.w LOGNEAR1
8235
8236LOGMAIN:
8237
8238
8239
8240
8241
8242
8243
8244
8245
8246
8247
8248
8249 asr.l &8,%d1
8250 asr.l &8,%d1
8251 sub.l &0x3FFF,%d1
8252 add.l ADJK(%a6),%d1
8253 lea LOGTBL(%pc),%a0
8254 fmov.l %d1,%fp1
8255
8256
8257 mov.l &0x3FFF0000,X(%a6)
8258 mov.l XFRAC(%a6),FFRAC(%a6)
8259 and.l &0xFE000000,FFRAC(%a6)
8260 or.l &0x01000000,FFRAC(%a6)
8261 mov.l FFRAC(%a6),%d1
8262 and.l &0x7E000000,%d1
8263 asr.l &8,%d1
8264 asr.l &8,%d1
8265 asr.l &4,%d1
8266 add.l %d1,%a0
8267
8268 fmov.x X(%a6),%fp0
8269 mov.l &0x3fff0000,F(%a6)
8270 clr.l F+8(%a6)
8271 fsub.x F(%a6),%fp0
8272 fmovm.x &0xc,-(%sp)
8273
8274
8275
8276LP1CONT1:
8277
8278 fmul.x (%a0),%fp0
8279 fmul.x LOGOF2(%pc),%fp1
8280 fmov.x %fp0,%fp2
8281 fmul.x %fp2,%fp2
8282 fmov.x %fp1,KLOG2(%a6)
8283
8284
8285
8286
8287
8288 fmov.x %fp2,%fp3
8289 fmov.x %fp2,%fp1
8290
8291 fmul.d LOGA6(%pc),%fp1
8292 fmul.d LOGA5(%pc),%fp2
8293
8294 fadd.d LOGA4(%pc),%fp1
8295 fadd.d LOGA3(%pc),%fp2
8296
8297 fmul.x %fp3,%fp1
8298 fmul.x %fp3,%fp2
8299
8300 fadd.d LOGA2(%pc),%fp1
8301 fadd.d LOGA1(%pc),%fp2
8302
8303 fmul.x %fp3,%fp1
8304 add.l &16,%a0
8305 fmul.x %fp3,%fp2
8306
8307 fmul.x %fp0,%fp1
8308 fadd.x %fp2,%fp0
8309
8310 fadd.x (%a0),%fp1
8311 fmovm.x (%sp)+,&0x30
8312 fadd.x %fp1,%fp0
8313
8314 fmov.l %d0,%fpcr
8315 fadd.x KLOG2(%a6),%fp0
8316 bra t_inx2
8317
8318
8319LOGNEAR1:
8320
8321
8322
8323
8324 fcmp.b %fp0,&0x1
8325 fbeq.l ld_pzero
8326
8327
8328 fmov.x %fp0,%fp1
8329 fsub.s one(%pc),%fp1
8330 fadd.s one(%pc),%fp0
8331 fadd.x %fp1,%fp1
8332
8333
8334
8335LP1CONT2:
8336
8337 fdiv.x %fp0,%fp1
8338 fmovm.x &0xc,-(%sp)
8339
8340
8341
8342
8343 fmov.x %fp1,%fp0
8344 fmul.x %fp0,%fp0
8345 fmov.x %fp1,SAVEU(%a6)
8346 fmov.x %fp0,%fp1
8347 fmul.x %fp1,%fp1
8348
8349 fmov.d LOGB5(%pc),%fp3
8350 fmov.d LOGB4(%pc),%fp2
8351
8352 fmul.x %fp1,%fp3
8353 fmul.x %fp1,%fp2
8354
8355 fadd.d LOGB3(%pc),%fp3
8356 fadd.d LOGB2(%pc),%fp2
8357
8358 fmul.x %fp3,%fp1
8359
8360 fmul.x %fp0,%fp2
8361
8362 fadd.d LOGB1(%pc),%fp1
8363 fmul.x SAVEU(%a6),%fp0
8364
8365 fadd.x %fp2,%fp1
8366 fmovm.x (%sp)+,&0x30
8367
8368 fmul.x %fp1,%fp0
8369
8370 fmov.l %d0,%fpcr
8371 fadd.x SAVEU(%a6),%fp0
8372 bra t_inx2
8373
8374
8375LOGNEG:
8376 bra t_operr
8377
8378 global slognd
8379slognd:
8380
8381
8382 mov.l &-100,ADJK(%a6)
8383
8384
8385
8386
8387
8388
8389 movm.l &0x3f00,-(%sp)
8390 mov.l (%a0),%d3
8391 mov.l 4(%a0),%d4
8392 mov.l 8(%a0),%d5
8393 clr.l %d2
8394
8395 tst.l %d4
8396 bne.b Hi_not0
8397
8398Hi_0:
8399 mov.l %d5,%d4
8400 clr.l %d5
8401 mov.l &32,%d2
8402 clr.l %d6
8403 bfffo %d4{&0:&32},%d6
8404 lsl.l %d6,%d4
8405 add.l %d6,%d2
8406
8407 mov.l %d3,X(%a6)
8408 mov.l %d4,XFRAC(%a6)
8409 mov.l %d5,XFRAC+4(%a6)
8410 neg.l %d2
8411 mov.l %d2,ADJK(%a6)
8412 fmov.x X(%a6),%fp0
8413 movm.l (%sp)+,&0xfc
8414 lea X(%a6),%a0
8415 bra.w LOGBGN
8416
8417Hi_not0:
8418 clr.l %d6
8419 bfffo %d4{&0:&32},%d6
8420 mov.l %d6,%d2
8421 lsl.l %d6,%d4
8422 mov.l %d5,%d7
8423 lsl.l %d6,%d5
8424 neg.l %d6
8425 add.l &32,%d6
8426 lsr.l %d6,%d7
8427 or.l %d7,%d4
8428
8429 mov.l %d3,X(%a6)
8430 mov.l %d4,XFRAC(%a6)
8431 mov.l %d5,XFRAC+4(%a6)
8432 neg.l %d2
8433 mov.l %d2,ADJK(%a6)
8434 fmov.x X(%a6),%fp0
8435 movm.l (%sp)+,&0xfc
8436 lea X(%a6),%a0
8437 bra.w LOGBGN
8438
8439 global slognp1
8440
8441slognp1:
8442 fmov.x (%a0),%fp0
8443 fabs.x %fp0
8444 fcmp.x %fp0,LTHOLD(%pc)
8445 fbgt.w LP1REAL
8446 fmov.l %d0,%fpcr
8447 mov.b &FMOV_OP,%d1
8448 fmov.x (%a0),%fp0
8449 bra t_catch
8450
8451LP1REAL:
8452 fmov.x (%a0),%fp0
8453 mov.l &0x00000000,ADJK(%a6)
8454 fmov.x %fp0,%fp1
8455 fadd.s one(%pc),%fp0
8456 fmov.x %fp0,X(%a6)
8457 mov.w XFRAC(%a6),XDCARE(%a6)
8458 mov.l X(%a6),%d1
8459 cmp.l %d1,&0
8460 ble.w LP1NEG0
8461 cmp.l %d1,&0x3ffe8000
8462 blt.w LOGMAIN
8463 cmp.l %d1,&0x3fffc000
8464 bgt.w LOGMAIN
8465
8466
8467
8468
8469LP1NEAR1:
8470
8471 cmp.l %d1,&0x3ffef07d
8472 blt.w LP1CARE
8473 cmp.l %d1,&0x3fff8841
8474 bgt.w LP1CARE
8475
8476LP1ONE16:
8477
8478
8479 fadd.x %fp1,%fp1
8480 fadd.s one(%pc),%fp0
8481
8482 bra.w LP1CONT2
8483
8484LP1CARE:
8485
8486
8487
8488
8489
8490
8491
8492
8493
8494 mov.l XFRAC(%a6),FFRAC(%a6)
8495 and.l &0xFE000000,FFRAC(%a6)
8496 or.l &0x01000000,FFRAC(%a6)
8497 cmp.l %d1,&0x3FFF8000
8498 bge.b KISZERO
8499
8500KISNEG1:
8501 fmov.s TWO(%pc),%fp0
8502 mov.l &0x3fff0000,F(%a6)
8503 clr.l F+8(%a6)
8504 fsub.x F(%a6),%fp0
8505 mov.l FFRAC(%a6),%d1
8506 and.l &0x7E000000,%d1
8507 asr.l &8,%d1
8508 asr.l &8,%d1
8509 asr.l &4,%d1
8510 fadd.x %fp1,%fp1
8511 fmovm.x &0xc,-(%sp)
8512 fadd.x %fp1,%fp0
8513 lea LOGTBL(%pc),%a0
8514 add.l %d1,%a0
8515 fmov.s negone(%pc),%fp1
8516 bra.w LP1CONT1
8517
8518KISZERO:
8519 fmov.s one(%pc),%fp0
8520 mov.l &0x3fff0000,F(%a6)
8521 clr.l F+8(%a6)
8522 fsub.x F(%a6),%fp0
8523 mov.l FFRAC(%a6),%d1
8524 and.l &0x7E000000,%d1
8525 asr.l &8,%d1
8526 asr.l &8,%d1
8527 asr.l &4,%d1
8528 fadd.x %fp1,%fp0
8529 fmovm.x &0xc,-(%sp)
8530 lea LOGTBL(%pc),%a0
8531 add.l %d1,%a0
8532 fmov.s zero(%pc),%fp1
8533 bra.w LP1CONT1
8534
8535LP1NEG0:
8536
8537 cmp.l %d1,&0
8538 blt.b LP1NEG
8539LP1ZERO:
8540 fmov.s negone(%pc),%fp0
8541
8542 fmov.l %d0,%fpcr
8543 bra t_dz
8544
8545LP1NEG:
8546 fmov.s zero(%pc),%fp0
8547
8548 fmov.l %d0,%fpcr
8549 bra t_operr
8550
8551 global slognp1d
8552
8553
8554slognp1d:
8555 bra t_extdnrm
8556
8557
8558
8559
8560
8561
8562
8563
8564
8565
8566
8567
8568
8569
8570
8571
8572
8573
8574
8575
8576
8577
8578
8579
8580
8581
8582
8583
8584
8585
8586
8587
8588
8589
8590
8591
8592
8593
8594
8595
8596
8597
8598
8599 global satanh
8600satanh:
8601 mov.l (%a0),%d1
8602 mov.w 4(%a0),%d1
8603 and.l &0x7FFFFFFF,%d1
8604 cmp.l %d1,&0x3FFF8000
8605 bge.b ATANHBIG
8606
8607
8608
8609
8610 fabs.x (%a0),%fp0
8611 fmov.x %fp0,%fp1
8612 fneg.x %fp1
8613 fadd.x %fp0,%fp0
8614 fadd.s &0x3F800000,%fp1
8615 fdiv.x %fp1,%fp0
8616 mov.l (%a0),%d1
8617 and.l &0x80000000,%d1
8618 or.l &0x3F000000,%d1
8619 mov.l %d1,-(%sp)
8620
8621 mov.l %d0,-(%sp)
8622 clr.l %d0
8623 fmovm.x &0x01,-(%sp)
8624 lea (%sp),%a0
8625 bsr slognp1
8626 add.l &0xc,%sp
8627
8628 mov.l (%sp)+,%d0
8629 fmov.l %d0,%fpcr
8630 mov.b &FMUL_OP,%d1
8631 fmul.s (%sp)+,%fp0
8632 bra t_catch
8633
8634ATANHBIG:
8635 fabs.x (%a0),%fp0
8636 fcmp.s %fp0,&0x3F800000
8637 fbgt t_operr
8638 bra t_dz
8639
8640 global satanhd
8641
8642satanhd:
8643 bra t_extdnrm
8644
8645
8646
8647
8648
8649
8650
8651
8652
8653
8654
8655
8656
8657
8658
8659
8660
8661
8662
8663
8664
8665
8666
8667
8668
8669
8670
8671
8672
8673
8674
8675
8676
8677
8678
8679
8680
8681
8682
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695
8696
8697
8698
8699
8700
8701
8702
8703
8704
8705
8706
8707
8708
8709
8710
8711
8712
8713
8714
8715
8716
8717
8718
8719
8720
8721
8722
8723
8724
8725
8726
8727
8728
8729
8730INV_L10:
8731 long 0x3FFD0000,0xDE5BD8A9,0x37287195,0x00000000
8732
8733INV_L2:
8734 long 0x3FFF0000,0xB8AA3B29,0x5C17F0BC,0x00000000
8735
8736 global slog10
8737
8738slog10:
8739 fmov.b &0x1,%fp0
8740 fcmp.x %fp0,(%a0)
8741 fbeq.l ld_pzero
8742
8743 mov.l (%a0),%d1
8744 blt.w invalid
8745 mov.l %d0,-(%sp)
8746 clr.l %d0
8747 bsr slogn
8748 fmov.l (%sp)+,%fpcr
8749 fmul.x INV_L10(%pc),%fp0
8750 bra t_inx2
8751
8752 global slog10d
8753
8754slog10d:
8755 mov.l (%a0),%d1
8756 blt.w invalid
8757 mov.l %d0,-(%sp)
8758 clr.l %d0
8759 bsr slognd
8760 fmov.l (%sp)+,%fpcr
8761 fmul.x INV_L10(%pc),%fp0
8762 bra t_minx2
8763
8764 global slog2
8765
8766slog2:
8767 mov.l (%a0),%d1
8768 blt.w invalid
8769
8770 mov.l 8(%a0),%d1
8771 bne.b continue
8772
8773 mov.l 4(%a0),%d1
8774 and.l &0x7FFFFFFF,%d1
8775 bne.b continue
8776
8777
8778 mov.w (%a0),%d1
8779 and.l &0x00007FFF,%d1
8780 sub.l &0x3FFF,%d1
8781 beq.l ld_pzero
8782 fmov.l %d0,%fpcr
8783 fmov.l %d1,%fp0
8784 bra t_inx2
8785
8786continue:
8787 mov.l %d0,-(%sp)
8788 clr.l %d0
8789 bsr slogn
8790 fmov.l (%sp)+,%fpcr
8791 fmul.x INV_L2(%pc),%fp0
8792 bra t_inx2
8793
8794invalid:
8795 bra t_operr
8796
8797 global slog2d
8798
8799slog2d:
8800 mov.l (%a0),%d1
8801 blt.w invalid
8802 mov.l %d0,-(%sp)
8803 clr.l %d0
8804 bsr slognd
8805 fmov.l (%sp)+,%fpcr
8806 fmul.x INV_L2(%pc),%fp0
8807 bra t_minx2
8808
8809
8810
8811
8812
8813
8814
8815
8816
8817
8818
8819
8820
8821
8822
8823
8824
8825
8826
8827
8828
8829
8830
8831
8832
8833
8834
8835
8836
8837
8838
8839
8840
8841
8842
8843
8844
8845
8846
8847
8848
8849
8850
8851
8852
8853
8854
8855
8856
8857
8858
8859
8860
8861
8862
8863
8864
8865
8866
8867
8868
8869
8870
8871
8872
8873
8874
8875
8876
8877
8878
8879
8880
8881
8882
8883L2TEN64:
8884 long 0x406A934F,0x0979A371
8885L10TWO1:
8886 long 0x3F734413,0x509F8000
8887
8888L10TWO2:
8889 long 0xBFCD0000,0xC0219DC1,0xDA994FD2,0x00000000
8890
8891LOG10: long 0x40000000,0x935D8DDD,0xAAA8AC17,0x00000000
8892
8893LOG2: long 0x3FFE0000,0xB17217F7,0xD1CF79AC,0x00000000
8894
8895EXPA5: long 0x3F56C16D,0x6F7BD0B2
8896EXPA4: long 0x3F811112,0x302C712C
8897EXPA3: long 0x3FA55555,0x55554CC1
8898EXPA2: long 0x3FC55555,0x55554A54
8899EXPA1: long 0x3FE00000,0x00000000,0x00000000,0x00000000
8900
8901TEXPTBL:
8902 long 0x3FFF0000,0x80000000,0x00000000,0x3F738000
8903 long 0x3FFF0000,0x8164D1F3,0xBC030773,0x3FBEF7CA
8904 long 0x3FFF0000,0x82CD8698,0xAC2BA1D7,0x3FBDF8A9
8905 long 0x3FFF0000,0x843A28C3,0xACDE4046,0x3FBCD7C9
8906 long 0x3FFF0000,0x85AAC367,0xCC487B15,0xBFBDE8DA
8907 long 0x3FFF0000,0x871F6196,0x9E8D1010,0x3FBDE85C
8908 long 0x3FFF0000,0x88980E80,0x92DA8527,0x3FBEBBF1
8909 long 0x3FFF0000,0x8A14D575,0x496EFD9A,0x3FBB80CA
8910 long 0x3FFF0000,0x8B95C1E3,0xEA8BD6E7,0xBFBA8373
8911 long 0x3FFF0000,0x8D1ADF5B,0x7E5BA9E6,0xBFBE9670
8912 long 0x3FFF0000,0x8EA4398B,0x45CD53C0,0x3FBDB700
8913 long 0x3FFF0000,0x9031DC43,0x1466B1DC,0x3FBEEEB0
8914 long 0x3FFF0000,0x91C3D373,0xAB11C336,0x3FBBFD6D
8915 long 0x3FFF0000,0x935A2B2F,0x13E6E92C,0xBFBDB319
8916 long 0x3FFF0000,0x94F4EFA8,0xFEF70961,0x3FBDBA2B
8917 long 0x3FFF0000,0x96942D37,0x20185A00,0x3FBE91D5
8918 long 0x3FFF0000,0x9837F051,0x8DB8A96F,0x3FBE8D5A
8919 long 0x3FFF0000,0x99E04593,0x20B7FA65,0xBFBCDE7B
8920 long 0x3FFF0000,0x9B8D39B9,0xD54E5539,0xBFBEBAAF
8921 long 0x3FFF0000,0x9D3ED9A7,0x2CFFB751,0xBFBD86DA
8922 long 0x3FFF0000,0x9EF53260,0x91A111AE,0xBFBEBEDD
8923 long 0x3FFF0000,0xA0B0510F,0xB9714FC2,0x3FBCC96E
8924 long 0x3FFF0000,0xA2704303,0x0C496819,0xBFBEC90B
8925 long 0x3FFF0000,0xA43515AE,0x09E6809E,0x3FBBD1DB
8926 long 0x3FFF0000,0xA5FED6A9,0xB15138EA,0x3FBCE5EB
8927 long 0x3FFF0000,0xA7CD93B4,0xE965356A,0xBFBEC274
8928 long 0x3FFF0000,0xA9A15AB4,0xEA7C0EF8,0x3FBEA83C
8929 long 0x3FFF0000,0xAB7A39B5,0xA93ED337,0x3FBECB00
8930 long 0x3FFF0000,0xAD583EEA,0x42A14AC6,0x3FBE9301
8931 long 0x3FFF0000,0xAF3B78AD,0x690A4375,0xBFBD8367
8932 long 0x3FFF0000,0xB123F581,0xD2AC2590,0xBFBEF05F
8933 long 0x3FFF0000,0xB311C412,0xA9112489,0x3FBDFB3C
8934 long 0x3FFF0000,0xB504F333,0xF9DE6484,0x3FBEB2FB
8935 long 0x3FFF0000,0xB6FD91E3,0x28D17791,0x3FBAE2CB
8936 long 0x3FFF0000,0xB8FBAF47,0x62FB9EE9,0x3FBCDC3C
8937 long 0x3FFF0000,0xBAFF5AB2,0x133E45FB,0x3FBEE9AA
8938 long 0x3FFF0000,0xBD08A39F,0x580C36BF,0xBFBEAEFD
8939 long 0x3FFF0000,0xBF1799B6,0x7A731083,0xBFBCBF51
8940 long 0x3FFF0000,0xC12C4CCA,0x66709456,0x3FBEF88A
8941 long 0x3FFF0000,0xC346CCDA,0x24976407,0x3FBD83B2
8942 long 0x3FFF0000,0xC5672A11,0x5506DADD,0x3FBDF8AB
8943 long 0x3FFF0000,0xC78D74C8,0xABB9B15D,0xBFBDFB17
8944 long 0x3FFF0000,0xC9B9BD86,0x6E2F27A3,0xBFBEFE3C
8945 long 0x3FFF0000,0xCBEC14FE,0xF2727C5D,0xBFBBB6F8
8946 long 0x3FFF0000,0xCE248C15,0x1F8480E4,0xBFBCEE53
8947 long 0x3FFF0000,0xD06333DA,0xEF2B2595,0xBFBDA4AE
8948 long 0x3FFF0000,0xD2A81D91,0xF12AE45A,0x3FBC9124
8949 long 0x3FFF0000,0xD4F35AAB,0xCFEDFA1F,0x3FBEB243
8950 long 0x3FFF0000,0xD744FCCA,0xD69D6AF4,0x3FBDE69A
8951 long 0x3FFF0000,0xD99D15C2,0x78AFD7B6,0xBFB8BC61
8952 long 0x3FFF0000,0xDBFBB797,0xDAF23755,0x3FBDF610
8953 long 0x3FFF0000,0xDE60F482,0x5E0E9124,0xBFBD8BE1
8954 long 0x3FFF0000,0xE0CCDEEC,0x2A94E111,0x3FBACB12
8955 long 0x3FFF0000,0xE33F8972,0xBE8A5A51,0x3FBB9BFE
8956 long 0x3FFF0000,0xE5B906E7,0x7C8348A8,0x3FBCF2F4
8957 long 0x3FFF0000,0xE8396A50,0x3C4BDC68,0x3FBEF22F
8958 long 0x3FFF0000,0xEAC0C6E7,0xDD24392F,0xBFBDBF4A
8959 long 0x3FFF0000,0xED4F301E,0xD9942B84,0x3FBEC01A
8960 long 0x3FFF0000,0xEFE4B99B,0xDCDAF5CB,0x3FBE8CAC
8961 long 0x3FFF0000,0xF281773C,0x59FFB13A,0xBFBCBB3F
8962 long 0x3FFF0000,0xF5257D15,0x2486CC2C,0x3FBEF73A
8963 long 0x3FFF0000,0xF7D0DF73,0x0AD13BB9,0xBFB8B795
8964 long 0x3FFF0000,0xFA83B2DB,0x722A033A,0x3FBEF84B
8965 long 0x3FFF0000,0xFD3E0C0C,0xF486C175,0xBFBEF581
8966
8967 set INT,L_SCR1
8968
8969 set X,FP_SCR0
8970 set XDCARE,X+2
8971 set XFRAC,X+4
8972
8973 set ADJFACT,FP_SCR0
8974
8975 set FACT1,FP_SCR0
8976 set FACT1HI,FACT1+4
8977 set FACT1LOW,FACT1+8
8978
8979 set FACT2,FP_SCR1
8980 set FACT2HI,FACT2+4
8981 set FACT2LOW,FACT2+8
8982
8983 global stwotox
8984
8985stwotox:
8986 fmovm.x (%a0),&0x80
8987
8988 mov.l (%a0),%d1
8989 mov.w 4(%a0),%d1
8990 fmov.x %fp0,X(%a6)
8991 and.l &0x7FFFFFFF,%d1
8992
8993 cmp.l %d1,&0x3FB98000
8994 bge.b TWOOK1
8995 bra.w EXPBORS
8996
8997TWOOK1:
8998 cmp.l %d1,&0x400D80C0
8999 ble.b TWOMAIN
9000 bra.w EXPBORS
9001
9002TWOMAIN:
9003
9004
9005 fmov.x %fp0,%fp1
9006 fmul.s &0x42800000,%fp1
9007 fmov.l %fp1,INT(%a6)
9008 mov.l %d2,-(%sp)
9009 lea TEXPTBL(%pc),%a1
9010 fmov.l INT(%a6),%fp1
9011 mov.l INT(%a6),%d1
9012 mov.l %d1,%d2
9013 and.l &0x3F,%d1
9014 asl.l &4,%d1
9015 add.l %d1,%a1
9016 asr.l &6,%d2
9017 mov.l %d2,%d1
9018 asr.l &1,%d1
9019 sub.l %d1,%d2
9020 add.l &0x3FFF,%d2
9021
9022
9023
9024
9025
9026
9027 fmovm.x &0x0c,-(%sp)
9028
9029 fmul.s &0x3C800000,%fp1
9030 mov.l (%a1)+,FACT1(%a6)
9031 mov.l (%a1)+,FACT1HI(%a6)
9032 mov.l (%a1)+,FACT1LOW(%a6)
9033 mov.w (%a1)+,FACT2(%a6)
9034
9035 fsub.x %fp1,%fp0
9036
9037 mov.w (%a1)+,FACT2HI(%a6)
9038 clr.w FACT2HI+2(%a6)
9039 clr.l FACT2LOW(%a6)
9040 add.w %d1,FACT1(%a6)
9041 fmul.x LOG2(%pc),%fp0
9042 add.w %d1,FACT2(%a6)
9043
9044 bra.w expr
9045
9046EXPBORS:
9047
9048 cmp.l %d1,&0x3FFF8000
9049 bgt.b TEXPBIG
9050
9051
9052
9053 fmov.l %d0,%fpcr
9054 fadd.s &0x3F800000,%fp0
9055 bra t_pinx2
9056
9057TEXPBIG:
9058
9059
9060 mov.l X(%a6),%d1
9061 cmp.l %d1,&0
9062 blt.b EXPNEG
9063
9064 bra t_ovfl2
9065
9066EXPNEG:
9067 bra t_unfl2
9068
9069 global stwotoxd
9070stwotoxd:
9071
9072
9073 fmov.l %d0,%fpcr
9074 fmov.s &0x3F800000,%fp0
9075 mov.l (%a0),%d1
9076 or.l &0x00800001,%d1
9077 fadd.s %d1,%fp0
9078 bra t_pinx2
9079
9080 global stentox
9081
9082stentox:
9083 fmovm.x (%a0),&0x80
9084
9085 mov.l (%a0),%d1
9086 mov.w 4(%a0),%d1
9087 fmov.x %fp0,X(%a6)
9088 and.l &0x7FFFFFFF,%d1
9089
9090 cmp.l %d1,&0x3FB98000
9091 bge.b TENOK1
9092 bra.w EXPBORS
9093
9094TENOK1:
9095 cmp.l %d1,&0x400B9B07
9096 ble.b TENMAIN
9097 bra.w EXPBORS
9098
9099TENMAIN:
9100
9101
9102 fmov.x %fp0,%fp1
9103 fmul.d L2TEN64(%pc),%fp1
9104 fmov.l %fp1,INT(%a6)
9105 mov.l %d2,-(%sp)
9106 lea TEXPTBL(%pc),%a1
9107 fmov.l INT(%a6),%fp1
9108 mov.l INT(%a6),%d1
9109 mov.l %d1,%d2
9110 and.l &0x3F,%d1
9111 asl.l &4,%d1
9112 add.l %d1,%a1
9113 asr.l &6,%d2
9114 mov.l %d2,%d1
9115 asr.l &1,%d1
9116 sub.l %d1,%d2
9117 add.l &0x3FFF,%d2
9118
9119
9120
9121
9122
9123 fmovm.x &0x0c,-(%sp)
9124
9125 fmov.x %fp1,%fp2
9126
9127 fmul.d L10TWO1(%pc),%fp1
9128 mov.l (%a1)+,FACT1(%a6)
9129
9130 fmul.x L10TWO2(%pc),%fp2
9131
9132 mov.l (%a1)+,FACT1HI(%a6)
9133 mov.l (%a1)+,FACT1LOW(%a6)
9134 fsub.x %fp1,%fp0
9135 mov.w (%a1)+,FACT2(%a6)
9136
9137 fsub.x %fp2,%fp0
9138
9139 mov.w (%a1)+,FACT2HI(%a6)
9140 clr.w FACT2HI+2(%a6)
9141 clr.l FACT2LOW(%a6)
9142
9143 fmul.x LOG10(%pc),%fp0
9144 add.w %d1,FACT1(%a6)
9145 add.w %d1,FACT2(%a6)
9146
9147expr:
9148
9149
9150
9151
9152
9153 fmov.x %fp0,%fp1
9154 fmul.x %fp1,%fp1
9155
9156 fmov.d EXPA5(%pc),%fp2
9157 fmov.d EXPA4(%pc),%fp3
9158
9159 fmul.x %fp1,%fp2
9160 fmul.x %fp1,%fp3
9161
9162 fadd.d EXPA3(%pc),%fp2
9163 fadd.d EXPA2(%pc),%fp3
9164
9165 fmul.x %fp1,%fp2
9166 fmul.x %fp1,%fp3
9167
9168 fadd.d EXPA1(%pc),%fp2
9169 fmul.x %fp0,%fp3
9170
9171 fmul.x %fp1,%fp2
9172 fadd.x %fp3,%fp0
9173 fadd.x %fp2,%fp0
9174
9175 fmovm.x (%sp)+,&0x30
9176
9177
9178
9179
9180 fmul.x FACT1(%a6),%fp0
9181 fadd.x FACT2(%a6),%fp0
9182 fadd.x FACT1(%a6),%fp0
9183
9184 fmov.l %d0,%fpcr
9185 mov.w %d2,ADJFACT(%a6)
9186 mov.l (%sp)+,%d2
9187 mov.l &0x80000000,ADJFACT+4(%a6)
9188 clr.l ADJFACT+8(%a6)
9189 mov.b &FMUL_OP,%d1
9190 fmul.x ADJFACT(%a6),%fp0
9191 bra t_catch
9192
9193 global stentoxd
9194stentoxd:
9195
9196
9197 fmov.l %d0,%fpcr
9198 fmov.s &0x3F800000,%fp0
9199 mov.l (%a0),%d1
9200 or.l &0x00800001,%d1
9201 fadd.s %d1,%fp0
9202 bra t_pinx2
9203
9204
9205
9206
9207
9208
9209
9210
9211
9212
9213
9214
9215
9216
9217
9218set SIGN, L_SCR1
9219
9220 global sscale
9221sscale:
9222 mov.l %d0,-(%sp)
9223
9224 mov.w DST_EX(%a1),%d1
9225 smi.b SIGN(%a6)
9226 andi.l &0x00007fff,%d1
9227
9228 mov.w SRC_EX(%a0),%d0
9229 andi.w &0x7fff,%d0
9230 cmpi.w %d0,&0x3fff
9231 blt.w src_small
9232 cmpi.w %d0,&0x400c
9233 bgt.w src_out
9234
9235
9236
9237
9238src_ok:
9239 fintrz.x SRC(%a0),%fp0
9240 fmov.l %fp0,%d0
9241
9242
9243 fmov.l &0x0,%fpsr
9244
9245 tst.b DST_HI(%a1)
9246 bmi.b sok_norm
9247
9248
9249
9250sok_dnrm:
9251 mov.l %d0,-(%sp)
9252
9253 mov.w DST_EX(%a1),FP_SCR0_EX(%a6)
9254 mov.l DST_HI(%a1),FP_SCR0_HI(%a6)
9255 mov.l DST_LO(%a1),FP_SCR0_LO(%a6)
9256
9257 lea FP_SCR0(%a6),%a0
9258 bsr.l norm
9259 neg.l %d0
9260 add.l (%sp)+,%d0
9261
9262 fmovm.x FP_SCR0(%a6),&0x80
9263
9264 cmpi.w %d0,&-0x3fff
9265 bge.b sok_norm2
9266
9267
9268
9269
9270
9271
9272
9273 fmov.l (%sp)+,%fpcr
9274 mov.l &0x80000000,%d1
9275 subi.l &-0x3fff,%d0
9276 neg.l %d0
9277 cmpi.b %d0,&0x20
9278 bge.b sok_dnrm_32
9279 lsr.l %d0,%d1
9280 clr.l -(%sp)
9281 mov.l %d1,-(%sp)
9282 clr.l -(%sp)
9283 bra.b sok_norm_cont
9284sok_dnrm_32:
9285 subi.b &0x20,%d0
9286 lsr.l %d0,%d1
9287 mov.l %d1,-(%sp)
9288 clr.l -(%sp)
9289 clr.l -(%sp)
9290 bra.b sok_norm_cont
9291
9292
9293
9294sok_norm:
9295 fmovm.x DST(%a1),&0x80
9296sok_norm2:
9297 fmov.l (%sp)+,%fpcr
9298
9299 addi.w &0x3fff,%d0
9300 swap %d0
9301 clr.l -(%sp)
9302 mov.l &0x80000000,-(%sp)
9303 mov.l %d0,-(%sp)
9304
9305sok_norm_cont:
9306 fmov.l %fpcr,%d0
9307 mov.b &FMUL_OP,%d1
9308 fmul.x (%sp)+,%fp0
9309 bra t_catch2
9310
9311
9312
9313
9314
9315src_out:
9316 mov.l (%sp)+,%d0
9317 exg %a0,%a1
9318 tst.b SRC_EX(%a1)
9319 bmi t_unfl
9320 bra t_ovfl_sc
9321
9322
9323
9324
9325
9326src_small:
9327 tst.b DST_HI(%a1)
9328 bpl.b ssmall_done
9329
9330 mov.l (%sp)+,%d0
9331 fmov.l %d0,%fpcr
9332 mov.b &FMOV_OP,%d1
9333 fmov.x DST(%a1),%fp0
9334 bra t_catch2
9335ssmall_done:
9336 mov.l (%sp)+,%d0
9337 mov.l %a1,%a0
9338 bra t_resdnrm
9339
9340
9341
9342
9343
9344
9345
9346
9347
9348
9349
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360
9361
9362
9363
9364
9365# else
9366
9367# endif
9368
9369
9370
9371
9372
9373
9374
9375
9376
9377
9378
9379
9380
9381
9382
9383
9384
9385
9386
9387
9388
9389
9390
9391
9392
9393
9394
9395
9396
9397
9398
9399
9400 set Mod_Flag,L_SCR3
9401 set Sc_Flag,L_SCR3+1
9402
9403 set SignY,L_SCR2
9404 set SignX,L_SCR2+2
9405 set SignQ,L_SCR3+2
9406
9407 set Y,FP_SCR0
9408 set Y_Hi,Y+4
9409 set Y_Lo,Y+8
9410
9411 set R,FP_SCR1
9412 set R_Hi,R+4
9413 set R_Lo,R+8
9414
9415Scale:
9416 long 0x00010000,0x80000000,0x00000000,0x00000000
9417
9418 global smod
9419smod:
9420 clr.b FPSR_QBYTE(%a6)
9421 mov.l %d0,-(%sp)
9422 clr.b Mod_Flag(%a6)
9423 bra.b Mod_Rem
9424
9425 global srem
9426srem:
9427 clr.b FPSR_QBYTE(%a6)
9428 mov.l %d0,-(%sp)
9429 mov.b &0x1,Mod_Flag(%a6)
9430
9431Mod_Rem:
9432
9433 movm.l &0x3f00,-(%sp)
9434 mov.w SRC_EX(%a0),%d3
9435 mov.w %d3,SignY(%a6)
9436 and.l &0x00007FFF,%d3
9437
9438
9439 mov.l SRC_HI(%a0),%d4
9440 mov.l SRC_LO(%a0),%d5
9441
9442 tst.l %d3
9443 bne.b Y_Normal
9444
9445 mov.l &0x00003FFE,%d3
9446 tst.l %d4
9447 bne.b HiY_not0
9448
9449HiY_0:
9450 mov.l %d5,%d4
9451 clr.l %d5
9452 sub.l &32,%d3
9453 clr.l %d6
9454 bfffo %d4{&0:&32},%d6
9455 lsl.l %d6,%d4
9456 sub.l %d6,%d3
9457
9458 bra.b Chk_X
9459
9460HiY_not0:
9461 clr.l %d6
9462 bfffo %d4{&0:&32},%d6
9463 sub.l %d6,%d3
9464 lsl.l %d6,%d4
9465 mov.l %d5,%d7
9466 lsl.l %d6,%d5
9467 neg.l %d6
9468 add.l &32,%d6
9469 lsr.l %d6,%d7
9470 or.l %d7,%d4
9471
9472 bra.b Chk_X
9473
9474Y_Normal:
9475 add.l &0x00003FFE,%d3
9476
9477
9478Chk_X:
9479 mov.w DST_EX(%a1),%d0
9480 mov.w %d0,SignX(%a6)
9481 mov.w SignY(%a6),%d1
9482 eor.l %d0,%d1
9483 and.l &0x00008000,%d1
9484 mov.w %d1,SignQ(%a6)
9485 and.l &0x00007FFF,%d0
9486 mov.l DST_HI(%a1),%d1
9487 mov.l DST_LO(%a1),%d2
9488 tst.l %d0
9489 bne.b X_Normal
9490 mov.l &0x00003FFE,%d0
9491 tst.l %d1
9492 bne.b HiX_not0
9493
9494HiX_0:
9495 mov.l %d2,%d1
9496 clr.l %d2
9497 sub.l &32,%d0
9498 clr.l %d6
9499 bfffo %d1{&0:&32},%d6
9500 lsl.l %d6,%d1
9501 sub.l %d6,%d0
9502
9503 bra.b Init
9504
9505HiX_not0:
9506 clr.l %d6
9507 bfffo %d1{&0:&32},%d6
9508 sub.l %d6,%d0
9509 lsl.l %d6,%d1
9510 mov.l %d2,%d7
9511 lsl.l %d6,%d2
9512 neg.l %d6
9513 add.l &32,%d6
9514 lsr.l %d6,%d7
9515 or.l %d7,%d1
9516
9517 bra.b Init
9518
9519X_Normal:
9520 add.l &0x00003FFE,%d0
9521
9522
9523Init:
9524
9525 mov.l %d3,L_SCR1(%a6)
9526 mov.l %d0,-(%sp)
9527 sub.l %d3,%d0
9528
9529 clr.l %d6
9530 clr.l %d3
9531 mov.l &0,%a1
9532
9533
9534 tst.l %d0
9535 bge.b Mod_Loop_pre
9536
9537
9538
9539 mov.l (%sp)+,%d0
9540 bra.w Get_Mod
9541
9542Mod_Loop_pre:
9543 addq.l &0x4,%sp
9544
9545Mod_Loop:
9546 tst.l %d6
9547 bgt.b R_GT_Y
9548
9549
9550 cmp.l %d1,%d4
9551 bne.b R_NE_Y
9552 cmp.l %d2,%d5
9553 bne.b R_NE_Y
9554
9555
9556 bra.w Rem_is_0
9557
9558R_NE_Y:
9559
9560 bcs.b R_LT_Y
9561
9562R_GT_Y:
9563
9564
9565 sub.l %d5,%d2
9566 subx.l %d4,%d1
9567 clr.l %d6
9568 addq.l &1,%d3
9569
9570R_LT_Y:
9571
9572 tst.l %d0
9573 beq.b PostLoop
9574
9575 add.l %d3,%d3
9576 add.l %d2,%d2
9577 roxl.l &1,%d1
9578 scs %d6
9579 addq.l &1,%a1
9580 subq.l &1,%d0
9581
9582
9583 bra.b Mod_Loop
9584
9585PostLoop:
9586
9587
9588
9589 mov.l L_SCR1(%a6),%d0
9590 tst.l %d1
9591 bne.b HiR_not0
9592
9593HiR_0:
9594 mov.l %d2,%d1
9595 clr.l %d2
9596 sub.l &32,%d0
9597 clr.l %d6
9598 bfffo %d1{&0:&32},%d6
9599 lsl.l %d6,%d1
9600 sub.l %d6,%d0
9601
9602 bra.b Get_Mod
9603
9604HiR_not0:
9605 clr.l %d6
9606 bfffo %d1{&0:&32},%d6
9607 bmi.b Get_Mod
9608 sub.l %d6,%d0
9609 lsl.l %d6,%d1
9610 mov.l %d2,%d7
9611 lsl.l %d6,%d2
9612 neg.l %d6
9613 add.l &32,%d6
9614 lsr.l %d6,%d7
9615 or.l %d7,%d1
9616
9617
9618Get_Mod:
9619 cmp.l %d0,&0x000041FE
9620 bge.b No_Scale
9621Do_Scale:
9622 mov.w %d0,R(%a6)
9623 mov.l %d1,R_Hi(%a6)
9624 mov.l %d2,R_Lo(%a6)
9625 mov.l L_SCR1(%a6),%d6
9626 mov.w %d6,Y(%a6)
9627 mov.l %d4,Y_Hi(%a6)
9628 mov.l %d5,Y_Lo(%a6)
9629 fmov.x R(%a6),%fp0
9630 mov.b &1,Sc_Flag(%a6)
9631 bra.b ModOrRem
9632No_Scale:
9633 mov.l %d1,R_Hi(%a6)
9634 mov.l %d2,R_Lo(%a6)
9635 sub.l &0x3FFE,%d0
9636 mov.w %d0,R(%a6)
9637 mov.l L_SCR1(%a6),%d6
9638 sub.l &0x3FFE,%d6
9639 mov.l %d6,L_SCR1(%a6)
9640 fmov.x R(%a6),%fp0
9641 mov.w %d6,Y(%a6)
9642 mov.l %d4,Y_Hi(%a6)
9643 mov.l %d5,Y_Lo(%a6)
9644 clr.b Sc_Flag(%a6)
9645
9646
9647ModOrRem:
9648 tst.b Mod_Flag(%a6)
9649 beq.b Fix_Sign
9650
9651 mov.l L_SCR1(%a6),%d6
9652 subq.l &1,%d6
9653 cmp.l %d0,%d6
9654 blt.b Fix_Sign
9655 bgt.b Last_Sub
9656
9657 cmp.l %d1,%d4
9658 bne.b Not_EQ
9659 cmp.l %d2,%d5
9660 bne.b Not_EQ
9661 bra.w Tie_Case
9662
9663Not_EQ:
9664 bcs.b Fix_Sign
9665
9666Last_Sub:
9667
9668 fsub.x Y(%a6),%fp0
9669 addq.l &1,%d3
9670
9671
9672Fix_Sign:
9673
9674 mov.w SignX(%a6),%d6
9675 bge.b Get_Q
9676 fneg.x %fp0
9677
9678
9679
9680Get_Q:
9681 clr.l %d6
9682 mov.w SignQ(%a6),%d6
9683 mov.l &8,%d7
9684 lsr.l %d7,%d6
9685 and.l &0x0000007F,%d3
9686 or.l %d6,%d3
9687
9688
9689
9690
9691
9692 mov.b %d3,FPSR_QBYTE(%a6)
9693
9694
9695Restore:
9696 movm.l (%sp)+,&0xfc
9697 mov.l (%sp)+,%d0
9698 fmov.l %d0,%fpcr
9699 tst.b Sc_Flag(%a6)
9700 beq.b Finish
9701 mov.b &FMUL_OP,%d1
9702 fmul.x Scale(%pc),%fp0
9703 bra t_catch2
9704
9705
9706
9707
9708
9709
9710
9711Finish:
9712 mov.b &FMOV_OP,%d1
9713 fmov.x %fp0,%fp0
9714 bra t_catch2
9715
9716Rem_is_0:
9717
9718 addq.l &1,%d3
9719 cmp.l %d0,&8
9720 bge.b Q_Big
9721
9722 lsl.l %d0,%d3
9723 bra.b Set_R_0
9724
9725Q_Big:
9726 clr.l %d3
9727
9728Set_R_0:
9729 fmov.s &0x00000000,%fp0
9730 clr.b Sc_Flag(%a6)
9731 bra.w Fix_Sign
9732
9733Tie_Case:
9734
9735 mov.l %d3,%d6
9736 and.l &0x00000001,%d6
9737 tst.l %d6
9738 beq.w Fix_Sign
9739
9740
9741 addq.l &1,%d3
9742 mov.w SignX(%a6),%d6
9743 eor.l &0x00008000,%d6
9744 mov.w %d6,SignX(%a6)
9745 bra.w Fix_Sign
9746
9747
9748
9749
9750
9751
9752
9753
9754
9755
9756
9757
9758
9759
9760
9761
9762
9763
9764
9765
9766
9767
9768
9769
9770
9771 global tag
9772tag:
9773 mov.w FTEMP_EX(%a0), %d0
9774 andi.w &0x7fff, %d0
9775 cmpi.w %d0, &0x7fff
9776 beq.b inf_or_nan_x
9777not_inf_or_nan_x:
9778 btst &0x7,FTEMP_HI(%a0)
9779 beq.b not_norm_x
9780is_norm_x:
9781 mov.b &NORM, %d0
9782 rts
9783not_norm_x:
9784 tst.w %d0
9785 bne.b is_unnorm_x
9786not_unnorm_x:
9787 tst.l FTEMP_HI(%a0)
9788 bne.b is_denorm_x
9789 tst.l FTEMP_LO(%a0)
9790 bne.b is_denorm_x
9791is_zero_x:
9792 mov.b &ZERO, %d0
9793 rts
9794is_denorm_x:
9795 mov.b &DENORM, %d0
9796 rts
9797is_unnorm_x:
9798 bsr.l unnorm_fix
9799 rts
9800is_unnorm_reg_x:
9801 mov.b &UNNORM, %d0
9802 rts
9803inf_or_nan_x:
9804 tst.l FTEMP_LO(%a0)
9805 bne.b is_nan_x
9806 mov.l FTEMP_HI(%a0), %d0
9807 and.l &0x7fffffff, %d0
9808 bne.b is_nan_x
9809is_inf_x:
9810 mov.b &INF, %d0
9811 rts
9812is_nan_x:
9813 mov.b &QNAN, %d0
9814 rts
9815
9816
9817
9818qnan: long 0x7fff0000, 0xffffffff, 0xffffffff
9819
9820
9821
9822
9823
9824
9825
9826
9827
9828
9829
9830
9831
9832
9833
9834
9835
9836
9837
9838
9839
9840
9841
9842
9843
9844
9845
9846 global t_dz
9847t_dz:
9848 tst.b SRC_EX(%a0)
9849 bpl.b dz_pinf
9850
9851 global t_dz2
9852t_dz2:
9853 ori.l &dzinf_mask+neg_mask,USER_FPSR(%a6)
9854
9855 btst &dz_bit,FPCR_ENABLE(%a6)
9856 bne.b dz_minf_ena
9857
9858
9859 fmov.s &0xff800000,%fp0
9860 rts
9861
9862
9863
9864dz_minf_ena:
9865 fmovm.x EXC_FP0(%a6),&0x80
9866 fmov.l USER_FPCR(%a6),%fpcr
9867 fmov.s &0xbf800000,%fp1
9868 fdiv.s &0x00000000,%fp1
9869 rts
9870
9871dz_pinf:
9872 ori.l &dzinf_mask,USER_FPSR(%a6)
9873
9874 btst &dz_bit,FPCR_ENABLE(%a6)
9875 bne.b dz_pinf_ena
9876
9877
9878 fmov.s &0x7f800000,%fp0
9879 rts
9880
9881
9882
9883dz_pinf_ena:
9884 fmovm.x EXC_FP0(%a6),&0x80
9885 fmov.l USER_FPCR(%a6),%fpcr
9886 fmov.s &0x3f800000,%fp1
9887 fdiv.s &0x00000000,%fp1
9888 rts
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905
9906
9907
9908
9909
9910
9911
9912
9913
9914
9915 global t_operr
9916t_operr:
9917 ori.l &opnan_mask,USER_FPSR(%a6)
9918
9919 btst &operr_bit,FPCR_ENABLE(%a6)
9920 bne.b operr_ena
9921
9922
9923 fmovm.x qnan(%pc),&0x80
9924 rts
9925
9926
9927
9928operr_ena:
9929 fmovm.x EXC_FP0(%a6),&0x80
9930 fmov.l USER_FPCR(%a6),%fpcr
9931 fmovm.x &0x04,-(%sp)
9932 fmov.s &0x7f800000,%fp2
9933 fmul.s &0x00000000,%fp2
9934 fmovm.x (%sp)+,&0x20
9935 rts
9936
9937pls_huge:
9938 long 0x7ffe0000,0xffffffff,0xffffffff
9939mns_huge:
9940 long 0xfffe0000,0xffffffff,0xffffffff
9941pls_tiny:
9942 long 0x00000000,0x80000000,0x00000000
9943mns_tiny:
9944 long 0x80000000,0x80000000,0x00000000
9945
9946
9947
9948
9949
9950
9951
9952
9953
9954
9955
9956
9957
9958
9959
9960
9961
9962
9963
9964
9965
9966
9967
9968
9969
9970
9971 global t_unfl
9972t_unfl:
9973 tst.b SRC_EX(%a0)
9974 bpl.b unf_pos
9975
9976 global t_unfl2
9977t_unfl2:
9978 ori.l &unfinx_mask+neg_mask,USER_FPSR(%a6)
9979
9980 fmov.l USER_FPCR(%a6),%fpcr
9981 fmovm.x mns_tiny(%pc),&0x80
9982 fmul.x pls_tiny(%pc),%fp0
9983
9984 fmov.l %fpsr,%d0
9985 rol.l &0x8,%d0
9986 mov.b %d0,FPSR_CC(%a6)
9987 rts
9988unf_pos:
9989 ori.w &unfinx_mask,FPSR_EXCEPT(%a6)
9990
9991 fmov.l USER_FPCR(%a6),%fpcr
9992 fmovm.x pls_tiny(%pc),&0x80
9993 fmul.x %fp0,%fp0
9994
9995 fmov.l %fpsr,%d0
9996 rol.l &0x8,%d0
9997 mov.b %d0,FPSR_CC(%a6)
9998 rts
9999
10000
10001
10002
10003
10004
10005
10006
10007
10008
10009
10010
10011
10012
10013
10014
10015
10016
10017
10018
10019
10020
10021
10022
10023
10024
10025
10026
10027
10028
10029 global t_ovfl_sc
10030t_ovfl_sc:
10031 ori.l &ovfl_inx_mask,USER_FPSR(%a6)
10032
10033 mov.b %d0,%d1
10034 andi.b &0xc0,%d1
10035 beq.w ovfl_work
10036
10037
10038
10039
10040 mov.w LOCAL_EX(%a0),FP_SCR0_EX(%a6)
10041 mov.l LOCAL_HI(%a0),FP_SCR0_HI(%a6)
10042 mov.l LOCAL_LO(%a0),FP_SCR0_LO(%a6)
10043 lea FP_SCR0(%a6),%a0
10044 movm.l &0xc080,-(%sp)
10045 bsr.l norm
10046 movm.l (%sp)+,&0x0103
10047
10048 cmpi.b %d1,&0x40
10049 bne.b ovfl_sc_dbl
10050ovfl_sc_sgl:
10051 tst.l LOCAL_LO(%a0)
10052 bne.b ovfl_sc_inx
10053 tst.b 3+LOCAL_HI(%a0)
10054 bne.b ovfl_sc_inx
10055 bra.w ovfl_work
10056ovfl_sc_dbl:
10057 mov.l LOCAL_LO(%a0),%d1
10058 andi.l &0x7ff,%d1
10059 beq.w ovfl_work
10060ovfl_sc_inx:
10061 ori.l &inex2_mask,USER_FPSR(%a6)
10062 bra.b ovfl_work
10063
10064 global t_ovfl
10065t_ovfl:
10066 ori.w &ovfinx_mask,FPSR_EXCEPT(%a6)
10067ovfl_work:
10068 tst.b SRC_EX(%a0)
10069 bpl.b ovfl_p
10070ovfl_m:
10071 fmov.l USER_FPCR(%a6),%fpcr
10072 fmovm.x mns_huge(%pc),&0x80
10073 fmul.x pls_huge(%pc),%fp0
10074
10075 fmov.l %fpsr,%d0
10076 rol.l &0x8,%d0
10077 ori.b &neg_mask,%d0
10078 mov.b %d0,FPSR_CC(%a6)
10079 rts
10080ovfl_p:
10081 fmov.l USER_FPCR(%a6),%fpcr
10082 fmovm.x pls_huge(%pc),&0x80
10083 fmul.x pls_huge(%pc),%fp0
10084
10085 fmov.l %fpsr,%d0
10086 rol.l &0x8,%d0
10087 mov.b %d0,FPSR_CC(%a6)
10088 rts
10089
10090 global t_ovfl2
10091t_ovfl2:
10092 ori.w &ovfinx_mask,FPSR_EXCEPT(%a6)
10093 fmov.l USER_FPCR(%a6),%fpcr
10094 fmovm.x pls_huge(%pc),&0x80
10095 fmul.x pls_huge(%pc),%fp0
10096
10097 fmov.l %fpsr,%d0
10098 rol.l &0x8,%d0
10099 mov.b %d0,FPSR_CC(%a6)
10100 rts
10101
10102
10103
10104
10105
10106
10107
10108
10109
10110
10111
10112
10113
10114
10115
10116
10117
10118
10119
10120
10121
10122
10123
10124
10125
10126
10127
10128 global t_catch2
10129t_catch2:
10130 fmov.l %fpsr,%d0
10131 or.l %d0,USER_FPSR(%a6)
10132 bra.b inx2_work
10133
10134 global t_catch
10135t_catch:
10136 fmov.l %fpsr,%d0
10137 or.l %d0,USER_FPSR(%a6)
10138
10139
10140
10141
10142
10143
10144
10145
10146
10147
10148
10149
10150
10151
10152
10153
10154
10155
10156
10157
10158
10159
10160
10161
10162
10163
10164 global t_inx2
10165t_inx2:
10166 fblt.w t_minx2
10167 fbeq.w inx2_zero
10168
10169 global t_pinx2
10170t_pinx2:
10171 ori.w &inx2a_mask,FPSR_EXCEPT(%a6)
10172 bra.b inx2_work
10173
10174 global t_minx2
10175t_minx2:
10176 ori.l &inx2a_mask+neg_mask,USER_FPSR(%a6)
10177
10178inx2_work:
10179 btst &inex2_bit,FPCR_ENABLE(%a6)
10180 bne.b inx2_work_ena
10181 rts
10182inx2_work_ena:
10183 fmov.l USER_FPCR(%a6),%fpcr
10184 fmov.s &0x3f800000,%fp1
10185 fadd.x pls_tiny(%pc),%fp1
10186 rts
10187
10188inx2_zero:
10189 mov.b &z_bmask,FPSR_CC(%a6)
10190 ori.w &inx2a_mask,2+USER_FPSR(%a6)
10191 rts
10192
10193
10194
10195
10196
10197
10198
10199
10200
10201
10202
10203
10204
10205
10206
10207
10208
10209
10210
10211
10212
10213
10214
10215
10216
10217 global t_extdnrm
10218t_extdnrm:
10219 fmov.l USER_FPCR(%a6),%fpcr
10220 fmov.x SRC_EX(%a0),%fp0
10221 fmov.l %fpsr,%d0
10222 ori.l &unfinx_mask,%d0
10223 or.l %d0,USER_FPSR(%a6)
10224 rts
10225
10226 global t_resdnrm
10227t_resdnrm:
10228 fmov.l USER_FPCR(%a6),%fpcr
10229 fmov.x SRC_EX(%a0),%fp0
10230 fmov.l %fpsr,%d0
10231 or.l %d0,USER_FPSR(%a6)
10232 rts
10233
10234
10235
10236
10237
10238
10239
10240
10241 global sto_cos
10242sto_cos:
10243 rts
10244
10245
10246
10247
10248
10249
10250 global dst_qnan
10251dst_qnan:
10252 fmov.x DST(%a1),%fp0
10253 tst.b DST_EX(%a1)
10254 bmi.b dst_qnan_m
10255dst_qnan_p:
10256 mov.b &nan_bmask,FPSR_CC(%a6)
10257 rts
10258dst_qnan_m:
10259 mov.b &nan_bmask+neg_bmask,FPSR_CC(%a6)
10260 rts
10261
10262
10263
10264
10265 global src_qnan
10266src_qnan:
10267 fmov.x SRC(%a0),%fp0
10268 tst.b SRC_EX(%a0)
10269 bmi.b src_qnan_m
10270src_qnan_p:
10271 mov.b &nan_bmask,FPSR_CC(%a6)
10272 rts
10273src_qnan_m:
10274 mov.b &nan_bmask+neg_bmask,FPSR_CC(%a6)
10275 rts
10276
10277
10278
10279
10280
10281
10282
10283
10284
10285
10286 global _fadds_
10287_fadds_:
10288 fmov.l %fpcr,-(%sp)
10289 fmov.l &0x00000000,%fpcr
10290 fmov.s 0x8(%sp),%fp0
10291 fmov.l (%sp)+,%fpcr
10292 fadd.s 0x8(%sp),%fp0
10293 rts
10294
10295 global _faddd_
10296_faddd_:
10297 fmov.l %fpcr,-(%sp)
10298 fmov.l &0x00000000,%fpcr
10299 fmov.d 0x8(%sp),%fp0
10300 fmov.l (%sp)+,%fpcr
10301 fadd.d 0xc(%sp),%fp0
10302 rts
10303
10304 global _faddx_
10305_faddx_:
10306 fmovm.x 0x4(%sp),&0x80
10307 fadd.x 0x10(%sp),%fp0
10308 rts
10309
10310 global _fsubs_
10311_fsubs_:
10312 fmov.l %fpcr,-(%sp)
10313 fmov.l &0x00000000,%fpcr
10314 fmov.s 0x8(%sp),%fp0
10315 fmov.l (%sp)+,%fpcr
10316 fsub.s 0x8(%sp),%fp0
10317 rts
10318
10319 global _fsubd_
10320_fsubd_:
10321 fmov.l %fpcr,-(%sp)
10322 fmov.l &0x00000000,%fpcr
10323 fmov.d 0x8(%sp),%fp0
10324 fmov.l (%sp)+,%fpcr
10325 fsub.d 0xc(%sp),%fp0
10326 rts
10327
10328 global _fsubx_
10329_fsubx_:
10330 fmovm.x 0x4(%sp),&0x80
10331 fsub.x 0x10(%sp),%fp0
10332 rts
10333
10334 global _fmuls_
10335_fmuls_:
10336 fmov.l %fpcr,-(%sp)
10337 fmov.l &0x00000000,%fpcr
10338 fmov.s 0x8(%sp),%fp0
10339 fmov.l (%sp)+,%fpcr
10340 fmul.s 0x8(%sp),%fp0
10341 rts
10342
10343 global _fmuld_
10344_fmuld_:
10345 fmov.l %fpcr,-(%sp)
10346 fmov.l &0x00000000,%fpcr
10347 fmov.d 0x8(%sp),%fp0
10348 fmov.l (%sp)+,%fpcr
10349 fmul.d 0xc(%sp),%fp0
10350 rts
10351
10352 global _fmulx_
10353_fmulx_:
10354 fmovm.x 0x4(%sp),&0x80
10355 fmul.x 0x10(%sp),%fp0
10356 rts
10357
10358 global _fdivs_
10359_fdivs_:
10360 fmov.l %fpcr,-(%sp)
10361 fmov.l &0x00000000,%fpcr
10362 fmov.s 0x8(%sp),%fp0
10363 fmov.l (%sp)+,%fpcr
10364 fdiv.s 0x8(%sp),%fp0
10365 rts
10366
10367 global _fdivd_
10368_fdivd_:
10369 fmov.l %fpcr,-(%sp)
10370 fmov.l &0x00000000,%fpcr
10371 fmov.d 0x8(%sp),%fp0
10372 fmov.l (%sp)+,%fpcr
10373 fdiv.d 0xc(%sp),%fp0
10374 rts
10375
10376 global _fdivx_
10377_fdivx_:
10378 fmovm.x 0x4(%sp),&0x80
10379 fdiv.x 0x10(%sp),%fp0
10380 rts
10381
10382 global _fabss_
10383_fabss_:
10384 fabs.s 0x4(%sp),%fp0
10385 rts
10386
10387 global _fabsd_
10388_fabsd_:
10389 fabs.d 0x4(%sp),%fp0
10390 rts
10391
10392 global _fabsx_
10393_fabsx_:
10394 fabs.x 0x4(%sp),%fp0
10395 rts
10396
10397 global _fnegs_
10398_fnegs_:
10399 fneg.s 0x4(%sp),%fp0
10400 rts
10401
10402 global _fnegd_
10403_fnegd_:
10404 fneg.d 0x4(%sp),%fp0
10405 rts
10406
10407 global _fnegx_
10408_fnegx_:
10409 fneg.x 0x4(%sp),%fp0
10410 rts
10411
10412 global _fsqrts_
10413_fsqrts_:
10414 fsqrt.s 0x4(%sp),%fp0
10415 rts
10416
10417 global _fsqrtd_
10418_fsqrtd_:
10419 fsqrt.d 0x4(%sp),%fp0
10420 rts
10421
10422 global _fsqrtx_
10423_fsqrtx_:
10424 fsqrt.x 0x4(%sp),%fp0
10425 rts
10426
10427 global _fints_
10428_fints_:
10429 fint.s 0x4(%sp),%fp0
10430 rts
10431
10432 global _fintd_
10433_fintd_:
10434 fint.d 0x4(%sp),%fp0
10435 rts
10436
10437 global _fintx_
10438_fintx_:
10439 fint.x 0x4(%sp),%fp0
10440 rts
10441
10442 global _fintrzs_
10443_fintrzs_:
10444 fintrz.s 0x4(%sp),%fp0
10445 rts
10446
10447 global _fintrzd_
10448_fintrzd_:
10449 fintrz.d 0x4(%sp),%fp0
10450 rts
10451
10452 global _fintrzx_
10453_fintrzx_:
10454 fintrz.x 0x4(%sp),%fp0
10455 rts
10456
10457
10458
10459
10460
10461
10462 global src_zero
10463src_zero:
10464 tst.b SRC_EX(%a0)
10465 bmi.b ld_mzero
10466
10467
10468
10469
10470 global ld_pzero
10471ld_pzero:
10472 fmov.s &0x00000000,%fp0
10473 mov.b &z_bmask,FPSR_CC(%a6)
10474 rts
10475
10476
10477 global ld_mzero
10478ld_mzero:
10479 fmov.s &0x80000000,%fp0
10480 mov.b &neg_bmask+z_bmask,FPSR_CC(%a6)
10481 rts
10482
10483
10484
10485
10486 global dst_zero
10487dst_zero:
10488 tst.b DST_EX(%a1)
10489 bmi.b ld_mzero
10490 bra.b ld_pzero
10491
10492
10493
10494
10495 global src_inf
10496src_inf:
10497 tst.b SRC_EX(%a0)
10498 bmi.b ld_minf
10499
10500
10501
10502
10503 global ld_pinf
10504ld_pinf:
10505 fmov.s &0x7f800000,%fp0
10506 mov.b &inf_bmask,FPSR_CC(%a6)
10507 rts
10508
10509
10510
10511
10512 global ld_minf
10513ld_minf:
10514 fmov.s &0xff800000,%fp0
10515 mov.b &neg_bmask+inf_bmask,FPSR_CC(%a6)
10516 rts
10517
10518
10519
10520
10521 global dst_inf
10522dst_inf:
10523 tst.b DST_EX(%a1)
10524 bmi.b ld_minf
10525 bra.b ld_pinf
10526
10527 global szr_inf
10528
10529
10530
10531
10532
10533szr_inf:
10534 tst.b SRC_EX(%a0)
10535 bmi.b ld_pzero
10536 bra.b ld_pinf
10537
10538
10539
10540
10541
10542
10543 global sopr_inf
10544sopr_inf:
10545 tst.b SRC_EX(%a0)
10546 bmi.w t_operr
10547 bra.b ld_pinf
10548
10549
10550
10551
10552
10553
10554 global setoxm1i
10555setoxm1i:
10556 tst.b SRC_EX(%a0)
10557 bmi.b ld_mone
10558 bra.b ld_pinf
10559
10560
10561
10562
10563 global src_one
10564src_one:
10565 tst.b SRC_EX(%a0)
10566 bmi.b ld_mone
10567
10568
10569
10570
10571 global ld_pone
10572ld_pone:
10573 fmov.s &0x3f800000,%fp0
10574 clr.b FPSR_CC(%a6)
10575 rts
10576
10577
10578
10579
10580 global ld_mone
10581ld_mone:
10582 fmov.s &0xbf800000,%fp0
10583 mov.b &neg_bmask,FPSR_CC(%a6)
10584 rts
10585
10586ppiby2: long 0x3fff0000, 0xc90fdaa2, 0x2168c235
10587mpiby2: long 0xbfff0000, 0xc90fdaa2, 0x2168c235
10588
10589
10590
10591
10592 global spi_2
10593spi_2:
10594 tst.b SRC_EX(%a0)
10595 bmi.b ld_mpi2
10596
10597
10598
10599
10600 global ld_ppi2
10601ld_ppi2:
10602 fmov.l %d0,%fpcr
10603 fmov.x ppiby2(%pc),%fp0
10604 bra.w t_pinx2
10605
10606
10607
10608
10609 global ld_mpi2
10610ld_mpi2:
10611 fmov.l %d0,%fpcr
10612 fmov.x mpiby2(%pc),%fp0
10613 bra.w t_minx2
10614
10615
10616
10617
10618
10619
10620
10621
10622
10623
10624 global ssincosz
10625ssincosz:
10626 fmov.s &0x3f800000,%fp1
10627 tst.b SRC_EX(%a0)
10628 bpl.b sincoszp
10629 fmov.s &0x80000000,%fp0
10630 mov.b &z_bmask+neg_bmask,FPSR_CC(%a6)
10631 rts
10632sincoszp:
10633 fmov.s &0x00000000,%fp0
10634 mov.b &z_bmask,FPSR_CC(%a6)
10635 rts
10636
10637
10638
10639
10640
10641
10642 global ssincosi
10643ssincosi:
10644 fmov.x qnan(%pc),%fp1
10645 bra.w t_operr
10646
10647
10648
10649
10650
10651 global ssincosqnan
10652ssincosqnan:
10653 fmov.x LOCAL_EX(%a0),%fp1
10654 bra.w src_qnan
10655
10656
10657
10658 global smod_sdnrm
10659 global smod_snorm
10660smod_sdnrm:
10661smod_snorm:
10662 mov.b DTAG(%a6),%d1
10663 beq.l smod
10664 cmpi.b %d1,&ZERO
10665 beq.w smod_zro
10666 cmpi.b %d1,&INF
10667 beq.l t_operr
10668 cmpi.b %d1,&DENORM
10669 beq.l smod
10670 bra.l dst_qnan
10671
10672 global smod_szero
10673smod_szero:
10674 mov.b DTAG(%a6),%d1
10675 beq.l t_operr
10676 cmpi.b %d1,&ZERO
10677 beq.l t_operr
10678 cmpi.b %d1,&INF
10679 beq.l t_operr
10680 cmpi.b %d1,&DENORM
10681 beq.l t_operr
10682 bra.l dst_qnan
10683
10684 global smod_sinf
10685smod_sinf:
10686 mov.b DTAG(%a6),%d1
10687 beq.l smod_fpn
10688 cmpi.b %d1,&ZERO
10689 beq.l smod_zro
10690 cmpi.b %d1,&INF
10691 beq.l t_operr
10692 cmpi.b %d1,&DENORM
10693 beq.l smod_fpn
10694 bra.l dst_qnan
10695
10696smod_zro:
10697srem_zro:
10698 mov.b SRC_EX(%a0),%d1
10699 mov.b DST_EX(%a1),%d0
10700 eor.b %d0,%d1
10701 andi.b &0x80,%d1
10702 mov.b %d1,FPSR_QBYTE(%a6)
10703 tst.b %d0
10704 bpl.w ld_pzero
10705 bra.w ld_mzero
10706
10707smod_fpn:
10708srem_fpn:
10709 clr.b FPSR_QBYTE(%a6)
10710 mov.l %d0,-(%sp)
10711 mov.b SRC_EX(%a0),%d1
10712 mov.b DST_EX(%a1),%d0
10713 eor.b %d0,%d1
10714 andi.b &0x80,%d1
10715 mov.b %d1,FPSR_QBYTE(%a6)
10716 cmpi.b DTAG(%a6),&DENORM
10717 bne.b smod_nrm
10718 lea DST(%a1),%a0
10719 mov.l (%sp)+,%d0
10720 bra t_resdnrm
10721smod_nrm:
10722 fmov.l (%sp)+,%fpcr
10723 fmov.x DST(%a1),%fp0
10724 tst.b DST_EX(%a1)
10725 bmi.b smod_nrm_neg
10726 rts
10727
10728smod_nrm_neg:
10729 mov.b &neg_bmask,FPSR_CC(%a6)
10730 rts
10731
10732
10733 global srem_snorm
10734 global srem_sdnrm
10735srem_sdnrm:
10736srem_snorm:
10737 mov.b DTAG(%a6),%d1
10738 beq.l srem
10739 cmpi.b %d1,&ZERO
10740 beq.w srem_zro
10741 cmpi.b %d1,&INF
10742 beq.l t_operr
10743 cmpi.b %d1,&DENORM
10744 beq.l srem
10745 bra.l dst_qnan
10746
10747 global srem_szero
10748srem_szero:
10749 mov.b DTAG(%a6),%d1
10750 beq.l t_operr
10751 cmpi.b %d1,&ZERO
10752 beq.l t_operr
10753 cmpi.b %d1,&INF
10754 beq.l t_operr
10755 cmpi.b %d1,&DENORM
10756 beq.l t_operr
10757 bra.l dst_qnan
10758
10759 global srem_sinf
10760srem_sinf:
10761 mov.b DTAG(%a6),%d1
10762 beq.w srem_fpn
10763 cmpi.b %d1,&ZERO
10764 beq.w srem_zro
10765 cmpi.b %d1,&INF
10766 beq.l t_operr
10767 cmpi.b %d1,&DENORM
10768 beq.l srem_fpn
10769 bra.l dst_qnan
10770
10771
10772
10773 global sscale_snorm
10774 global sscale_sdnrm
10775sscale_snorm:
10776sscale_sdnrm:
10777 mov.b DTAG(%a6),%d1
10778 beq.l sscale
10779 cmpi.b %d1,&ZERO
10780 beq.l dst_zero
10781 cmpi.b %d1,&INF
10782 beq.l dst_inf
10783 cmpi.b %d1,&DENORM
10784 beq.l sscale
10785 bra.l dst_qnan
10786
10787 global sscale_szero
10788sscale_szero:
10789 mov.b DTAG(%a6),%d1
10790 beq.l sscale
10791 cmpi.b %d1,&ZERO
10792 beq.l dst_zero
10793 cmpi.b %d1,&INF
10794 beq.l dst_inf
10795 cmpi.b %d1,&DENORM
10796 beq.l sscale
10797 bra.l dst_qnan
10798
10799 global sscale_sinf
10800sscale_sinf:
10801 mov.b DTAG(%a6),%d1
10802 beq.l t_operr
10803 cmpi.b %d1,&QNAN
10804 beq.l dst_qnan
10805 bra.l t_operr
10806
10807
10808
10809 global sop_sqnan
10810sop_sqnan:
10811 mov.b DTAG(%a6),%d1
10812 cmpi.b %d1,&QNAN
10813 beq.l dst_qnan
10814 bra.l src_qnan
10815
10816
10817
10818
10819
10820
10821
10822
10823
10824
10825
10826
10827
10828
10829
10830
10831
10832
10833
10834
10835 global norm
10836norm:
10837 mov.l %d2, -(%sp)
10838 mov.l %d3, -(%sp)
10839
10840 mov.l FTEMP_HI(%a0), %d0
10841 mov.l FTEMP_LO(%a0), %d1
10842
10843 bfffo %d0{&0:&32}, %d2
10844 beq.b norm_lo
10845
10846norm_hi:
10847 lsl.l %d2, %d0
10848 bfextu %d1{&0:%d2}, %d3
10849
10850 or.l %d3, %d0
10851 lsl.l %d2, %d1
10852
10853 mov.l %d0, FTEMP_HI(%a0)
10854 mov.l %d1, FTEMP_LO(%a0)
10855
10856 mov.l %d2, %d0
10857
10858 mov.l (%sp)+, %d3
10859 mov.l (%sp)+, %d2
10860
10861 rts
10862
10863norm_lo:
10864 bfffo %d1{&0:&32}, %d2
10865 lsl.l %d2, %d1
10866 add.l &32, %d2
10867
10868 mov.l %d1, FTEMP_HI(%a0)
10869 clr.l FTEMP_LO(%a0)
10870
10871 mov.l %d2, %d0
10872
10873 mov.l (%sp)+, %d3
10874 mov.l (%sp)+, %d2
10875
10876 rts
10877
10878
10879
10880
10881
10882
10883
10884
10885
10886
10887
10888
10889
10890
10891
10892
10893
10894
10895
10896
10897
10898 global unnorm_fix
10899unnorm_fix:
10900 bfffo FTEMP_HI(%a0){&0:&32}, %d0
10901 bne.b unnorm_shift
10902
10903
10904
10905
10906unnorm_chk_lo:
10907 bfffo FTEMP_LO(%a0){&0:&32}, %d0
10908 beq.w unnorm_zero
10909
10910 add.w &32, %d0
10911
10912
10913
10914
10915unnorm_shift:
10916 clr.l %d1
10917 mov.w FTEMP_EX(%a0), %d1
10918 and.w &0x7fff, %d1
10919
10920 cmp.w %d0, %d1
10921 bgt.b unnorm_nrm_zero
10922
10923
10924
10925
10926 sub.w %d0, %d1
10927 mov.w FTEMP_EX(%a0), %d0
10928 and.w &0x8000, %d0
10929 or.w %d0, %d1
10930 mov.w %d1, FTEMP_EX(%a0)
10931
10932 bsr.l norm
10933
10934 mov.b &NORM, %d0
10935 rts
10936
10937
10938
10939
10940unnorm_nrm_zero:
10941 cmp.b %d1, &32
10942 bgt.b unnorm_nrm_zero_lrg
10943
10944 bfextu FTEMP_HI(%a0){%d1:&32}, %d0
10945 mov.l %d0, FTEMP_HI(%a0)
10946
10947 mov.l FTEMP_LO(%a0), %d0
10948 lsl.l %d1, %d0
10949 mov.l %d0, FTEMP_LO(%a0)
10950
10951 and.w &0x8000, FTEMP_EX(%a0)
10952
10953 mov.b &DENORM, %d0
10954 rts
10955
10956
10957
10958
10959unnorm_nrm_zero_lrg:
10960 sub.w &32, %d1
10961
10962 mov.l FTEMP_LO(%a0), %d0
10963 lsl.l %d1, %d0
10964
10965 mov.l %d0, FTEMP_HI(%a0)
10966 clr.l FTEMP_LO(%a0)
10967
10968 and.w &0x8000, FTEMP_EX(%a0)
10969
10970 mov.b &DENORM, %d0
10971 rts
10972
10973
10974
10975
10976unnorm_zero:
10977 and.w &0x8000, FTEMP_EX(%a0)
10978
10979 mov.b &ZERO, %d0
10980 rts
10981