mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-07 12:21:27 +01:00
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/18711 ghimport-source-id: c9caedc0660b2b7ba3730cd0e1a2e0e9c3cf422b Stack from [ghstack](https://github.com/ezyang/ghstack): * **#18711 [jit] fix side-effects and aliasing for custom ops** Previously we didn't track aliasing, mutation, or side effects for custom ops. This PR adds in guards with the most conservative assumptions possible: the op will 1) have side effects, 2) write to everything 3) produce a wildcard. In order to tell whether a given operator is a custom op, this PR introduces the concept of a "reserved" namespace (basically all our builtin namespaces). Custom ops live in non-reserved namespaces, so a check on the namespace is sufficient to tell whether a schema/node is "custom" or not. This is just to get things correct for now. Follow-ups to this: - Users should be able to specify aliasing/mutability without having to learn the whole alias annotation schema. - Relax assumptions a bit. In particular outputs can only alias input tensors, they don't have to be wildcards. Fixes #18490 Differential Revision: D14730978 fbshipit-source-id: 540b47a24ccf24145051609bdcc99c97e46e0fe0 |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| CMakeLists.txt | ||
| test_alias_analysis.h | ||
| test_argument_spec.h | ||
| test_autodiff.h | ||
| test_base.h | ||
| test_class_parser.h | ||
| test_code_template.h | ||
| test_constant_pooling.h | ||
| test_create_autodiff_subgraphs.h | ||
| test_custom_operators.h | ||
| test_dynamic_dag.h | ||
| test_fuser.h | ||
| test_graph_executor.h | ||
| test_interpreter.h | ||
| test_ir.h | ||
| test_irparser.h | ||
| test_ivalue.h | ||
| test_misc.h | ||
| test_netdef_converter.h | ||
| test_peephole_optimize.h | ||
| test_subgraph_utils.h | ||
| test_utils.h | ||
| test.cpp | ||
| tests_setup.py | ||