diff options
author | dos-reis <gdr@axiomatics.org> | 2012-02-03 11:21:00 +0000 |
---|---|---|
committer | dos-reis <gdr@axiomatics.org> | 2012-02-03 11:21:00 +0000 |
commit | d36c43d159d39a847ef8728e5da201bb29e747f5 (patch) | |
tree | 06befc858ccc2912afd67fc705f64e568a6e7a16 /config | |
parent | a00d32a888a910fe517afb91cc48a6eb44ed58da (diff) | |
download | open-axiom-d36c43d159d39a847ef8728e5da201bb29e747f5.tar.gz |
* config/open-axiom.m4 (OPENAXIOM_ALIGNAS_SPECIFIER): New.
(OPENAXIOM_CHECK_MISC): Use it.
src/
* utils/vm.H: Add more VM data structures.
* utils/vm.cc (BasicContext::make_operator): Define.
* algebra/Makefile.in (SPADFILES): Include syntax.spad and
spad-parser.spad.
Diffstat (limited to 'config')
-rw-r--r-- | config/open-axiom.m4 | 22 | ||||
-rw-r--r-- | config/openaxiom-c-macros.h.in | 3 |
2 files changed, 24 insertions, 1 deletions
diff --git a/config/open-axiom.m4 b/config/open-axiom.m4 index f8e632f9..f3c8afd5 100644 --- a/config/open-axiom.m4 +++ b/config/open-axiom.m4 @@ -1006,12 +1006,31 @@ AC_COMPILE_IFELSE([int a = __alignof(int);], [oa_alignment="__alignof"], [AC_COMPILE_IFELSE([int a = alignof(int);], [oa_alignment="alignof"], - [AC_MSG_ERROR([C/C++ compiler does not support alignment query operator])])]) + [AC_MSG_ERROR([C++ compiler does not support alignment query operator])])]) AC_DEFINE_UNQUOTED([openaxiom_alignment],[$oa_alignment], [Alignment query operator]) AC_MSG_RESULT([$oa_alignment]) ]) +dnl --------------------------------- +dnl -- OPENAXIOM_ALIGNAS_SPECIFIER -- +dnl --------------------------------- +dnl check for alignment specifier support. +dnl Vendor lock-ins are of the attribute form. +AC_DEFUN([OPENAXIOM_ALIGNAS_SPECIFIER],[ +AC_MSG_CHECKING([alignment boundary specifier syntax]) +oa_alignas= +AC_COMPILE_IFELSE([alignas(16) int a = 42;], + [oa_alignas="alignas(N)"], + [AC_COMPILE_IFELSE([__attribute__((__aligned__(16))) int a = 42;], + [oa_alignas="__attribute__((__aligned__(N)))"], + [AC_MSG_ERROR([C++ compiler does not support alignment specifier])])]) +AC_DEFINE_UNQUOTED([openaxiom_alignas(N)],[$oa_alignas], + [Alignment specifier operator]) +AC_MSG_RESULT([$oa_alignas]) +]) + + dnl ------------------------- dnl -- OPENAXIOM_CHECK_GMP -- dnl ------------------------- @@ -1025,6 +1044,7 @@ dnl -- OPENAXIOM_CHECK_MISC -- dnl -------------------------- AC_DEFUN([OPENAXIOM_CHECK_MISC],[ OPENAXIOM_ALIGNMENT_OPERATOR +OPENAXIOM_ALIGNAS_SPECIFIER case $oa_gnu_compiler in yes) CFLAGS="$CFLAGS -O2 -Wall" diff --git a/config/openaxiom-c-macros.h.in b/config/openaxiom-c-macros.h.in index 1f9f1bc8..41805ba4 100644 --- a/config/openaxiom-c-macros.h.in +++ b/config/openaxiom-c-macros.h.in @@ -274,6 +274,9 @@ if such a type exists, and if the system does not define it. */ #undef intptr_t +/* Alignment specifier operator */ +#undef openaxiom_alignas + /* Alignment query operator */ #undef openaxiom_alignment |