From 7e82f04c8037d5f8d2d9e8a0b46bc1a3c4f64717 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Fri, 2 Aug 2002 12:44:06 +0000 Subject: [PATCH] Add support for x86_64 CPU. --- ChangeLog | 7 +++++++ include/cln/config.h.in | 3 +++ include/cln/modules.h | 4 ++-- include/cln/object.h | 2 +- include/cln/types.h | 4 ++-- 5 files changed, 15 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index e649984..fef17e6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2002-08-03 Joerg Arndt + + * include/cln/config.h.in: Add support for x86_64 CPU. + * include/cln/modules.h: Likewise. + * include/cln/types.h: Likewise. + * include/cln/object.h: Likewise. + 2002-06-08 Richard Kreckel * src/base/digitseq/cl_asm.h: ensure intCsize==16 when including diff --git a/include/cln/config.h.in b/include/cln/config.h.in index f3e40f1..f4e9a9b 100644 --- a/include/cln/config.h.in +++ b/include/cln/config.h.in @@ -54,6 +54,9 @@ #ifndef __ia64__ #undef __ia64__ #endif +#ifndef __x86_64__ +#undef __x86_64__ +#endif #ifndef __s390__ #undef __s390__ #endif diff --git a/include/cln/modules.h b/include/cln/modules.h index 90addd2..c9cedb9 100644 --- a/include/cln/modules.h +++ b/include/cln/modules.h @@ -64,7 +64,7 @@ #endif // Globalize a label defined in the same translation unit. // See macro ASM_GLOBALIZE_LABEL in the gcc sources. - #if defined(__i386__) || defined(__m68k__) || defined(__mips__) || defined(__mips64__) || defined(__alpha__) || defined(__rs6000__) || defined(__s390__) + #if defined(__i386__) || defined(__m68k__) || defined(__mips__) || defined(__mips64__) || defined(__alpha__) || defined(__rs6000__) || defined(__x86_64__) || defined(__s390__) // Some m68k systems use "xdef" or "global" or ".global"... #define CL_GLOBALIZE_LABEL(label) __asm__("\t.globl " label); #endif @@ -117,7 +117,7 @@ // except that the latter inhibits inlining of the function containing it // in gcc-2.95. For new CPUs, look for "jump" and "indirect_jump" in gcc's // machine description. - #if defined(__i386__) + #if defined(__i386__) || defined(__x86_64__) #define CL_JUMP_TO(addr) ASM_VOLATILE("jmp %*%0" : : "rm" ((void*)(addr))) #endif #if defined(__m68k__) diff --git a/include/cln/object.h b/include/cln/object.h index b22e78f..ccfde56 100644 --- a/include/cln/object.h +++ b/include/cln/object.h @@ -25,7 +25,7 @@ namespace cln { #if defined(__i386__) || defined(__mips__) || defined(__sparc__) || defined(__hppa__) || defined(__arm__) || defined(__rs6000__) || defined(__m88k__) || defined(__convex__) || defined(__s390__) #define cl_word_alignment 4 #endif -#if defined(__alpha__) || defined(__mips64__) || defined(__sparc64__) || defined(__ia64__) +#if defined(__alpha__) || defined(__mips64__) || defined(__sparc64__) || defined(__ia64__) || defined(__x86_64__) #define cl_word_alignment 8 #endif #if !defined(cl_word_alignment) diff --git a/include/cln/types.h b/include/cln/types.h index 876ebcc..5075723 100644 --- a/include/cln/types.h +++ b/include/cln/types.h @@ -48,7 +48,7 @@ #undef HAVE_LONGLONG #endif #endif - #if defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__mips64__) || defined(__sparc64__) || defined(__ia64__)) + #if defined(HAVE_LONGLONG) && (defined(__alpha__) || defined(__mips64__) || defined(__sparc64__) || defined(__ia64__) || defined(__x86_64__)) // 64 bit registers in hardware #define HAVE_FAST_LONGLONG #endif @@ -85,7 +85,7 @@ #define signean_minus -1 // Integer type used for counters. - #if (defined(HAVE_FAST_LONGLONG) && (defined(__alpha__) || defined(__ia64__))) + #if (defined(HAVE_FAST_LONGLONG) && (defined(__alpha__) || defined(__ia64__) || defined(__x86_64__))) #define intCsize long_bitsize typedef long sintC; typedef unsigned long uintC;