patch-2.1.73 linux/arch/i386/math-emu/wm_sqrt.S
Next file: linux/arch/m68k/amiga/amifb.c
Previous file: linux/arch/i386/math-emu/wm_shrx.S
Back to the patch index
Back to the overall index
- Lines: 37
- Date:
Tue Dec 9 17:57:09 1997
- Orig file:
v2.1.72/linux/arch/i386/math-emu/wm_sqrt.S
- Orig date:
Thu Oct 5 06:30:43 1995
diff -u --recursive --new-file v2.1.72/linux/arch/i386/math-emu/wm_sqrt.S linux/arch/i386/math-emu/wm_sqrt.S
@@ -4,12 +4,12 @@
| |
| Fixed point arithmetic square root evaluation. |
| |
- | Copyright (C) 1992,1993,1995 |
+ | Copyright (C) 1992,1993,1995,1997 |
| W. Metzenthen, 22 Parker St, Ormond, Vic 3163, |
- | Australia. E-mail billm@jacobi.maths.monash.edu.au |
+ | Australia. E-mail billm@suburbia.net |
| |
| Call from C as: |
- | void wm_sqrt(FPU_REG *n, unsigned int control_word) |
+ | int wm_sqrt(FPU_REG *n, unsigned int control_word) |
| |
+---------------------------------------------------------------------------*/
@@ -92,7 +92,7 @@
/* We use a rough linear estimate for the first guess.. */
- cmpl EXP_BIAS,EXP(%esi)
+ cmpw EXP_BIAS,EXP(%esi)
jnz sqrt_arg_ge_2
shrl $1,%eax /* arg is in the range [1.0 .. 2.0) */
@@ -347,9 +347,8 @@
movl %esi,%eax
movl %edi,%ebx
movl PARAM1,%edi
- movl EXP_BIAS,EXP(%edi) /* Result is in [1.0 .. 2.0) */
- movl PARAM2,%ecx
- jmp fpu_reg_round_sqrt
+ movw EXP_BIAS,EXP(%edi) /* Result is in [1.0 .. 2.0) */
+ jmp fpu_reg_round
sqrt_near_exact_x:
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov