Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
8f8fa918
Commit
8f8fa918
authored
Apr 28, 2021
by
Piotr Caban
Committed by
Alexandre Julliard
Apr 28, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msvcrt: Import y0 implementation from musl.
Signed-off-by:
Piotr Caban
<
piotr@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
c739e222
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
43 additions
and
31 deletions
+43
-31
configure
configure
+0
-1
configure.ac
configure.ac
+0
-1
math.c
dlls/msvcrt/math.c
+43
-11
unixlib.c
dlls/msvcrt/unixlib.c
+0
-14
unixlib.h
dlls/msvcrt/unixlib.h
+0
-1
config.h.in
include/config.h.in
+0
-3
No files found.
configure
View file @
8f8fa918
...
@@ -19662,7 +19662,6 @@ for ac_func in \
...
@@ -19662,7 +19662,6 @@ for ac_func in \
tgammaf
\
tgammaf
\
trunc
\
trunc
\
truncf
\
truncf
\
y0
\
y1
\
y1
\
yn
yn
...
...
configure.ac
View file @
8f8fa918
...
@@ -2706,7 +2706,6 @@ AC_CHECK_FUNCS(\
...
@@ -2706,7 +2706,6 @@ AC_CHECK_FUNCS(\
tgammaf \
tgammaf \
trunc \
trunc \
truncf \
truncf \
y0 \
y1 \
y1 \
yn
yn
)
)
...
...
dlls/msvcrt/math.c
View file @
8f8fa918
...
@@ -2696,18 +2696,50 @@ double CDECL _jn(int n, double num)
...
@@ -2696,18 +2696,50 @@ double CDECL _jn(int n, double num)
/*********************************************************************
/*********************************************************************
* _y0 (MSVCRT.@)
* _y0 (MSVCRT.@)
*/
*/
double
CDECL
_y0
(
double
num
)
double
CDECL
_y0
(
double
x
)
{
{
double
retval
;
static
const
double
tpi
=
6.36619772367581382433e-01
,
u00
=
-
7.38042951086872317523e-02
,
u01
=
1.76666452509181115538e-01
,
u02
=
-
1.38185671945596898896e-02
,
u03
=
3.47453432093683650238e-04
,
u04
=
-
3.81407053724364161125e-06
,
u05
=
1.95590137035022920206e-08
,
u06
=
-
3.98205194132103398453e-11
,
v01
=
1.27304834834123699328e-02
,
v02
=
7.60068627350353253702e-05
,
v03
=
2.59150851840457805467e-07
,
v04
=
4.41110311332675467403e-10
;
double
z
,
u
,
v
;
unsigned
int
ix
,
lx
;
if
(
!
isfinite
(
num
))
*
_errno
()
=
EDOM
;
ix
=
*
(
ULONGLONG
*
)
&
x
>>
32
;
retval
=
unix_funcs
->
y0
(
num
);
lx
=
*
(
ULONGLONG
*
)
&
x
;
if
(
_fpclass
(
retval
)
==
_FPCLASS_NINF
)
{
/* y0(nan)=nan, y0(<0)=nan, y0(0)=-inf, y0(inf)=0 */
*
_errno
()
=
EDOM
;
if
((
ix
<<
1
|
lx
)
==
0
)
retval
=
NAN
;
return
math_error
(
_OVERFLOW
,
"_y0"
,
x
,
0
,
-
INFINITY
);
}
if
(
isnan
(
x
))
return
retval
;
return
x
;
if
(
ix
>>
31
)
return
math_error
(
_DOMAIN
,
"_y0"
,
x
,
0
,
0
/
(
x
-
x
));
if
(
ix
>=
0x7ff00000
)
return
1
/
x
;
if
(
ix
>=
0x40000000
)
{
/* x >= 2 */
/* large ulp errors near zeros: 3.958, 7.086,.. */
return
j0_y0_approx
(
ix
,
x
,
TRUE
);
}
if
(
ix
>=
0x3e400000
)
{
/* x >= 2**-27 */
/* large ulp error near the first zero, x ~= 0.89 */
z
=
x
*
x
;
u
=
u00
+
z
*
(
u01
+
z
*
(
u02
+
z
*
(
u03
+
z
*
(
u04
+
z
*
(
u05
+
z
*
u06
)))));
v
=
1
.
0
+
z
*
(
v01
+
z
*
(
v02
+
z
*
(
v03
+
z
*
v04
)));
return
u
/
v
+
tpi
*
(
j0
(
x
)
*
log
(
x
));
}
return
u00
+
tpi
*
log
(
x
);
}
}
/*********************************************************************
/*********************************************************************
...
...
dlls/msvcrt/unixlib.c
View file @
8f8fa918
...
@@ -966,19 +966,6 @@ static float CDECL unix_tgammaf(float x)
...
@@ -966,19 +966,6 @@ static float CDECL unix_tgammaf(float x)
}
}
/*********************************************************************
/*********************************************************************
* y0
*/
static
double
CDECL
unix_y0
(
double
num
)
{
#ifdef HAVE_Y0
return
y0
(
num
);
#else
FIXME
(
"not implemented
\n
"
);
return
0
;
#endif
}
/*********************************************************************
* y1
* y1
*/
*/
static
double
CDECL
unix_y1
(
double
num
)
static
double
CDECL
unix_y1
(
double
num
)
...
@@ -1093,7 +1080,6 @@ static const struct unix_funcs funcs =
...
@@ -1093,7 +1080,6 @@ static const struct unix_funcs funcs =
unix_tgammaf
,
unix_tgammaf
,
unix_trunc
,
unix_trunc
,
unix_truncf
,
unix_truncf
,
unix_y0
,
unix_y1
,
unix_y1
,
unix_yn
unix_yn
};
};
...
...
dlls/msvcrt/unixlib.h
View file @
8f8fa918
...
@@ -110,7 +110,6 @@ struct unix_funcs
...
@@ -110,7 +110,6 @@ struct unix_funcs
float
(
CDECL
*
tgammaf
)(
float
x
);
float
(
CDECL
*
tgammaf
)(
float
x
);
double
(
CDECL
*
trunc
)(
double
x
);
double
(
CDECL
*
trunc
)(
double
x
);
float
(
CDECL
*
truncf
)(
float
x
);
float
(
CDECL
*
truncf
)(
float
x
);
double
(
CDECL
*
y0
)(
double
num
);
double
(
CDECL
*
y1
)(
double
num
);
double
(
CDECL
*
y1
)(
double
num
);
double
(
CDECL
*
yn
)(
int
order
,
double
num
);
double
(
CDECL
*
yn
)(
int
order
,
double
num
);
};
};
...
...
include/config.h.in
View file @
8f8fa918
...
@@ -1172,9 +1172,6 @@
...
@@ -1172,9 +1172,6 @@
/* Define if Xrandr has the XRRGetProviderResources function */
/* Define if Xrandr has the XRRGetProviderResources function */
#undef HAVE_XRRGETPROVIDERRESOURCES
#undef HAVE_XRRGETPROVIDERRESOURCES
/* Define to 1 if you have the `y0' function. */
#undef HAVE_Y0
/* Define to 1 if you have the `y1' function. */
/* Define to 1 if you have the `y1' function. */
#undef HAVE_Y1
#undef HAVE_Y1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment