pytorch/test/jit
rzou 6412c6060c [reland] Refresh OpOverloadPacket if a new OpOverload gets added (#128000)
If a user accesses an OpOverloadPacket, then creates a new OpOverload,
then uses the OpOverloadPacket, the new OpOverload never gets hit. This
is because OpOverloadPacket caches OpOverloads when it is constructed.

This PR fixes the problem by "refreshing" the OpOverloadPacket if a new
OpOverload gets constructed and the OpOverloadPacket exists.

Test Plan:
- new tests

This is the third land attempt. The first one was reverted for breaking
internal tests, the second was reverted for being erroneously suspected
of causing a perf regression.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/128000
Approved by: https://github.com/albanD
2024-06-05 17:57:09 +00:00
..
_imported_class_test Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
fixtures
fixtures_srcs [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
xnnpack Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
__init__.py
mydecorator.py [torch] Use __prepare_scriptable__ for closures (#121553) 2024-03-11 19:14:19 +00:00
myexception.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
myfunction_a.py [torch] Use __prepare_scriptable__ for closures (#121553) 2024-03-11 19:14:19 +00:00
myfunction_b.py [torch] Use __prepare_scriptable__ for closures (#121553) 2024-03-11 19:14:19 +00:00
test_alias_analysis.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_async.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_aten_pow.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_attr.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_autodiff.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_autodiff_subgraph_slicing.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_await.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_backend_nnapi.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_backends.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_batch_mm.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_builtins.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_class_type.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_complex.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_complexity.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_convert_activation.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_cuda.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_custom_operators.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_data_parallel.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_dataclasses.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_dce.py
test_decorator.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_device_analysis.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_dtype_analysis.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_enum.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_exception.py [BE]: TRY002 - Ban raising vanilla exceptions (#124570) 2024-04-21 22:26:40 +00:00
test_freezing.py [BE] enable ruff rule RSE and remove useless parentheses in raise statements (#124261) 2024-04-17 19:29:34 +00:00
test_functional_blocks.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_fuser_common.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_generator.py
test_graph_rewrite_passes.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_hash.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_hooks.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_hooks_modules.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_ignorable_args.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_ignore_context_manager.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_isinstance.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_jit_utils.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_list_dict.py [reland] Refresh OpOverloadPacket if a new OpOverload gets added (#128000) 2024-06-05 17:57:09 +00:00
test_logging.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_misc.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_models.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_module_apis.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_module_containers.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_module_interface.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_modules.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_op_decompositions.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_optimize_for_mobile_preserve_debug_info.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_parametrization.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_pdt.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_peephole.py [BE]: TRY002 - Ban raising vanilla exceptions (#124570) 2024-04-21 22:26:40 +00:00
test_profiler.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_python_bindings.py
test_python_builtins.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_python_ir.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_recursive_script.py [1/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort stdlib (#127122) 2024-05-25 08:25:50 +00:00
test_remove_mutation.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_save_load.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_save_load_for_op_version.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_script_profile.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_scriptmod_ann.py [TorchScript] Expand TorchScript __init__ annotation warning (#127045) 2024-05-28 23:49:10 +00:00
test_slice.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_sparse.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_string_formatting.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_symbolic_shape_analysis.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_tensor_creation_ops.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_tensor_methods.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_torchbind.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_tracer.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_type_sharing.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_types.py [5/N][Easy] fix typo for usort config in pyproject.toml (kown -> known): sort torch (#127126) 2024-05-27 14:49:57 +00:00
test_typing.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_union.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_union_pep604.py
test_unsupported_ops.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_upgraders.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_warn.py Enable UFMT on all of test/jit (#123623) 2024-04-11 23:45:05 +00:00
test_with.py [BE]: TRY002 - Ban raising vanilla exceptions (#124570) 2024-04-21 22:26:40 +00:00