added: some pragmas for the clang compiler:
#pragma clang diagnostic ignored "-Wtautological-compare" to get rid off some warning messages changed: changing version number to 0.9.3 release git-svn-id: svn://ttmath.org/publicrep/ttmath/trunk@436 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
parent
e58253a078
commit
506840787a
|
@ -1,4 +1,9 @@
|
|||
Version 0.9.3 prerelease (2011.02.27):
|
||||
Version 0.9.3 (2012.12.28):
|
||||
* fixed: in Big::FromDouble(double value) (only 32 bit version)
|
||||
buffer overflow in referencing to UInt<2>
|
||||
this was used when 'value' was in so called "unnormalized" state
|
||||
(E=0 and F is nonzero)
|
||||
it produced incorrect mantissa (on about 8th decimal digit up)
|
||||
* added: Parser::InitCGamma()
|
||||
initializing coefficients used when calculating the gamma (or factorial) function
|
||||
this speed up the next calculations
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
Copyright (c) 2006-2011, Tomasz Sowa
|
||||
Copyright (c) 2006-2012, Tomasz Sowa
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* Copyright (c) 2006-2010, Tomasz Sowa
|
||||
* Copyright (c) 2006-2012, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
|
@ -2835,7 +2835,9 @@ namespace ttmath
|
|||
he can only use '#include <ttmath/ttmath.h>'
|
||||
*/
|
||||
#include "ttmathparser.h"
|
||||
#include "ttmathdec.h"
|
||||
|
||||
// Dec is not finished yet
|
||||
//#include "ttmathdec.h"
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
*/
|
||||
|
||||
/*
|
||||
* Copyright (c) 2006-2011, Tomasz Sowa
|
||||
* Copyright (c) 2006-2012, Tomasz Sowa
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
|
@ -74,7 +74,7 @@
|
|||
#define TTMATH_MINOR_VER 9
|
||||
#define TTMATH_REVISION_VER 3
|
||||
|
||||
#define TTMATH_PRERELEASE_VER 1
|
||||
#define TTMATH_PRERELEASE_VER 0
|
||||
|
||||
|
||||
|
||||
|
@ -122,7 +122,7 @@
|
|||
_M_IX86 defined by Visual Studio, Intel C/C++, Digital Mars and Watcom C/C++
|
||||
|
||||
amd64 architecture:
|
||||
__x86_64__ defined by GNU C and Sun Studio
|
||||
__x86_64__ defined by GNU C, CLANG (LLVM) and Sun Studio
|
||||
_M_X64 defined by Visual Studio
|
||||
|
||||
asm version is available only for x86 or amd64 platforms
|
||||
|
@ -134,7 +134,8 @@
|
|||
|
||||
#if !defined _MSC_VER && !defined __GNUC__
|
||||
/*!
|
||||
another compilers than MS VC or GCC by default use no asm version
|
||||
another compilers than MS VC or GCC or CLANG (LLVM) by default use no asm version
|
||||
(CLANG defines __GNUC__ too)
|
||||
*/
|
||||
#define TTMATH_NOASM
|
||||
#endif
|
||||
|
|
|
@ -1260,9 +1260,18 @@ private:
|
|||
UInt<ss_size*2> res;
|
||||
Mul2Big2<ss_size>(ss1, ss2, res);
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
|
||||
for(uint i=0 ; i<ss_size*2 ; ++i)
|
||||
result[i] = res.table[i];
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
else
|
||||
|
@ -1355,10 +1364,18 @@ private:
|
|||
|
||||
Mul3Big2<first_size>(temp.table, temp2.table, z1.table);
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
|
||||
// clearing the rest of z1
|
||||
for(i=first_size*2 ; i<first_size*3 ; ++i)
|
||||
z1.table[i] = 0;
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
if( xc )
|
||||
{
|
||||
|
@ -1375,9 +1392,18 @@ private:
|
|||
|
||||
if( xc && yc )
|
||||
{
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
|
||||
for( i=first_size*2 ; i<first_size*3 ; ++i )
|
||||
if( ++z1.table[i] != 0 )
|
||||
break; // break if there was no carry
|
||||
break; // break if there was no carry
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
// z1 = z1 - z2
|
||||
|
@ -1396,11 +1422,20 @@ private:
|
|||
uint z1_size = result_size - first_size;
|
||||
TTMATH_ASSERT( z1_size <= first_size*3 )
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
|
||||
for(i=z1_size ; i<first_size*3 ; ++i)
|
||||
{
|
||||
TTMATH_ASSERT( z1.table[i] == 0 )
|
||||
}
|
||||
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
c = AddVector(result+first_size, z1.table, result_size-first_size, z1_size, result+first_size);
|
||||
TTMATH_ASSERT(c==0)
|
||||
}
|
||||
|
@ -2505,10 +2540,18 @@ public:
|
|||
*/
|
||||
bool IsOnlyTheHighestBitSet() const
|
||||
{
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
|
||||
for(uint i=0 ; i<value_size-1 ; ++i)
|
||||
if( table[i] != 0 )
|
||||
return false;
|
||||
|
||||
#ifdef __clang__
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
if( table[value_size-1] != TTMATH_UINT_HIGHEST_BIT )
|
||||
return false;
|
||||
|
||||
|
@ -4036,7 +4079,7 @@ public:
|
|||
|
||||
|
||||
/*
|
||||
following methods are defined in:
|
||||
Following methods are defined in:
|
||||
ttmathuint_x86.h
|
||||
ttmathuint_x86_64.h
|
||||
ttmathuint_noasm.h
|
||||
|
|
Loading…
Reference in New Issue