Architecture related Types and Helpers.
This module defines the types and helpers functions to properly handle architecture specific components
Namespaces | |
| namespace | platform |
| Platform specific constexpr information. | |
Macros | |
| #define | EVE_ABI_NAMESPACE |
| Expands to an identifier that is unique to the current compilation configuration. | |
| #define | EVE_NAMESPACE namespace eve |
| namespace eve::inline EVE_ABI_NAMESPACE. | |
| #define EVE_ABI_NAMESPACE |
Expands to an identifier that is unique to the current compilation configuration.
Defined in Header
The identifier depends on the instruction sets and EVE options used to compile, for example abi_O for -march=haswell -DNDEBUG. It is kept short on purpose and is not meant to be read.
EVE uses it as the name of an inline namespace, so that multiple versions of the same code, compiled with different configurations, can be linked into one binary without causing ODR violations. ODR violations can still come from other namespaces, but EVE's own symbols mostly shouldn't cause them.
You can choose the name yourself by defining EVE_ABI_NAMESPACE before including EVE. If you give the same name to translation units compiled with different options, keeping them apart is then up to you.
To protect your own code that depends on compilation options in the same way, put it in an inline namespace named after the same macro:
| #define EVE_NAMESPACE namespace eve |