History log of /freebsd-current/lib/msun/src/e_j0.c
Revision Date Author Comments
# 0dd5a560 28-Jan-2024 Steve Kargl <kargl@FreeBSD.org>

lib/msun: Cleanup after $FreeBSD$ removal

Remove no longer needed explicit inclusion of sys/cdefs.h.

PR: 276669
MFC after: 1 week


# dc36d6f9 23-Nov-2023 Warner Losh <imp@FreeBSD.org>

lib: Remove ancient SCCS tags.

Remove ancient SCCS tags from the tree, automated scripting, with two
minor fixup to keep things compiling. All the common forms in the tree
were removed with a perl script.

Sponsored by: Netflix


# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# 99843eb8 03-Aug-2023 Steve Kargl <kargl@FreeBSD.org>

Clean up libm use of the __ieee754_ prefix

This removes the __ieee754_ prefix from a number of the math functions.
msun/src/math_private.h contains the statement that

/*
* ieee style elementary functions
*
* We rename functions here to improve other sources' diffability
* against fdlibm.
*/
#define __ieee754_sqrt sqrt
...

Here, fdlibm refers to https://netlib.org/fdlibm. It is seen from
https://netlib.org/fdlibm/readme that this prefix was used to
differentiate between different standards:

Wrapper functions will twist the result of the ieee754
function to comply to the standard specified by the value
of _LIB_VERSION
if _LIB_VERSION = _IEEE_, return the ieee754 result;
if _LIB_VERSION = _SVID_, return SVID result;
if _LIB_VERSION = _XOPEN_, return XOPEN result;
if _LIB_VERSION = _POSIX_, return POSIX/ANSI result.
(These are macros, see fdlibm.h for their definition.)

AFAICT, FreeBSD has never supported these wrappers. In addition, as C99,
principally the long double, functions were added to libm, this
convention was not maintained. Given that only 148 of 324 files under
lib/msun contain a "Copyright (C) 1993 by Sun Microsystems" statement,
the removal of the __ieee754_ prefix provides consistency across all
source files.

The last time someone compared lib/msun to fdlibm appears to be

commit 3f70824172feb82ea3dcdb3866b54fe0eb7cd890
Author: David Schultz <das@FreeBSD.org>
Date: Fri Feb 4 18:26:06 2005 +0000

Reduce diffs against vendor source (Sun fdlibm 5.3).

The most recent fdlibm RCS string that appears in a Sun Microsystem
copyrighted file is date "95/01/18". With Oracle Corporation's
acquisition of Sun Microsystems in 2009, it is unlikely that fdlibm will
ever be updated. A search for fdlibm at https://opensource.oracle.com/
yields no hits.

Finally, OpenBSD removed the use of this prefix over 21 years ago. pSee
revision 1.6 of OpenBSD's math_private.h.

Note: this does not drop the __ieee754_ prefix from the trigonometric
argument reduction functions, e.g., __ieee754_rem_pio2. These functions
are internal to the libm and exported through Symbol.map; and thus,
reserved for the implementation.

PR: 272783
MFC after: 1 week


# 885bfcda 10-Feb-2019 Peter Jeremy <peterj@FreeBSD.org>

Replace calls to sin(x) and cos(x) with a single call to sincos().
Replace calls to sinf(x) and cosf(x) with a single call to sincosf().

Submitted by: Steve Kargl <sgk@troutmask.apl.washington.edu>
Reviewed by: bde
Approved by: grog
MFC after: 3 days


# 76c528d3 14-Jan-2019 Pedro F. Giffuni <pfg@FreeBSD.org>

msun: reduce diff between src/e_j0.c and src/e_j0f.c

PR: 229501
MFC after: 1 week


# 46a846f7 08-Jul-2018 Mark Johnston <markj@FreeBSD.org>

Fix whitespace issues in bessel function routines.

PR: 229423
Submitted by: Steve Kargl <sgk@troutmask.apl.washington.edu>
MFC after: 3 days


# 5b3a5f83 17-May-2015 Steve Kargl <kargl@FreeBSD.org>

In r279493, the functions pzero[f](), qzero[f], pone[f](),
and qone[f]() were marked as __inline, but their forward
declarations were not updated. Fix the forward declarations
to match the actual function declarations.

Requested by: bde


# 186f6207 10-Mar-2015 Steve Kargl <kargl@FreeBSD.org>

According to POSIX.1-2008, the Bessel functions of second kind
should raise a divide-by-zero floating point exception for x = +-0
and an invalid floating point exception for x < 0 including x = -Inf.
Update the code to raise the exception and update the documentation
with hopefully better description of the behavior.

Reviewed by: bde (code only)


# a737ef56 01-Mar-2015 Steve Kargl <kargl@FreeBSD.org>

Give compilers a stronger hint to inline the functions
pzero[f], qzero[f], pone[f], and qone[f]. While here
fix the function declarations in accordance with style(9).


# d300dc23 24-Feb-2015 Pedro F. Giffuni <pfg@FreeBSD.org>

msun: drop unnecessary checks (part 2).

Drop an unnecessary check in some calculations. The check
would have Coverity falsely conclude that a variable could
be left undefined.


# 8617260a 21-Feb-2015 Pedro F. Giffuni <pfg@FreeBSD.org>

msun: drop unnecessary checks.

Drop an unnecessary check in some calculations. The check
would have Coverity falsely conclude that variables could
be left undefined.

Discussed with: kargl, bde
Reviewed by: bde


# 2656e946 05-Dec-2014 Steve Kargl <kargl@FreeBSD.org>

Update the constants associated with the evaluation of j0f(x)
for |x| small.

While here, remove the explicit cast of 0.25 to float. Replace
a multiplication involving 0.25 by a division using an integer
constant 4. Make a similar change in j0() to minimize the diff.

Suggested by: bde


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# 5aa554c7 21-Feb-2008 David Schultz <das@FreeBSD.org>

s/rcsid/__FBSDID/


# 3f708241 04-Feb-2005 David Schultz <das@FreeBSD.org>

Reduce diffs against vendor source (Sun fdlibm 5.3).


# 59b19ff1 28-May-2002 Alfred Perlstein <alfred@FreeBSD.org>

Fix formatting, this is hard to explain, so I'll show one example.

- float ynf(int n, float x) /* wrapper ynf */
+float
+ynf(int n, float x) /* wrapper ynf */

This is because the __STDC__ stuff was indented.

Reviewed by: md5


# 2dcc2286 28-May-2002 Alfred Perlstein <alfred@FreeBSD.org>

Assume __STDC__, remove non-__STDC__ code.

Reviewed by: md5


# 7f3dea24 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# 7e546392 22-Feb-1997 Peter Wemm <peter@FreeBSD.org>

Revert $FreeBSD$ to $Id$


# 1130b656 14-Jan-1997 Jordan K. Hubbard <jkh@FreeBSD.org>

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


# 6c06b4e2 29-May-1995 Rodney W. Grimes <rgrimes@FreeBSD.org>

Remove trailing whitespace.


# 3a8617a8 19-Aug-1994 Jordan K. Hubbard <jkh@FreeBSD.org>

J.T. Conklin's latest version of the Sun math library.

-- Begin comments from J.T. Conklin:
The most significant improvement is the addition of "float" versions
of the math functions that take float arguments, return floats, and do
all operations in floating point. This doesn't help (performance)
much on the i386, but they are still nice to have.

The float versions were orginally done by Cygnus' Ian Taylor when
fdlibm was integrated into the libm we support for embedded systems.
I gave Ian a copy of my libm as a starting point since I had already
fixed a lot of bugs & problems in Sun's original code. After he was
done, I cleaned it up a bit and integrated the changes back into my
libm.
-- End comments

Reviewed by: jkh
Submitted by: jtc