📄 l_entry.s
字号:
L_1035: bsrl __l_satand | assuming a denorm...L_1036: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fatand__l_fatand: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmoved a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_1037 bsrl __l_satan | normalized (regular) number jra L_103BL_1037: cmpb #0x20,d0 | zero? jne L_1038 bsrl __l_szero jra L_103BL_1038: cmpb #0x40,d0 | infinity? jne L_1039 bsrl __l_spi_2 jra L_103BL_1039: cmpb #0x60,d0 | NaN? jne L_103A bsrl __l_mon_nan jra L_103BL_103A: bsrl __l_satand | assuming a denorm...L_103B: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fatanx__l_fatanx: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmovex a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_103C bsrl __l_satan | normalized (regular) number jra L_103GL_103C: cmpb #0x20,d0 | zero? jne L_103D bsrl __l_szero jra L_103GL_103D: cmpb #0x40,d0 | infinity? jne L_103E bsrl __l_spi_2 jra L_103GL_103E: cmpb #0x60,d0 | NaN? jne L_103F bsrl __l_mon_nan jra L_103GL_103F: bsrl __l_satand | assuming a denorm...L_103G: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts|| MONADIC.GEN 1.3 4/30/91|| MONADIC.GEN --- generic MONADIC template|| This version saves all registers that will be used by the emulation| routines and restores all but FP0 on exit. The FPSR is| updated to reflect the result of the operation. Return value| is placed in FP0 for single, double and extended results.|| The package subroutines expect the incoming fpcr to be zeroed| since they need extended precision to work properly. The/* | 'final' fpcr is expected in d1 so that the calculated result */| can be properly sized and rounded. Also, if the incoming fpcr| has enabled any exceptions, the exception will be taken on the| final fmovem in this template.|| Customizations:| 1. Remove the moveml at the entry and exit of| each routine if your compiler treats those| registers as scratch./* | 2. Likewise, don't save FP0/FP1 if they are scratch */| registers.| 3. Delete handling of the fpsr if you only care about| the result.| 4. Some (most?) C compilers convert all float arguments| to double, and provide no support at all for extended| precision so remove the __l_fatanhs and __l_fatanhx entry points.| 5. Move the result to d0/d1 if the compiler is that old.| Copyright (C) Motorola, Inc. 1991| All Rights Reserved|| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA| The copyright notice above does not evidence any| actual or intended publication of such source code.| xref __l_tag| xref __l_satanh| xref __l_szero| xref __l_t_operr| xref __l_mon_nan| xref __l_satanhd .globl __l_fatanhs__l_fatanhs: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmoves a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_1042 bsrl __l_satanh | normalized (regular) number jra L_1046L_1042: cmpb #0x20,d0 | zero? jne L_1043 bsrl __l_szero jra L_1046L_1043: cmpb #0x40,d0 | infinity? jne L_1044 bsrl __l_t_operr jra L_1046L_1044: cmpb #0x60,d0 | NaN? jne L_1045 bsrl __l_mon_nan jra L_1046L_1045: bsrl __l_satanhd | assuming a denorm...L_1046: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fatanhd__l_fatanhd: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmoved a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_1047 bsrl __l_satanh | normalized (regular) number jra L_104BL_1047: cmpb #0x20,d0 | zero? jne L_1048 bsrl __l_szero jra L_104BL_1048: cmpb #0x40,d0 | infinity? jne L_1049 bsrl __l_t_operr jra L_104BL_1049: cmpb #0x60,d0 | NaN? jne L_104A bsrl __l_mon_nan jra L_104BL_104A: bsrl __l_satanhd | assuming a denorm...L_104B: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fatanhx__l_fatanhx: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmovex a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_104C bsrl __l_satanh | normalized (regular) number jra L_104GL_104C: cmpb #0x20,d0 | zero? jne L_104D bsrl __l_szero jra L_104GL_104D: cmpb #0x40,d0 | infinity? jne L_104E bsrl __l_t_operr jra L_104GL_104E: cmpb #0x60,d0 | NaN? jne L_104F bsrl __l_mon_nan jra L_104GL_104F: bsrl __l_satanhd | assuming a denorm...L_104G: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts|| MONADIC.GEN 1.3 4/30/91|| MONADIC.GEN --- generic MONADIC template|| This version saves all registers that will be used by the emulation| routines and restores all but FP0 on exit. The FPSR is| updated to reflect the result of the operation. Return value| is placed in FP0 for single, double and extended results.|| The package subroutines expect the incoming fpcr to be zeroed| since they need extended precision to work properly. The/* | 'final' fpcr is expected in d1 so that the calculated result */| can be properly sized and rounded. Also, if the incoming fpcr| has enabled any exceptions, the exception will be taken on the| final fmovem in this template.|| Customizations:| 1. Remove the moveml at the entry and exit of| each routine if your compiler treats those| registers as scratch./* | 2. Likewise, don't save FP0/FP1 if they are scratch */| registers.| 3. Delete handling of the fpsr if you only care about| the result.| 4. Some (most?) C compilers convert all float arguments| to double, and provide no support at all for extended| precision so remove the __l_fcoss and __l_fcosx entry points.| 5. Move the result to d0/d1 if the compiler is that old.| Copyright (C) Motorola, Inc. 1991| All Rights Reserved|| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA| The copyright notice above does not evidence any| actual or intended publication of such source code.| xref __l_tag| xref __l_scos| xref __l_ld_pone| xref __l_t_operr| xref __l_mon_nan| xref __l_scosd .globl __l_fcoss__l_fcoss: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmoves a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_1052 bsrl __l_scos | normalized (regular) number jra L_1056L_1052: cmpb #0x20,d0 | zero? jne L_1053 bsrl __l_ld_pone jra L_1056L_1053: cmpb #0x40,d0 | infinity? jne L_1054 bsrl __l_t_operr jra L_1056L_1054: cmpb #0x60,d0 | NaN? jne L_1055 bsrl __l_mon_nan jra L_1056L_1055: bsrl __l_scosd | assuming a denorm...L_1056: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fcosd__l_fcosd: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmoved a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_1057 bsrl __l_scos | normalized (regular) number jra L_105BL_1057: cmpb #0x20,d0 | zero? jne L_1058 bsrl __l_ld_pone jra L_105BL_1058: cmpb #0x40,d0 | infinity? jne L_1059 bsrl __l_t_operr jra L_105BL_1059: cmpb #0x60,d0 | NaN? jne L_105A bsrl __l_mon_nan jra L_105BL_105A: bsrl __l_scosd | assuming a denorm...L_105B: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts .globl __l_fcosx__l_fcosx: link a6,#-LOCAL_SIZE moveml d0-d1/a0-a1,a6@(USER_DA) fmovemx fp0-fp3,a6@(USER_FP0) fmovel fpsr,a6@(USER_FPSR) fmovel fpcr,a6@(USER_FPCR) fmovel fpcr,d1 /* | user's rounding mode/precision */ fmovel #0,fpcr | force rounding mode/prec to extended,rn|| copy, convert and tag input argument| fmovex a6@(8),fp0 fmovex fp0,a6@(ETEMP) lea a6@(ETEMP),a0 bsrl __l_tag moveb d0,a6@(STAG) tstb d0 jne L_105C bsrl __l_scos | normalized (regular) number jra L_105GL_105C: cmpb #0x20,d0 | zero? jne L_105D bsrl __l_ld_pone jra L_105GL_105D: cmpb #0x40,d0 | infinity? jne L_105E bsrl __l_t_operr jra L_105GL_105E: cmpb #0x60,d0 | NaN? jne L_105F bsrl __l_mon_nan jra L_105GL_105F: bsrl __l_scosd | assuming a denorm...L_105G: fmovel fpsr,d0 | update status register orb a6@(USER_FPSR+3),d0 | add previously accrued exceptions fmovel d0,fpsr|| Result is now in FP0| moveml a6@(USER_DA),d0-d1/a0-a1 fmovemx a6@(USER_FP1),fp1-fp3 | note: fp0 not restored fmovel a6@(USER_FPCR),fpcr | fpcr restored unlk a6 rts|| MONADIC.GEN 1.3 4/30/91|| MONADIC.GEN --- generic MONADIC template|| This version saves all registers that will be used by the emulation| routines and restores all but FP0 on exit. The FPSR is| updated to reflect the result of the operation. Return value| is placed in FP0 for single, double and extended results.|| The package subroutines expect the incoming fpcr to be zeroed| since they need extended precision to work properly. The/* | 'final' fpcr is expected in d1 so that the calculated result */| can be properly sized and rounded. Also, if the incoming fpcr| has enabled any exceptions, the exception will be taken on the| final fmovem in this template.|
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -