69 #if defined(__sun) || defined(__sun__)
70 # include <inttypes.h>
71 #elif !defined(WIN32) && !defined(_WIN32)
79 #define SC_DT_MIXED_COMMA_OPERATORS
109 #define SC_NEG -1 // Negative number
110 #define SC_ZERO 0 // Zero
111 #define SC_POS 1 // Positive number
112 #define SC_NOSIGN 2 // Uninitialized sc_signed number
121 #define BITS_PER_BYTE 8
122 #define BYTE_RADIX 256
123 #define BYTE_MASK 255
127 #define LOG2_BITS_PER_BYTE 3
132 #define BYTES_PER_DIGIT_TYPE 4
133 #define BITS_PER_DIGIT_TYPE 32
136 #define BYTES_PER_DIGIT 4
137 #define BITS_PER_DIGIT 30
138 #define DIGIT_RADIX (1ul << BITS_PER_DIGIT)
139 #define DIGIT_MASK (DIGIT_RADIX - 1)
145 #define BITS_PER_HALF_DIGIT (BITS_PER_DIGIT / 2)
146 #define HALF_DIGIT_RADIX (1ul << BITS_PER_HALF_DIGIT)
147 #define HALF_DIGIT_MASK (HALF_DIGIT_RADIX - 1)
150 #define DIV_CEIL2(x, y) (((x) - 1) / (y) + 1)
154 #define DIV_CEIL(x) DIV_CEIL2(x, BITS_PER_DIGIT)
157 extern const int MAX_NDIGITS;
178 # if defined(__x86_64__)
179 typedef long long int64;
180 typedef unsigned long long uint64;
189 typedef __int64
int64;
190 typedef unsigned __int64
uint64;
199 #define BITS_PER_CHAR 8
200 #define BITS_PER_INT (sizeof(int) * BITS_PER_CHAR)
201 #define BITS_PER_LONG (sizeof(long) * BITS_PER_CHAR)
202 #define BITS_PER_INT64 (sizeof(::sc_dt::int64) * BITS_PER_CHAR)
203 #define BITS_PER_UINT (sizeof(unsigned int) * BITS_PER_CHAR)
204 #define BITS_PER_ULONG (sizeof(unsigned long) * BITS_PER_CHAR)
205 #define BITS_PER_UINT64 (sizeof(::sc_dt::uint64) * BITS_PER_CHAR)
208 #define DIGITS_PER_CHAR 1
209 #define DIGITS_PER_INT ((BITS_PER_INT+29)/30)
210 #define DIGITS_PER_LONG ((BITS_PER_LONG+29)/30)
211 #define DIGITS_PER_INT64 ((BITS_PER_INT64+29)/30)
212 #define DIGITS_PER_UINT ((BITS_PER_UINT+29)/30)
213 #define DIGITS_PER_ULONG ((BITS_PER_ULONG+29)/30)
214 #define DIGITS_PER_UINT64 ((BITS_PER_UINT64+29)/30)
219 #if defined( _WIN32 ) || defined( __HP_aCC )
228 #define LLWIDTH BITS_PER_INT64
229 #define INTWIDTH BITS_PER_INT
235 #define SC_INTWIDTH 64
243 #define SC_INTWIDTH 32
250 #if defined(_MSC_VER) && ( _MSC_VER < 1300 )
259 #if defined(_MSC_VER) && ( _MSC_VER < 1300 )
inline::std::ostream & operator<<(::std::ostream &os, const sc_fifo< T > &a)
::std::ios::fmtflags fmtflags
const uint64 UINT64_32ONES
const small_type NB_DEFAULT_BASE
inline::std::ostream & operator<<(::std::ostream &os, const sc_bit &a)