Skip to content

sporadic crash with aligned_allocator_adaptor with libc++ #23

@jcelerier

Description

@jcelerier

I have a std::vector<boost::aligned_allocator_adaptor<QPointF, 32>> which occasionnally crashes on destruction.
QPointF is basically struct { double x, y; }

#0 0x7b185afe6c1f in boost::alignment::aligned_allocator_adaptor<std::__1::allocator<QPointF>, 32ul>::deallocate(QPointF*, unsigned long) /usr/include/boost/align/aligned_allocator_adaptor.hpp:144:22
#1 0x7b185afe645c in std::__1::allocator_traits<boost::alignment::aligned_allocator_adaptor<std::__1::allocator<QPointF>, 32ul>>::deallocate[abi:ne200100](boost::alignment::aligned_allocator_adaptor<std::__1::allocator<QPointF>, 32ul>&, QPointF*, unsigned long) /usr/bin/../include/c++/v1/__memory/allocator_traits.h:302:9
#2 0x7b185afe623f in std::__1::vector<QPointF, boost::alignment::aligned_allocator_adaptor<std::__1::allocator<QPointF>, 32ul>>::__destroy_vector::operator()[abi:ne200100]() /usr/bin/../include/c++/v1/__vector/vector.h:250:9
#3 0x7b185afe49fa in std::__1::vector<QPointF, boost::alignment::aligned_allocator_adaptor<std::__1::allocator<QPointF>, 32ul>>::~vector[abi:ne200100]() /usr/bin/../include/c++/v1/__vector/vector.h:259:67

ASAN stack trace looks like this ^

normal std::allocator works fine, as well as boost::aligned_allocator directly

boost 1.88

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions