pytorch/torch/_dynamo/variables
Ryan Guo 9eb0520d75 [dynamo] Fix side-effect handling for pre-existing collections.deque (#141714)
Previously we never replayed side effects to `DequeVariable` with a
source; the bug was already in the `test_deque_input` test, but went
unnoticed because we didn't check the deque objects.

This patch adds limited but practical support for this (see comments in
`side_effects.py` for why limited), and updates the deque tests to check
for this.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/141714
Approved by: https://github.com/jansel
ghstack dependencies: #141713
2024-12-03 09:18:06 +00:00
..
__init__.py [dynamo][NFC] Rename NewCellVariable to CellVariable (#141628) 2024-12-02 19:09:30 +00:00
base.py [dynamo] Enforce some invariants on ConstantVariable.create (#140984) 2024-11-27 21:58:35 +00:00
builder.py [dynamo] Fix side-effect handling for pre-existing collections.deque (#141714) 2024-12-03 09:18:06 +00:00
builtin.py [dynamo] match implementation for sorted(...) with CPython (#141227) 2024-11-24 20:01:50 +00:00
constant.py [dynamo] Enforce some invariants on ConstantVariable.create (#140984) 2024-11-27 21:58:35 +00:00
ctx_manager.py [BE]: Apply PERF401 autofixes from ruff (#140980) 2024-11-20 17:52:07 +00:00
dicts.py Only reconstruct dict if needed (#141606) 2024-12-03 02:22:34 +00:00
distributed.py [dynamo] Fix VariableBuilder._wrap on frozenset and enforce invariants on ConstantVariable (#141504) 2024-11-27 21:58:35 +00:00
functions.py [dynamo] Fix VariableBuilder._wrap on frozenset and enforce invariants on ConstantVariable (#141504) 2024-11-27 21:58:35 +00:00
higher_order_ops.py [hop] add discard_graph_changes to remove the empty calls before hop (#140334) 2024-11-26 17:32:43 +00:00
iter.py [BE]: Apply PERF401 autofixes from ruff (#140980) 2024-11-20 17:52:07 +00:00
lazy.py [dynamo] Replace __str__ with __repr__ in some places (#136316) 2024-10-21 19:50:38 +00:00
lists.py [dynamo] Fix VariableBuilder._wrap on frozenset and enforce invariants on ConstantVariable (#141504) 2024-11-27 21:58:35 +00:00
misc.py [dynamo] Remove AutoDerefLocalSource and simplify cell handling (#141629) 2024-12-02 19:09:30 +00:00
nn_module.py [user-empathy-day][dynamo] Remove speical casing for torch.nn.Parameter tracing (#141209) 2024-11-21 21:18:42 +00:00
optimizer.py Ensure index for state guard construction is a source (#140515) 2024-11-15 22:02:50 +00:00
script_object.py Add basic mypy annotations to dynamo (#132415) 2024-08-04 18:43:36 +00:00
sdpa.py [dynamo] Simplify creation of VariableTrackers (#135714) 2024-10-18 09:36:46 +00:00
tensor.py [dynamo] Support is comparison for symnodes (#140754) 2024-11-19 00:19:33 +00:00
torch_function.py [dynamo] Simplify creation of VariableTrackers (#135714) 2024-10-18 09:36:46 +00:00
torch.py [dynamo] Restrict support for out= variants of torch operators (#140202) 2024-11-13 03:14:23 +00:00
user_defined.py [user empathy day][dynamo] Support get on subclassed dicts (#141214) 2024-11-21 21:18:42 +00:00