|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r77477 - trunk/boost/context
From: oliver.kowalke_at_[hidden]
Date: 2012-03-22 12:05:56
Author: olli
Date: 2012-03-22 12:05:54 EDT (Thu, 22 Mar 2012)
New Revision: 77477
URL: http://svn.boost.org/trac/boost/changeset/77477
Log:
context: test macros for architecture enhanced
Text files modified:
trunk/boost/context/fcontext.hpp | 51 ++++++++++++++++++++++-----------------
1 files changed, 29 insertions(+), 22 deletions(-)
Modified: trunk/boost/context/fcontext.hpp
==============================================================================
--- trunk/boost/context/fcontext.hpp (original)
+++ trunk/boost/context/fcontext.hpp 2012-03-22 12:05:54 EDT (Thu, 22 Mar 2012)
@@ -7,6 +7,10 @@
#ifndef BOOST_CONTEXTS_FCONTEXT_H
#define BOOST_CONTEXTS_FCONTEXT_H
+#if defined(__PGI)
+#include <stdint.h>
+#endif
+
#include <boost/config.hpp>
#include <boost/cstdint.hpp>
@@ -16,37 +20,40 @@
# include BOOST_ABI_PREFIX
#endif
-// Windows
-#if defined(BOOST_WINDOWS)
// i386
-# if defined(_WIN32) && ! defined(_WIN64)
+#if defined(i386) || defined(__i386__) || defined(__i386) \
+ || defined(__i486__) || defined(__i586__) || defined(__i686__) \
+ || defined(__X86__) || defined(_X86_) || defined(__THW_INTEL__) \
+ || defined(__I86__) || defined(__INTEL__) || defined(__IA32__) \
+ || defined(_M_IX86) || defined(_I86_)
+# if defined(BOOST_WINDOWS)
# include <boost/context/detail/fcontext_i386_win.hpp>
-// x86_64
-# elif defined(_WIN32) && defined(_WIN64)
-# include <boost/context/detail/fcontext_x86_64_win.hpp>
# else
-# error "platform not supported"
-# endif
-// POSIX
-#else
-// i386
-# if defined(__i386__)
# include <boost/context/detail/fcontext_i386.hpp>
+# endif
// x86_64
-# elif defined(__x86_64__)
+#elif defined(__x86_64__) || defined(__x86_64) \
+ || defined(__amd64__) || defined(__amd64)
+# if defined(BOOST_WINDOWS)
+# include <boost/context/detail/fcontext_x86_64_win.hpp>
+# else
# include <boost/context/detail/fcontext_x86_64.hpp>
+# endif
// arm
-# elif defined(__arm__)
-# include <boost/context/detail/fcontext_arm.hpp>
+#elif defined(__arm__) || defined(__thumb__) || defined(__TARGET_ARCH_ARM) \
+ || defined(__TARGET_ARCH_THUMB) || defined(_ARM)
+# include <boost/context/detail/fcontext_arm.hpp>
// mips
-# elif defined(__mips__)
-# include <boost/context/detail/fcontext_mips.hpp>
+#elif (defined(__mips) && __mips == 1) || defined(_MIPS_ISA_MIPS1) \
+ || defined(_R3000)
+# include <boost/context/detail/fcontext_mips.hpp>
// powerpc
-# elif defined(__powerpc__)
-# include <boost/context/detail/fcontext_ppc.hpp>
-# else
-# error "platform not supported"
-# endif
+#elif defined(__powerpc) || defined(__powerpc__) || defined(__ppc) \
+ || defined(__ppc__) || defined(_ARCH_PPC) || defined(__POWERPC__) \
+ || defined(__PPCGECKO__) || defined(__PPCBROADWAY) || defined(_XENON)
+# include <boost/context/detail/fcontext_ppc.hpp>
+#else
+# error "platform not supported"
#endif
extern "C" {
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk