home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / vol_200 / 250_01 / atan.s < prev    next >
Text File  |  1987-10-29  |  512b  |  30 lines

  1.     .ttl    "atan.s"
  2.  
  3. * MC68020/MC68881 IEEE Format Single Precision Routines
  4. *
  5. * Written by: Edmund H. Ramm
  6. *
  7. * _atan entry point for single prec. arc tangent, operand in 4(sp)
  8. *
  9. *     sp     4
  10. *    ---------------
  11. *    | ret  |  x   |
  12.  
  13.  
  14.  
  15.     .text
  16.     .globl    _atan
  17.  
  18.  
  19. _atan:
  20. *
  21. * on exit, d0 = atan( 4(sp) )
  22. *
  23. *    fatan.s    4(sp),fp0        * fp0 <-- atan( 4(sp) )
  24.     dc.w    $f22f,$440a,$0004
  25. *    fmove.s    fp0,d0            * d0 <-- arc tangent
  26.     dc.w    $f200,$6400
  27.     rts
  28.  
  29.     .end
  30.