3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-23 17:15:31 +00:00

Change how 64 bit builds are detected.

Instead of doing this at configure time, we look at the actual
compile time status. This also avoids hardcoding checks based on
what CPU architecture is present, which doesn't work when Z3 is
being built on non-x86_64 platforms.
This commit is contained in:
Bruce Mitchener 2018-12-09 16:16:20 +07:00
parent 559f57470e
commit 51a947b73d
12 changed files with 17 additions and 22 deletions

View file

@ -61,7 +61,7 @@ hwf_manager::hwf_manager() :
m_mpz_manager(m_mpq_manager)
{
#ifdef _WINDOWS
#if defined(_AMD64_) || defined(_M_IA64)
#if defined(_WIN64)
// Precision control is not supported on x64.
// See: http://msdn.microsoft.com/en-us/library/e9b52ceh(VS.110).aspx
// CMW: I think this is okay though, the compiler will chose the right instructions
@ -557,7 +557,7 @@ void hwf_manager::mk_ninf(hwf & o) {
}
#ifdef _WINDOWS
#if defined(_AMD64_) || defined(_M_IA64)
#if defined(_WIN64)
#ifdef USE_INTRINSICS
#define SETRM(RM) _MM_SET_ROUNDING_MODE(RM)
#else

View file

@ -20,7 +20,7 @@ Revision History:
#ifndef MACHINE_H_
#define MACHINE_H_
#ifdef _AMD64_
#if defined(__LP64__) || defined(_WIN64)
#define PTR_ALIGNMENT 3
#else
#define PTR_ALIGNMENT 2

View file

@ -61,7 +61,7 @@ public:
char * to_string(mpn_digit const * a, size_t lng,
char * buf, size_t lbuf) const;
private:
#ifdef _AMD64_
#if defined(__LP64__) || defined(_WIN64)
class mpn_sbuffer : public sbuffer<mpn_digit> {
public:
mpn_sbuffer() : sbuffer<mpn_digit>() {}

View file

@ -56,7 +56,7 @@ Revision History:
#define _trailing_zeros32(X) _tzcnt_u32(X)
#endif
#if defined(_AMD64_)
#if defined(__LP64__) || defined(_WIN64)
#if defined(__GNUC__)
#define _trailing_zeros64(X) __builtin_ctzll(X)
#else

View file

@ -56,7 +56,7 @@ public:
explicit symbol(char const * d);
explicit symbol(unsigned idx):
m_data(BOXTAGINT(char const *, idx, 1)) {
#ifndef _AMD64_
#if !defined(__LP64__) && !defined(_WIN64)
SASSERT(idx < (SIZE_MAX >> PTR_ALIGNMENT));
#endif
}