ATLAS Offline Software
Loading...
Searching...
No Matches
ArenaBlockAlignDetail.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3*/
4
16
17#ifndef ATLALLOCATORS__ARENABLOCKALIGNDETAIL
18#define ATLALLOCATORS__ARENABLOCKALIGNDETAIL
19
20#include <cstddef>
21namespace SG {
23
25 // gcc and clang seem to define this
26 // But not the same way ...
27 // gcc provides 16,32,64 as we change arch
28 // clang seem to provide 16 always...
29 // From the nature of the Block Header (other elements total size 24)
30 // 16 vs 32 costs the same in space overhead.
31 // So minimum 32
32#if defined(__BIGGEST_ALIGNMENT__) && (__BIGGEST_ALIGNMENT__ > 32)
33 alignas(__BIGGEST_ALIGNMENT__) double dummy;
34#else
35 alignas(32) double dummy;
36#endif
37};
38
39constexpr size_t alignment = std::alignment_of<padForAlign>::value;
40
41} // namespace ArenaBlockAlignDetail
42} // namespace SG
43#endif
Forward declaration.