ATLAS Offline Software
Loading...
Searching...
No Matches
aligned_vector.h
Go to the documentation of this file.
1// This file's extension implies that it's C, but it's really -*- C++ -*-.
2/*
3 * Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration.
4 */
19
20
21#ifndef CXXUTILS_ALIGNED_VECTOR_H
22#define CXXUTILS_ALIGNED_VECTOR_H
23
24
25#include "boost/align/aligned_allocator.hpp"
26#include <vector>
27
28
29namespace CxxUtils {
30
31
38template <class T, size_t Alignment=1>
39using aligned_vector = std::vector<T, boost::alignment::aligned_allocator<T, Alignment> >;
40
41
50template <class T>
52
53
54} // namespace CxxUtils
55
56
57#endif // not CXXUTILS_ALIGNED_VECTOR_H
aligned_vector< T, 64 > vec_aligned_vector
A std::vector with alignment sufficient for any vector instructions on this platform.
std::vector< T, boost::alignment::aligned_allocator< T, Alignment > > aligned_vector
A std::vector with extra alignment.