[dynamo] config guard cache size limit#111145
[dynamo] config guard cache size limit#111145jon-chuang wants to merge 29 commits intopytorch:mainfrom
Conversation
…uang/global-config-guard
…uang/global-config-guard
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/111145
Note: Links to docs will display an error until the docs builds have been completed. ✅ No FailuresAs of commit e925c25 with merge base 918054f ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
This PR needs a
|
|
@pytorchbot label "release notes: dynamo" |
|
since this isn't stacked I can't easily review it, removing from queue for now |
|
@ezyang would it be possible to get branch creation permission on this repo? Running ghstack: |
|
i sent you a gh invite |
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
--- Fixes: #110682 Replaces: #111074 The guards are installed based on config that is valid at the call to `torch.compile`, rather than at any subsequent call / triggered compilation. Subsequent compilations will restore the config if there is a config mismatch with the saved config. TODO: - [X] add tests Follow up PRs: - [x] add revised cache size computation (follow up PR: #111145, based on: #107496) - [ ] handle run-only mode? - [ ] config restoration itself is not thread-safe (tracked: #111150) cc voznesenskym ezyang Chillee [ghstack-poisoned]
Follow up to: #111074
CacheEntry are stored on f's
__code__object. We simply change the way of counting the cache size limitcc @voznesenskym @ezyang @Chillee