ibm:ibm1130-lib:dmsr2v12:r2ftanh_lst
R2FTANH
Table Of Contents |
---|
|
- r2ftanh.lst
ASM1130 CROSS ASSEMBLER V1.22 -- V2M12 -- Sun Nov 1 19:25:07 2020 Source File: \r2ftanh.asm 1 | *************************************************** R2I00010 2 | * * R2I00020 3 | * SUBROUTINE NAME- * R2I00030 4 | * FULL NAME- STANDARD PRECISION FLOATING- * R2I00040 5 | * POINT HYPERBOLIC TANGENT FUNCTION. * R2I00050 6 | * CODE NAME- FTNH/FTANH * R2I00060 7 | * PURPOSE- THIS SUBPROGRAM COMPUTES THE HYPER- * R2I00070 8 | * BOLIC TANGENT OF A STANDARD PRECISION FLOAT* R2I00080 9 | * ING-POINT NUMBER. * R2I00090 10 | * METHOD-SEE IBM 1130 SUBROUTINE LIBRARY MANUAL.* R2I00100 11 | * CAPABILITIES AND LIMITATIONS- SEE IBM 1130 * R2I00110 12 | * SUBROUTINE LIBRARY MANUAL. * R2I00120 13 | * SPECIAL FEATURES- N/A * R2I00130 14 | * ADDITIONAL INFORMATION- * R2I00140 15 | * ESTIMATED EXECUTION TIME- SEE IBM 1130 * R2I00150 16 | * SUBROUTINE LIBRARY MANUAL * R2I00160 17 | * * R2I00170 18 | *************************************************** R2I00180 CALL FTANH -V1. 20 | SPR R2I00200 21 | ENT FTANH STANDARD FORTRAN NAME R2I00210 22 | ENT FTNH R2I00220 0000 0000 23 | FTANH DC 0 FORTRAN ENTRY R2I00230 0001 061C*58D7 24 | LIBF FGETP GET PARAMETER R2I00240 0002 0000 25 | FTNH DC 0 USER ENTRY R2I00250 0003 C37D 26 | LD 3 125 ADD ONE TO EXPONENT TO R2I00260 0004 8028 27 | A ONE DOUBLE X. R2I00270 0005 D37D 28 | STO 3 125 R2I00280 0006 9028 29 | S EXK CHK EXPONENT RANGE R2I00290 0007 4C30 0023R 30 | BSC L OUT1,-Z BR IF TOO LARGE,SET TANH=+1 R2I00300 0009 C37E 31 | LD 3 126 GET MANTISSA. IF IT IS R2I00310 000A 4818 32 | BSC +- ZERO,SET EXPONENT TO ZERO R2I00320 000B D37D 33 | STO 3 125 R2I00330 000C 069D*7540 34 | CALL FXPN COMPUTE E**2X. X=ARGUMENT R2I00340 000E 0604*4100 35 | LIBF FADD (E**2X)+1 R2I00350 000F 0030R 36 | DC FLONE R2I00360 0010 068A*3580 37 | LIBF FSTO SAVE IN Z R2I00370 0011 0032R 38 | DC Z R2I00380 0012 C37F 39 | LD 3 127 GET EXPONENT OF FAC R2I00390 0013 1008 40 | SLA 8 AND SAVE IN TEMP. R2I00400 0014 1808 41 | SRA 8 R2I00410 0015 D016 42 | STO TEMP R2I00420 0016 0604*4100 43 | LIBF FADD COMPUTE (E**2X)-1 R2I00430 0017 0034R 44 | DC MIN2 R2I00440 0018 1010 45 | SLA 16 CORRECT THE DIVIDEND R2I00450 0019 9012 46 | S TEMP TO ALLOW FOR DIVISOR R2I00460 001A A37E 47 | M 3 126 TRUNCATION UPON DIVISION. R2I00470 001B A816 48 | D Z R2I00480 001C 1890 49 | SRT 16 R2I00490 001D 8B7E 50 | AD 3 126 R2I00500 001E DB7E 51 | STD 3 126 R2I00510 001F 0610*9940 52 | LIBF FDIV PERFORM DIVISION-- R2I00520 0020 0032R 53 | DC Z (E**2X-1)/(E**2X+1). R2I00530 0021 4C80 0002R 54 | BSC I FTNH RETURN TO MAIN PROGRAM R2I00540 55 | * R2I00550 56 | *ABSOLUTE VALUE OF ARGUMENT GT 32. RETURN +1 OR -1. R2I00560 57 | * R2I00570 0023 C37E 58 | OUT1 LD 3 126 GET ARGUMENT AND R2I00580 0024 18A0 59 | SRT 32 SHIFT OUT ALL BUT THE R2I00590 0025 109F 60 | SLT 31 SIGN BIT. R2I00600 0026 E809 61 | OR FLONE PUT THE SIGN ON FLT PT ONE R2I00610 0027 DB7E 62 | STD 3 126 AND STORE IN FAC. R2I00620 0028 C005 63 | LD EXP1 GET CORRESPONDING EXPONENT. R2I00630 0029 D37D 64 | STO 3 125 R2I00640 002A 4C80 0002R 65 | BSC I FTNH RETURN TO MAIN PROGRAM R2I00650 66 | * R2I00660 67 | *CONSTANTS AND BUFFER AREA R2I00670 68 | * R2I00680 002C 0000 69 | TEMP DC 0 SAVE LAST OF DIVISOR R2I00690 002D 0001 70 | ONE DC 1 SINGLE WORD ONE R2I00700 002E 0081 71 | EXP1 DC 129 EXPONENT FOR FLT PT ONE R2I00710 002F 0085 72 | EXK DC 128+5 EXPONENT CHECK R2I00720 0030 4000 0081 73 | FLONE DEC 1.0 FLT PT ONE R2I00730 0032 0000 0000 74 | Z DEC 0.0 STORE DIVISOR R2I00740 0034 C000 0082 75 | MIN2 DEC -2.0 DIFFERENCE BETWEEN DIVISOR R2I00750 76 | * AND DIVIDEND. R2I00760 0036 77 | END R2I00770 There were no errors in this assembly === CROSS REFERENCES ========================================================== Name Val Defd Referenced EXK 002FR 72 29 EXP1 002ER 71 63 FLONE 0030R 73 36 61 FTANH 0000R 23 FTNH 0002R 25 54 65 MIN2 0034R 75 44 ONE 002DR 70 27 OUT1 0023R 58 30 TEMP 002CR 69 42 46 Z 0032R 74 38 48 53
ibm/ibm1130-lib/dmsr2v12/r2ftanh_lst.txt ยท Last modified: 2023/08/06 13:34 by Site Administrator