[ET Trac] [Einstein Toolkit] #2207: support all of C++11 in Cactus or the Einstein Toolkit
Einstein Toolkit
trac-noreply at einsteintoolkit.org
Mon Oct 15 20:18:40 CDT 2018
#2207: support all of C++11 in Cactus or the Einstein Toolkit
---------------------------------+-------------------------
Reporter: Roland Haas | Type: enhancement
Status: new | Priority: minor
Milestone: | Component: Cactus
Version: development version | Keywords:
---------------------------------+-------------------------
We are currently allowing a subset of C++11 to be used in Cactus and the
Einstein Toolkit. Looking at configure.in the supported features are:
* the auto specifier
* C++ lambdas
* C++ range based for
To support all interesting features one would need at least icpc 15 as
well as g++ 4.8 and clang 3.3.
== Compiler support ==
The major compilers provide the following information on the features they
support:
* [[http://en.cppreference.com/w/cpp/compiler_support|Overview on
cppreference.com]]
* [[http://software.intel.com/en-us/articles/c0x-features-supported-by-
intel-c-compiler|Features supported by Intel compilers]]
* [[http://gcc.gnu.org/projects/cxx0x.html|Features supported by gcc
compilers]]
* [[http://clang.llvm.org/cxx_status.html|Features supported by clang
compilers]]
This summarizes the specific C++11 **language** features.
|| ||= Description =||= GCC version =||= Intel version =||=
Clang version =||= Notes =||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2008/n2672.htm|N2672]] =|| initializer
lists || 4.4 || 14.0 || 3.1 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Initializer_lists|(1)]]
[[http://en.wikipedia.org/wiki/C%2B%2B11#Uniform_initialization|(2)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2242.pdf|N2242]] \\ [[http://www
.open-std.org/jtc1/sc22/wg21/docs/papers/2008/n2555.pdf|N2552]] =||
variadic templates || 4.3 \\ 4.4 || 12.1 || 2.9 || Wikipedia:
[[http://en.wikipedia.org/wiki/Variadic_template|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2004/n1737.pdf|N1737]] \\ [[http://www
.open-std.org/jtc1/sc22/wg21/docs/papers/2006/n1984.pdf|N1984]] =||
''auto'' type || 4.4 || 12.0 || 2.9 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Type_inference|(1)]] ||
||= [[http://www.open-
std.org/JTC1/SC22/WG21/docs/papers/2009/n2930.html|N2930]] =|| range-based
for loops || 4.6 || 13.0 || 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Range-based_for_loop|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2431.pdf|N2431]] =|| ''nullptr''
constant || 4.6 || 12.1 || 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Null_pointer_constant|(1)]] ||
||= [[http://www.open-
std.org/JTC1/SC22/WG21/docs/papers/2009/n2927.pdf|N2927]] =|| lambda
functions || 4.5 || 12.0 || 3.1 || Wikipedia:
[[http://en.wikipedia.org/wiki/Anonymous_function#C.2B.2B_.28since_C.2B.2B11.29|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2010/n3052.html|N3052]] =|| lambda
function conversions || ? || 13.0 || ? || ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2008/n2761.pdf|N2761]] =|| standardized
attributes || 4.8 || 12.1 || 3.3 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Attributes|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2006/n1986.pdf|N1986]] =|| delegating
constructors || 4.7 || 14.0 || 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Object_construction_improvement|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2006/n2118.html|N2118]] =|| rvalue
references || 4.3 || 12.0 || 2.9 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Rvalue_references_and_move_constructors|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2346.htm|N2346]] =|| defaulted
and deleted methods || 4.4 || 12.0 || 2.9, 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Explicitly_defaulted_and_deleted_special_member_functions|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2442.htm|N2442]] =|| raw string
literals || 4.5 || 14.0 || 3.0 || Stackoverflow:
[[http://stackoverflow.com/a/5460235|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2235.pdf|N2235]] =|| generalized
constant expressions || 4.6 || 14.0 || 3.1 || Wikipedia:
[[http://en.wikipedia.org/wiki/C++11#constexpr_.E2.80.93_Generalized_constant_expressions|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2343.pdf|N2343]] \\ [[http://www
.open-std.org/jtc1/sc22/wg21/docs/papers/2011/n3276.pdf|N3276]] =||
declared type of an expression || 4.3 \\ 4.8.1 || 12.0 || 2.9 \\ 3.1 ||
Wikipedia: [[http://en.wikipedia.org/wiki/Decltype|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2437.pdf|N2437]] =|| explicit
conversion operators || 4.5 || 13.0 || 3.0 || Stroustrup 4th edition,
18.4.2 ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2005/n1757.html|N1757]] =|| right angle
brackets || 4.3 || 11.1 || 2.9 || ''>>'' for template arguments ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2011/n3272.htm|N3272]] =|| override and
final || 4.7 || 14.0 || 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Explicit_overrides_and_final|(1)]]
||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2258.pdf|N2258]] =|| template
aliases || 4.7 || 12.1 || 3.0 || Wikipedia:
[[http://en.wikipedia.org/wiki/C%2B%2B11#Alias_templates|(1)]] ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2010/n3053.html|N3053]] =|| move
special member functions || 4.6 || 14.0 || 3.0 || ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2008/n2659.htm|N2659]] =|| thread-local
storage || 4.8 || 15.0 || 3.3 || ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2341.pdf|N2341]] =|| Alignment
support || 4.8 || 15.0 || 3.3 || ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2008/n2756.htm|N2756]] =|| Non-static
data member initializers || 4.7 || 14.0 || 3.0 || ||
||= [[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2007/n2347.pdf|N2347 ]] || Strongly-
typed enums || 4.4 || 14.0 || 2.9 || ||
This summarizes the specific C++11 **library** features.
||= Description =||= libstdc++ version =||= libc++ version =||= Notes
=||
|| ''std::begin'', ''std::end'' || 4.5 || * || ||
|| smart pointers || <4.5 || * || Wikipedia:
[[http://en.wikipedia.org/wiki/Smart_pointer#C.2B.2B_smart_pointers|(1)]]
\\ Conversion between smart pointers to convertible types is not supported
until libstdc++-4.6.1 ||
|| ''std::map::emplace'' || 4.8 || || ||
|| ''std::vector::emplace'' || <4.5 || * || ||
|| ''<regex>'' || 4.9 || || cplusplus.com:
[[http://www.cplusplus.com/reference/regex/|(1)]] ||
|| ''<type_traits>'' || <4.5 || || cplusplus.com:
[[http://www.cplusplus.com/reference/type_traits/|(1)]] ||
|| ''<chrono>'' || 4.4 || || Stroustrup 4th edition ||
|| ''<atomic>'' || 4.5 || || cplusplus.com:
[[http://www.cplusplus.com/reference/atomic/|(1)]] \\
std::atomic::exchange does not compile for pointer types with Intel 13
(works with Intel 14) ||
|| ''std::array'' || <4.6 || || ||
|| ''std::to_string'' || || || ||
|| ''std::unordered_map'' || || || || ||
|| ''std::function'' || <=4.6 || || ||
* First version unknown; libc++ claims [[http://libcxx.llvm.org/index.html
#dir-structure|full support]] for all C++11 features.\\
See the
[[https://gcc.gnu.org/onlinedocs/gcc-4.6.4/libstdc++/manual/manual/status.html#status.iso.200x|libstdc++-4.6.4
documentation]] (under 20.9.4.3) for a list of unsupported traits.
--
Ticket URL: <https://trac.einsteintoolkit.org/ticket/2207>
Einstein Toolkit <http://einsteintoolkit.org>
The Einstein Toolkit
More information about the Trac
mailing list