repo.or.cz
/
minix.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
libutil: add O_NOCTTY back to old pty open code
[minix.git]
/
lib
/
libc
/
arch
/
powerpc
/
gen
/
fabs.c
blob
25d28db8bbfccad407de059e2de46296fe1a7750
1
/* $NetBSD: fabs.c,v 1.4 2005/12/24 23:10:08 perry Exp $ */
2
3
#include <math.h>
4
5
double
6
fabs
(
double
x
)
7
{
8
#ifdef _SOFT_FLOAT
9
if
(
x
<
0
)
10
x
= -
x
;
11
#else
12
__asm
volatile
(
"fabs %0,%1"
:
"=f"
(
x
) :
"f"
(
x
));
13
#endif
14
return
(
x
);
15
}