Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Assertion failure in btree::btree_node::construct_value #2

Open
smccauliff opened this issue Sep 24, 2020 · 0 comments
Open

Assertion failure in btree::btree_node::construct_value #2

smccauliff opened this issue Sep 24, 2020 · 0 comments

Comments

@smccauliff
Copy link

This appears to be from this line:
assert(memcmp(zero_value, v, sizeof(value_type)) == 0);

If a new value is being constructed why should it be zero initalized? Commenting out this assert causes segv later in the program.

__GI_raise 0x00007fedd5098f47
__GI_abort 0x00007fedd509a8b1
__assert_fail_base 0x00007fedd508a42a
__GI___assert_fail 0x00007fedd508a4a2
btree::btree_node<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::construct_value<std::pair<unsigned long const, app::MessageAndCoverCount> > btree.h:881
btree::btree_node<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::construct_value<std::pair<unsigned long const, app::MessageAndCoverCount> > btree.h:894
btree::btree_node<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::move_value btree.h:615
btree::btree_node<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::rebalance_right_to_left btree.h:1819
btree::btree<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::rebalance_or_split btree.h:2351
btree::btree<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::internal_emplace<std::piecewise_construct_t const&, std::tuple<unsigned long const&>, std::tuple<> >(btree::btree_iterator<btree::btree_node<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> > const, std::pair<unsigned long const, app::MessageAndCoverCount> const&, std::pair<unsigned long const, app::MessageAndCoverCount> const*>, std::piecewise_construct_t const&, std::tuple<unsigned long const&>&&, std::tuple<>&&) btree.h:2559
btree::btree<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> >::emplace_unique_key_args<std::piecewise_construct_t const&, std::tuple<unsigned long const&>, std::tuple<> >(unsigned long const&, std::piecewise_construct_t const&, std::tuple<unsigned long const&>&&, std::tuple<>&&) btree.h:2122
btree::btree_map_container<btree::btree<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> > >::try_emplace<>(unsigned long const&) map.h:70
btree::btree_map_container<btree::btree<btree::btree_map_params<unsigned long, app::MessageAndCoverCount, std::less, std::allocator<std::pair<unsigned long const, app::MessageAndCoverCount> >, 256> > >::operator[] map.h:118
app::CacheTest::PopulateCache test_cache.cpp:218

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant