aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Greenman <dg@FreeBSD.org>1995-01-22 22:03:45 +0000
committerDavid Greenman <dg@FreeBSD.org>1995-01-22 22:03:45 +0000
commit1504cd61727b44d99d6bedffcf562e771d90ca99 (patch)
tree3c104256f1aecc7132307e2645af18b8613f523b
parent95f51c5b57b80f726d3873a3d47c8f09731bb251 (diff)
downloadsrc-1504cd61727b44d99d6bedffcf562e771d90ca99.tar.gz
src-1504cd61727b44d99d6bedffcf562e771d90ca99.zip
(Very) minor improvement from NetBSD/J.T.Conklin.
Notes
Notes: svn path=/head/; revision=5783
-rw-r--r--lib/libc/i386/stdlib/abs.S4
-rw-r--r--lib/libc/i386/stdlib/labs.S4
2 files changed, 4 insertions, 4 deletions
diff --git a/lib/libc/i386/stdlib/abs.S b/lib/libc/i386/stdlib/abs.S
index 3122fcb84f6f..ab677d52f4c4 100644
--- a/lib/libc/i386/stdlib/abs.S
+++ b/lib/libc/i386/stdlib/abs.S
@@ -43,7 +43,7 @@
ENTRY(abs)
movl 4(%esp),%eax
- cmpl $0,%eax
- jge 1f
+ testl %eax,%eax
+ jns 1f
negl %eax
1: ret
diff --git a/lib/libc/i386/stdlib/labs.S b/lib/libc/i386/stdlib/labs.S
index b7a1c5dceebb..4475bb970c88 100644
--- a/lib/libc/i386/stdlib/labs.S
+++ b/lib/libc/i386/stdlib/labs.S
@@ -43,7 +43,7 @@
ENTRY(labs)
movl 4(%esp),%eax
- cmpl $0,%eax
- jge 1f
+ testl %eax,%eax
+ jns 1f
negl %eax
1: ret