mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
[dynamo][compile-time] Cache whether a function is inlineable (#153192)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/153192 Approved by: https://github.com/StrongerXi, https://github.com/jansel, https://github.com/williamwen42 ghstack dependencies: #153458
This commit is contained in:
committed by
PyTorch MergeBot
parent
e2ce17c6ef
commit
11c64b7cf8
@ -1372,6 +1372,7 @@ def clear_instruction_args(instructions):
|
||||
inst.arg = None
|
||||
|
||||
|
||||
@functools.lru_cache
|
||||
def get_code_keys() -> list[str]:
|
||||
# Python 3.11 changes to code keys are not fully documented.
|
||||
# See https://github.com/python/cpython/blob/3.11/Objects/clinic/codeobject.c.h#L24
|
||||
|
Reference in New Issue
Block a user