summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2007-09-12 18:07:14 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2007-09-12 18:07:14 +0000
commit7dddf8963ed5f99ce70452559e8bef74d07aa986 (patch)
tree3cfde02e33ec632c413a71adf283d6f5f14398dc
parent4aef188072cbe397021b7595cd7aa1df2b37ee90 (diff)
downloadATCD-7dddf8963ed5f99ce70452559e8bef74d07aa986.tar.gz
Wed Sep 12 18:02:38 UTC 2007 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r--ACE/ChangeLog20
-rw-r--r--ACE/ace/Atomic_Op.h3
-rw-r--r--ACE/ace/CDR_Base.cpp12
-rw-r--r--ACE/ace/CDR_Base.inl9
-rw-r--r--ACE/ace/WFMO_Reactor.h12
-rw-r--r--ACE/ace/config-g++-common.h4
-rw-r--r--ACE/ace/config-icc-common.h4
-rw-r--r--ACE/ace/config-win32-borland.h2
8 files changed, 46 insertions, 20 deletions
diff --git a/ACE/ChangeLog b/ACE/ChangeLog
index a38d31f83ba..68f8f624c86 100644
--- a/ACE/ChangeLog
+++ b/ACE/ChangeLog
@@ -1,3 +1,23 @@
+Wed Sep 12 18:02:38 UTC 2007 Johnny Willemsen <jwillemsen@remedy.nl>
+
+ * ace/config-win32-borland.h:
+ CodeGear RAD Studio 2007 doesn't seem to support inlined assembly
+
+ * ace/config-g++-common.h:
+ * ace/config-icc-common.h:
+ When we have pentium, AMD64, or EM64T as CPU define
+ ACE_HAS_INTEL_ASSEMBLY
+
+ * ace/Atomic_Op.h:
+ Simplified this file by using ACE_HAS_INTEL_ASSEMBLY
+
+ * ace/CDR_Base.{cpp.inl}:
+ Make use of ACE_HAS_INTEL_ASSEMBLY, this fixes bugzilla
+ issue 3072
+
+ * ace/WFMO_Reactor.h:
+ Doxygen fixes
+
Wed Sep 12 04:16:12 UTC 2007 Adam Mitz <mitza@ociweb.com>
* ACE-INSTALL.html:
diff --git a/ACE/ace/Atomic_Op.h b/ACE/ace/Atomic_Op.h
index 94c5031cee6..24abb64ef1d 100644
--- a/ACE/ace/Atomic_Op.h
+++ b/ACE/ace/Atomic_Op.h
@@ -41,9 +41,8 @@
# define ACE_HAS_BUILTIN_ATOMIC_OP
# endif /* _MSC_VER || __BORLANDC__ */
# endif /* ACE_HAS_INTERLOCKED_EXCHANGEADD */
-# elif (defined (__GNUC__) || defined (__INTEL_COMPILER)) && (defined (ACE_HAS_PENTIUM) || defined (__amd64__) || defined (__x86_64__))
+# elif defined (ACE_HAS_INTEL_ASSEMBLY)
# define ACE_HAS_BUILTIN_ATOMIC_OP
-# define ACE_HAS_INTEL_ASSEMBLY
# endif /* WIN32 */
#endif /* ACE_HAS_THREADS */
diff --git a/ACE/ace/CDR_Base.cpp b/ACE/ace/CDR_Base.cpp
index 600f6bbc9e1..eb6f0bb0514 100644
--- a/ACE/ace/CDR_Base.cpp
+++ b/ACE/ace/CDR_Base.cpp
@@ -34,7 +34,7 @@ ACE_CDR::swap_2_array (char const * orig, char* target, size_t n)
// Later, we try to read in 32 or 64 bit chunks,
// so make sure we don't do that for unaligned addresses.
#if ACE_SIZEOF_LONG == 8 && \
- !(defined(__amd64__) && defined(__GNUG__))
+ !((defined(__amd64__) || defined (__x86_64__)) && defined(__GNUG__))
char const * const o8 = ACE_ptr_align_binary (orig, 8);
while (orig < o8 && n > 0)
{
@@ -69,7 +69,7 @@ ACE_CDR::swap_2_array (char const * orig, char* target, size_t n)
// See if we're aligned for writting in 64 or 32 bit chunks...
#if ACE_SIZEOF_LONG == 8 && \
- !(defined(__amd64__) && defined(__GNUG__))
+ !((defined(__amd64__) || defined (__x86_64__)) && defined(__GNUG__))
if (target == ACE_ptr_align_binary (target, 8))
#else
if (target == ACE_ptr_align_binary (target, 4))
@@ -77,7 +77,7 @@ ACE_CDR::swap_2_array (char const * orig, char* target, size_t n)
{
while (orig < end)
{
-#if (defined (ACE_HAS_PENTIUM) || defined(__amd64__)) && defined (__GNUG__)
+#if defined (ACE_HAS_INTEL_ASSEMBLY)
unsigned int a =
* reinterpret_cast<const unsigned int*> (orig);
unsigned int b =
@@ -138,7 +138,7 @@ ACE_CDR::swap_2_array (char const * orig, char* target, size_t n)
// We're out of luck. We have to write in 2 byte chunks.
while (orig < end)
{
-#if (defined (ACE_HAS_PENTIUM) || defined(__amd64__)) && defined (__GNUG__)
+#if defined (ACE_HAS_INTEL_ASSEMBLY)
unsigned int a =
* reinterpret_cast<const unsigned int*> (orig);
unsigned int b =
@@ -294,7 +294,7 @@ ACE_CDR::swap_4_array (char const * orig, char* target, size_t n)
register unsigned long b =
* reinterpret_cast<const long*> (orig + 8);
-#if defined(__amd64__) && defined(__GNUC__)
+#if defined(ACE_HAS_INTEL_ASSEMBLY)
asm ("bswapq %1" : "=r" (a) : "0" (a));
asm ("bswapq %1" : "=r" (b) : "0" (b));
asm ("rol $32, %1" : "=r" (a) : "0" (a));
@@ -330,7 +330,7 @@ ACE_CDR::swap_4_array (char const * orig, char* target, size_t n)
register unsigned long b =
* reinterpret_cast<const long*> (orig + 8);
-#if defined(__amd64__) && defined(__GNUC__)
+#if defined(ACE_HAS_INTEL_ASSEMBLY)
asm ("bswapq %1" : "=r" (a) : "0" (a));
asm ("bswapq %1" : "=r" (b) : "0" (b));
asm ("rol $32, %1" : "=r" (a) : "0" (a));
diff --git a/ACE/ace/CDR_Base.inl b/ACE/ace/CDR_Base.inl
index 78e3f4e72b8..dd56d527144 100644
--- a/ACE/ace/CDR_Base.inl
+++ b/ACE/ace/CDR_Base.inl
@@ -73,7 +73,7 @@ ACE_CDR::swap_2 (const char *orig, char* target)
#elif defined (ACE_HAS_BSWAP_16)
*reinterpret_cast<unsigned short *> (target) =
bswap_16 (*reinterpret_cast<unsigned short const *> (orig));
-#elif (defined(ACE_HAS_PENTIUM) || defined (__amd64__)) && defined(__GNUG__)
+#elif defined(ACE_HAS_INTEL_ASSEMBLY)
unsigned short a =
*reinterpret_cast<const unsigned short*> (orig);
asm( "rolw $8, %0" : "=r" (a) : "0" (a) );
@@ -104,7 +104,7 @@ ACE_CDR::swap_4 (const char* orig, char* target)
#elif defined (ACE_HAS_BSWAP_32)
*reinterpret_cast<unsigned int *> (target) =
bswap_32 (*reinterpret_cast<unsigned int const *> (orig));
-#elif (defined(ACE_HAS_PENTIUM) || defined (__amd64__)) && defined(__GNUG__)
+#elif defined(ACE_HAS_INTEL_ASSEMBLY)
// We have ACE_HAS_PENTIUM, so we know the sizeof's.
register unsigned int j =
*reinterpret_cast<const unsigned int*> (orig);
@@ -136,7 +136,7 @@ ACE_CDR::swap_8 (const char* orig, char* target)
#elif defined (ACE_HAS_BSWAP_64)
*reinterpret_cast<unsigned long long *> (target) =
bswap_64 (*reinterpret_cast<unsigned long long const *> (orig));
-#elif defined(__amd64__) && defined(__GNUG__)
+#elif defined(ACE_HAS_INTEL_ASSEMBLY)
register unsigned long x =
* reinterpret_cast<const unsigned long*> (orig);
asm ("bswapq %1" : "=r" (x) : "0" (x));
@@ -224,8 +224,7 @@ ACE_CDR::first_size (size_t minsize)
ACE_INLINE size_t
ACE_CDR::next_size (size_t minsize)
{
- size_t newsize =
- ACE_CDR::first_size (minsize);
+ size_t newsize = ACE_CDR::first_size (minsize);
if (newsize == minsize)
{
diff --git a/ACE/ace/WFMO_Reactor.h b/ACE/ace/WFMO_Reactor.h
index fa516c6644d..5856af11c2f 100644
--- a/ACE/ace/WFMO_Reactor.h
+++ b/ACE/ace/WFMO_Reactor.h
@@ -966,10 +966,10 @@ public:
const ACE_Time_Value &interval = ACE_Time_Value::zero);
/**
- * Resets the interval of the timer represented by <timer_id> to
- * <interval>, which is specified in relative time to the current
- * <gettimeofday>. If <interval> is equal to
- * <ACE_Time_Value::zero>, the timer will become a non-rescheduling
+ * Resets the interval of the timer represented by @a timer_id to
+ * @a interval, which is specified in relative time to the current
+ * <gettimeofday>. If @a interval is equal to
+ * ACE_Time_Value::zero, the timer will become a non-rescheduling
* timer. Returns 0 if successful, -1 if not.
*/
virtual int reset_timer_interval (long timer_id,
@@ -981,12 +981,12 @@ public:
int dont_call_handle_close = 1);
/**
- * Cancel the single Event_Handler that matches the <timer_id> value
+ * Cancel the single Event_Handler that matches the @a timer_id value
* (which was returned from the schedule method). If arg is
* non-NULL then it will be set to point to the ``magic cookie''
* argument passed in when the Event_Handler was registered. This
* makes it possible to free up the memory and avoid memory leaks.
- * Returns 1 if cancellation succeeded and 0 if the <timer_id>
+ * Returns 1 if cancellation succeeded and 0 if the @a timer_id
* wasn't found.
*/
virtual int cancel_timer (long timer_id,
diff --git a/ACE/ace/config-g++-common.h b/ACE/ace/config-g++-common.h
index 4bfeee962d8..ef2c2a69e2d 100644
--- a/ACE/ace/config-g++-common.h
+++ b/ACE/ace/config-g++-common.h
@@ -62,6 +62,10 @@
# define ACE_HAS_PENTIUM
#endif /* i386 */
+#if (defined (ACE_HAS_PENTIUM) || defined (__amd64__) || defined (__x86_64__))
+# define ACE_HAS_INTEL_ASSEMBLY
+#endif
+
// GNU g++ >= 4.x implements "#pragma once".
#if (__GNUC__ < 4) && !defined (ACE_LACKS_PRAGMA_ONCE)
// We define it with a -D with make depend.
diff --git a/ACE/ace/config-icc-common.h b/ACE/ace/config-icc-common.h
index cbadf275362..d8e4a856c8c 100644
--- a/ACE/ace/config-icc-common.h
+++ b/ACE/ace/config-icc-common.h
@@ -88,6 +88,10 @@
# define ACE_HAS_PENTIUM
#endif /* i386 */
+#if (defined (ACE_HAS_PENTIUM) || defined (__amd64__) || defined (__x86_64__))
+# define ACE_HAS_INTEL_ASSEMBLY
+#endif
+
#if !defined (ACE_LACKS_PRAGMA_ONCE)
// We define it with a -D with make depend.
# define ACE_LACKS_PRAGMA_ONCE
diff --git a/ACE/ace/config-win32-borland.h b/ACE/ace/config-win32-borland.h
index fd0970e416f..69afe9370e5 100644
--- a/ACE/ace/config-win32-borland.h
+++ b/ACE/ace/config-win32-borland.h
@@ -103,7 +103,7 @@
#define ACE_HAS_NONCONST_TEMPNAM
-#if (__BORLANDC__ < 0x592)
+#if (__BORLANDC__ <= 0x592)
// Older Borland compilers can't handle assembly in inline methods or
// templates (E2211). When we build for pentium optimized and we are inlining
// then we disable inline assembly