mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 01:55:19 +00:00
[LIBM] Fix ldexp.c / ldexpf.c
This commit is contained in:
parent
4f348ee971
commit
7277e26944
3 changed files with 30 additions and 6 deletions
|
@ -25,9 +25,17 @@
|
|||
*
|
||||
*/
|
||||
|
||||
#include "fn_macros.h"
|
||||
#include "libm_util_amd.h"
|
||||
#include "libm_special.h"
|
||||
#include "libm.h"
|
||||
#include "libm_util.h"
|
||||
#include "libm_new.h"
|
||||
|
||||
#define FN_PROTOTYPE_REF FN_PROTOTYPE
|
||||
#define __amd_handle_error _handle_error
|
||||
#define __amd_ldexp OP_LDEXP
|
||||
|
||||
//#include "fn_macros.h"
|
||||
//#include "libm_util.h"
|
||||
//#include "libm_special.h"
|
||||
|
||||
double FN_PROTOTYPE_REF(ldexp)(double x, int n)
|
||||
{
|
||||
|
|
|
@ -25,9 +25,17 @@
|
|||
*
|
||||
*/
|
||||
|
||||
#include "fn_macros.h"
|
||||
#include "libm_util_amd.h"
|
||||
#include "libm_special.h"
|
||||
#include "libm.h"
|
||||
#include "libm_util.h"
|
||||
#include "libm_new.h"
|
||||
|
||||
#define FN_PROTOTYPE_REF FN_PROTOTYPE
|
||||
#define __amd_handle_errorf _handle_errorf
|
||||
#define __amd_ldexp OP_LDEXP
|
||||
|
||||
//#include "fn_macros.h"
|
||||
//#include "libm_util_amd.h"
|
||||
//#include "libm_special.h"
|
||||
|
||||
float FN_PROTOTYPE_REF(ldexpf)(float x, int n)
|
||||
{
|
||||
|
|
|
@ -32,6 +32,14 @@
|
|||
#include <float.h>
|
||||
|
||||
|
||||
#define MULTIPLIER_SP 24
|
||||
#define MULTIPLIER_DP 53
|
||||
|
||||
static const double VAL_2PMULTIPLIER_DP = 9007199254740992.0;
|
||||
static const double VAL_2PMMULTIPLIER_DP = 1.1102230246251565404236316680908e-16;
|
||||
static const float VAL_2PMULTIPLIER_SP = 16777216.0F;
|
||||
static const float VAL_2PMMULTIPLIER_SP = 5.9604645e-8F;
|
||||
|
||||
/* Definitions for double functions on 64 bit machines */
|
||||
#define SIGNBIT_DP64 0x8000000000000000
|
||||
#define EXPBITS_DP64 0x7ff0000000000000
|
||||
|
|
Loading…
Reference in a new issue