[libcxx-commits] [PATCH] D132092: [2a/3][ASan][libcxx] std::deque annotations
Tacet via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Sun May 7 21:39:03 PDT 2023
AdvenamTacet added a comment.
It looks like the problem was created when I added `__annotate_whole_block`. Example buildbot output relevant for this revision: https://lab.llvm.org/buildbot/#/builders/5/builds/33480/steps/13/logs/stdio
==296484==ERROR: AddressSanitizer: bad parameters to __sanitizer_annotate_double_ended_contiguous_container:
storage_beg : 0x6210000d0d00
storage_end : 0x6210000d1d00
old_container_beg : 0x6210000d1b40
old_container_end : 0x6210000d1d00
new_container_beg : 0x6210000d1b40
new_container_end : 0x6210000d0d00
#0 0x56178e14cac5 in __sanitizer_annotate_double_ended_contiguous_container /b/sanitizer-x86_64-linux-fast/build/llvm-project/compiler-rt/lib/asan/asan_poisoning.cpp:499:5
#1 0x56178efd3474 in __annotate_double_ended_contiguous_container /b/sanitizer-x86_64-linux-fast/build/libcxx_build_asan/include/c++/v1/deque:893:13
#2 0x56178efd3474 in __annotate_from_to /b/sanitizer-x86_64-linux-fast/build/libcxx_build_asan/include/c++/v1/deque:991:13
#3 0x56178efd3474 in __annotate_whole_block /b/sanitizer-x86_64-linux-fast/build/libcxx_build_asan/include/c++/v1/deque:1037:9
#4 0x56178efd3474 in std::__1::deque<std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>, std::__1::allocator<std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>>>::__add_back_capacity() /b/sanitizer-x86_64-linux-fast/build/libcxx_build_asan/include/c++/v1/deque:2233:13
#5 0x56178efd1aaf in std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>& std::__1::deque<std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>, std::__1::allocator<std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>>>::emplace_back<std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>>(std::__1::pair<std::__1::function<void ()>, llvm::ThreadPoolTaskGroup*>&&) /b/sanitizer-x86_64-linux-fast/build/libcxx_build_asan/include/c++/v1/deque:1596:9
[...]
All errors I could find seem to have an origin in `__add_back_capacity` and I'm almost sure that I see a problem in the function.
I am trying to create unit test catching it and then I will send the next update with fix and tests.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132092/new/
https://reviews.llvm.org/D132092
More information about the libcxx-commits
mailing list