214 |
|
|
215 |
#define EMMS() |
#define EMMS() |
216 |
|
|
217 |
|
#ifdef __GNUC__ |
218 |
|
|
219 |
// needed for bitstream.h |
// needed for bitstream.h |
220 |
#define BSWAP(a) __asm__ __volatile__ ("mux1 %1 = %0, @rev" \ |
#define BSWAP(a) __asm__ __volatile__ ("mux1 %1 = %0, @rev" \ |
221 |
";;" \ |
";;" \ |
232 |
|
|
233 |
} |
} |
234 |
|
|
235 |
|
/* we are missing our ia64intrin.h file, but according to the |
236 |
|
Intel's ecc manual, this should be the right way ... |
237 |
|
this |
238 |
|
|
239 |
|
#elif defined(__INTEL_COMPILER) |
240 |
|
|
241 |
|
#include <ia64intrin.h> |
242 |
|
|
243 |
|
static __inline int64_t read_counter() { |
244 |
|
return __getReg(44); |
245 |
|
} |
246 |
|
|
247 |
|
#define BSWAP(a) ((unsigned int) (_m64_mux1(a, 0xb) >> 32)) |
248 |
|
*/ |
249 |
|
|
250 |
|
#else |
251 |
|
|
252 |
|
// needed for bitstream.h |
253 |
|
#define BSWAP(a) \ |
254 |
|
((a) = ( ((a)&0xff)<<24) | (((a)&0xff00)<<8) | (((a)>>8)&0xff00) | (((a)>>24)&0xff)) |
255 |
|
|
256 |
|
// rdtsc command most likely not supported, |
257 |
|
// so just dummy code here |
258 |
|
static __inline int64_t |
259 |
|
read_counter() |
260 |
|
{ |
261 |
|
return 0; |
262 |
|
} |
263 |
|
|
264 |
|
#endif // gcc or ecc |
265 |
|
|
266 |
#else |
#else |
267 |
#define BSWAP(a) __asm__ ( "bswapl %0\n" : "=r" (a) : "0" (a) ) |
#define BSWAP(a) __asm__ ( "bswapl %0\n" : "=r" (a) : "0" (a) ) |
268 |
#define EMMS() __asm__("emms\n\t") |
#define EMMS() __asm__("emms\n\t") |