projects
/
musl
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1295848
)
remove special nan handling from x86 sqrt asm
author
Rich Felker
<dalias@aerifal.cx>
Thu, 15 Mar 2012 23:56:36 +0000
(19:56 -0400)
committer
Rich Felker
<dalias@aerifal.cx>
Thu, 15 Mar 2012 23:56:36 +0000
(19:56 -0400)
a double precision nan, when converted to extended (80-bit) precision,
will never end in 0x400, since the corresponding bits do not exist in
the original double precision value. thus there's no need to waste
time and code size on this check.
src/math/i386/sqrt.s
patch
|
blob
|
history
diff --git
a/src/math/i386/sqrt.s
b/src/math/i386/sqrt.s
index
1bd3b05
..
8289d09
100644
(file)
--- a/
src/math/i386/sqrt.s
+++ b/
src/math/i386/sqrt.s
@@
-10,9
+10,6
@@
sqrt: fldl 4(%esp)
and $0x7ff,%ecx
cmp $0x400,%ecx
jnz 1f
- mov 8(%esp),%cx
- inc %cx
- jo 1f
and $0x200,%eax
sub $0x100,%eax
sub %eax,(%esp)