Skip to content

torch._C._IncludeDispatchKeyGuard is very broken? #145108

@zou3519

Description

@zou3519
import torch

print(torch._C._meta_in_tls_dispatch_include())
with torch._C._IncludeDispatchKeyGuard(torch.DispatchKey.Meta):
    print(torch._C._meta_in_tls_dispatch_include())
print(torch._C._meta_in_tls_dispatch_include())

prints False, True, True, which is completely bogus

Metadata

Metadata

Assignees

No one assigned

    Labels

    module: dispatchDispatchStub, Type, void pointer table, c10 dispatchtriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions