pytorch/torch/_functorch
Tugsbayasgalan Manlaibaatar 6096c0fc74 Export should use aot_export_joint_with_descriptors (#165931)
This diff moves export run_decompositions to use aot_export_joint_with_descriptors instead of aot_export_module. Doing so, i ran into 2 main bugs:
1) aot_export_joint_with_descriptors don't correctly pass in record_nn_module_stack flag that is needed to populate nn_module_stack by switching the internal tracer.
2) When creating symint with negative inputs, we need to pass in positive=False. This didn't matter before because aot_autograd directly returns integer inputs instead of creating symint.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/165931
Approved by: https://github.com/zhxchen17
2025-10-27 19:33:33 +00:00
..
_activation_checkpointing [5/N] Apply ruff UP035 rule (#164423) 2025-10-02 07:31:11 +00:00
_aot_autograd Export should use aot_export_joint_with_descriptors (#165931) 2025-10-27 19:33:33 +00:00
__init__.py
aot_autograd.py Export should use aot_export_joint_with_descriptors (#165931) 2025-10-27 19:33:33 +00:00
apis.py [BE][PYFMT] migrate PYFMT for torch/_[a-h]*/ to ruff format (#144551) 2025-06-25 06:16:06 +00:00
autograd_function.py Add pyrefly suppressions (3/n) (#164588) 2025-10-03 22:03:03 +00:00
batch_norm_replacement.py
benchmark_utils.py [BE][PYFMT] migrate PYFMT for torch/_[a-h]*/ to ruff format (#144551) 2025-06-25 06:16:06 +00:00
compile_utils.py [5/N] Apply ruff UP035 rule (#164423) 2025-10-02 07:31:11 +00:00
compilers.py [1/N] Use "is" in python type comparison (#165037) 2025-10-10 12:36:50 +00:00
config.py add the option to disable functionalization in AOTDispatcher (#164577) 2025-10-16 15:44:11 +00:00
deprecated.py [5/N] Apply ruff UP035 rule (#164423) 2025-10-02 07:31:11 +00:00
eager_transforms.py [5/N] Apply ruff UP035 rule (#164423) 2025-10-02 07:31:11 +00:00
functional_call.py [2/N] Use "is" in python type comparison (#165142) 2025-10-10 15:36:44 +00:00
fx_minifier.py [5/N] Apply ruff UP035 rule (#164423) 2025-10-02 07:31:11 +00:00
make_functional.py [2/N] Use "is" in python type comparison (#165142) 2025-10-10 15:36:44 +00:00
partitioners.py [RFC] Add pyrefly to lintrunner (#165179) 2025-10-16 20:07:09 +00:00
predispatch.py [scan x vmap] support scan in vmap (#165580) 2025-10-22 09:46:00 +00:00
pyfunctorch.py Add pyrefly suppressions (3/n) (#164588) 2025-10-03 22:03:03 +00:00
python_key.py
pytree_hacks.py
top_operators_github_usage.py [BE][PYFMT] migrate PYFMT for torch/_[a-h]*/ to ruff format (#144551) 2025-06-25 06:16:06 +00:00
utils.py
vmap.py Fix self assignment (#165816) 2025-10-18 18:51:52 +00:00