Skip to content

HandleUsingDestroyedMutex assert can occur on Impeller/Vulkan if a command is submitted after shutdown of the FenceWaiter #187703

Closed

Description

@jason-simmons

One way to reproduce this:

  • Run Gallery on Android with Impeller/Vulkan using a host_debug_unopt build
  • Go to the Shrine demo
  • Scroll quickly though the images
  • Use the Android back gesture to suspend the app before all of the images have been decoded and displayed

On a Pixel 6a, the Mali Vulkan implementation may abort with a call to HandleUsingDestroyedMutex that triggers an assert:
Abort message: 'FORTIFY: pthread_mutex_lock called on a destroyed mutex (0xb4000074243e87c4)

This happens because CommandQueueVK::Submit submitted a command buffer with a fence that is then passed to FenceWaiterVK::AddFence. But AddFence fails because the FenceWaiterVK was terminated during engine shutdown.

AddFence then destroys the fence, but the Vulkan implementation still associates the fence with the command buffer. The assert then happens when the command buffer completes and attempts to signal the destroyed fence.

Activity

  1. added
    in triagePresently being triaged by the triage team
    engineflutter/engine related. See also e: labels.
    e: impellerImpeller rendering backend issues and features requests
    platform-androidAndroid applications specifically
    and removed
    in triagePresently being triaged by the triage team
    on Jun 9, 2026
  2. added
    P1High-priority issues at the top of the work list
    on Jun 15, 2026
  3. github-actions commented on Jul 14, 2026

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  4. locked as resolved and limited conversation to collaborators on Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High-priority issues at the top of the work liste: impellerImpeller rendering backend issues and features requestsengineflutter/engine related. See also e: labels.platform-androidAndroid applications specificallyteam-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions