1: /*
   2:  * Copyright (c) 1987 Regents of the University of California.
   3:  * All rights reserved.  The Berkeley software License Agreement
   4:  * specifies the terms and conditions for redistribution.
   5:  */
   6: 
   7: #ifdef LIBC_SCCS
   8:         <@(#)frexp.s	2.3 (Berkeley) 1/6/87\0>
   9:         .even
  10: #endif LIBC_SCCS
  11: 
  12: /*
  13:  * mantissa = frexp(value, ip)
  14:  *	double	mantissa,
  15:  *		value;
  16:  *	int	*ip;
  17:  *
  18:  * returns a fractional part 1/2 <= |mantisa| < 1
  19:  * and stores an exponent so value = mantisa * 2^(*ip)
  20:  */
  21: #include "DEFS.h"
  22: 
  23: ENTRY(frexp)
  24:         movf    2(sp),fr0       / fr0 = value
  25:         movei   fr0,r0          / r0 = log2(value)
  26:         movie   $0,fr0          / force result exponent to biased 0
  27:         mov     r0,*10.(sp)     / *ip = old log2(value)
  28:         rts     pc

Defined functions

Last modified: 1987-01-25
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 2242
Valid CSS Valid XHTML 1.0 Strict