Annotation of coherent/b/lib/libm/i8087/hypot87.m, revision 1.1.1.1

1.1       root        1: //////////
                      2: / libm 8087
                      3: / cabs(z), hypot(x, y)
                      4: //////////
                      5: 
                      6: #include "larges.h"
                      7: #include "ifno8087.h"
                      8: 
                      9:        .globl  cabs_
                     10:        .globl  hypot_
                     11: 
                     12: //////////
                     13: / double
                     14: / cabs(z)
                     15: / CPX z;
                     16: /
                     17: / hypot(x, y)
                     18: / double x, y;
                     19: //////////
                     20: 
                     21: x      =       RASIZE          / x arg offset
                     22: y      =       RASIZE+8        / y arg offset
                     23: 
                     24: cabs_:
                     25: hypot_:
                     26:        ifno8087(_cabs_)
                     27:        mov     bx, sp
                     28: 
                     29:        fdld    Pss x(bx)       / x
                     30:        fmul    st, st          / x*x
                     31:        fdld    Pss y(bx)       / y, x*x
                     32:        fmul    st, st          / y*y, x*x
                     33:        fadd                    / x*x + y*y
                     34:        fsqrt                   / result = sqrt(x*x + y*y)
                     35: 
                     36:        Gret

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.