summaryrefslogtreecommitdiffstats
path: root/src/mesa/main
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2003-03-03 21:44:39 +0000
committerBrian Paul <[email protected]>2003-03-03 21:44:39 +0000
commit386578c5bcc5c6701a6b9692cdc04cfe4064ca06 (patch)
treed362c087bddee06fa34b30068cd19b56499e91a6 /src/mesa/main
parent42ad8664f972aaecff80934b5ec7d135d04ea767 (diff)
disable using optimized _mesa_sqrtf() for now
Diffstat (limited to 'src/mesa/main')
-rw-r--r--src/mesa/main/imports.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/mesa/main/imports.h b/src/mesa/main/imports.h
index 0915fc7b821..354819f43f0 100644
--- a/src/mesa/main/imports.h
+++ b/src/mesa/main/imports.h
@@ -1,4 +1,4 @@
-/* $Id: imports.h,v 1.15 2003/03/02 19:38:24 brianp Exp $ */
+/* $Id: imports.h,v 1.16 2003/03/03 21:44:39 brianp Exp $ */
/*
* Mesa 3-D graphics library
@@ -151,9 +151,7 @@ extern void _ext_mesa_free_pixelbuffer( void *pb );
/***
*** SQRTF: single-precision square root
***/
-#ifdef DEBUG
-# define SQRTF(X) ((float)_mesa_sqrtd((float) X))
-#elif defined(__WATCOMC__) && defined(USE_X86_ASM)
+#if defined(__WATCOMC__) && defined(USE_X86_ASM)
float asm_sqrt (float x);
#pragma aux asm_sqrt = \
"fsqrt" \
@@ -161,8 +159,12 @@ float asm_sqrt (float x);
value [8087] \
modify exact [];
# define SQRTF(X) asm_sqrt(X)
-#else
+#elif 0 /* _mesa_sqrtf() not accurate enough - temporarily disabled */
# define SQRTF(X) _mesa_sqrtf(X)
+#elif defined(XFree86LOADER) && defined(IN_MODULE)
+# define SQRTF(X) (float) xf86sqrt((float) (X))
+#else
+# define SQRTF(X) (float) sqrt((float) (X))
#endif