New issue
Advanced search Search tips

Issue 905535 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

'Waiting on a //base sync primitive is not allowed on this thread" - LevelDB

Project Member Reported by mpdenton@google.com, Nov 15

Issue description

It looks like the destructor of DBImpl waits on a condition variable, which is called on a disallowed thread. Backtrace:

base/debug/stack_trace_posix.cc:820
base/debug/stack_trace.cc:203
base/logging.cc:592
base/threading/thread_restrictions.cc:116
base/threading/scoped_blocking_call.cc:112
base/optional.h:70
base/optional.h:683
base/synchronization/condition_variable_posix.cc:70
third_party/leveldatabase/port/port_chromium.cc:40
third_party/leveldatabase/src/db/db_impl.cc:156
third_party/leveldatabase/src/db/db_impl.cc:151
buildtools/third_party/libc++/trunk/include/memory:2325
third_party/leveldatabase/env_chromium.cc:1332
buildtools/third_party/libc++/trunk/include/memory:2325
components/services/leveldb/leveldb_database_impl.cc:67
buildtools/third_party/libc++/trunk/include/memory:2325
mojo/public/cpp/bindings/strong_associated_binding.h:78
mojo/public/cpp/bindings/strong_associated_binding.h:113
base/bind_internal.h:516
base/bind_internal.h:616
base/bind_internal.h:689
base/bind_internal.h:671
base/callback.h:99
mojo/public/cpp/bindings/lib/interface_endpoint_client.cc:332
mojo/public/cpp/bindings/lib/multiplex_router.cc:789
mojo/public/cpp/bindings/lib/multiplex_router.cc:702
mojo/public/cpp/bindings/lib/multiplex_router.cc:611
mojo/public/cpp/bindings/lib/filter_chain.cc:40
mojo/public/cpp/bindings/lib/connector.cc:476
mojo/public/cpp/bindings/lib/connector.cc:505
mojo/public/cpp/bindings/lib/connector.cc:387
mojo/public/cpp/bindings/lib/connector.cc:364
base/bind_internal.h:516
base/bind_internal.h:616
base/bind_internal.h:689
base/bind_internal.h:671
base/callback.h:129
mojo/public/cpp/system/simple_watcher.h:194
base/bind_internal.h:416
base/bind_internal.h:616
base/bind_internal.h:689
base/bind_internal.h:671
base/callback.h:129
mojo/public/cpp/system/simple_watcher.cc:273
base/bind_internal.h:516
base/bind_internal.h:636
base/bind_internal.h:689
base/bind_internal.h:671
base/callback.h:99
base/debug/task_annotator.cc:99
base/task/task_scheduler/task_tracker.cc:641
base/task/task_scheduler/task_tracker_posix.cc:23
base/task/task_scheduler/task_tracker.cc:496
base/task/task_scheduler/scheduler_worker.cc:333
base/task/task_scheduler/scheduler_worker.cc:225
base/task/task_scheduler/scheduler_worker.cc:204
base/threading/platform_thread_posix.cc:81

Check failed: !g_base_sync_primitives_disallowed.Get().Get(). Waiting on a //base sync primitive is not allowed on this thread to prevent jank and deadlock. If waiting on a //base sync primitive is unavoidable, do it within the scope of a ScopedAllowBaseSyncPrimitives. If in a test, use ScopedAllowBaseSyncPrimitivesForTesting.

I'm guessing this isn't very important as it's primarily on shutdown, but the assertion adds to the noise.
 
I think you just need to add an allowance. If it's difficult to edit the third_party code here, this can probably just be ignored.
Status: Assigned (was: Untriaged)
This issue has an owner, a component and a priority, but is still listed as untriaged or unconfirmed. By definition, this bug is triaged. Changing status to "assigned". Please reach out to me if you disagree with how I've done this.

Sign in to add a comment