Dont introduce aliasing in CSE or Constant Pooling (#19576)
authoreellison <elias_ellison@brown.edu>
Wed, 24 Apr 2019 03:31:36 +0000 (20:31 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Wed, 24 Apr 2019 03:39:09 +0000 (20:39 -0700)
commitd902774cadd085c89bd27391d1a3c5a8488235de
tree76297df7952ebc9c7a60b2d57267e632f968c5a7
parentba1cf3871862b2ab5681c2a0e66ad22c7795e806
Dont introduce aliasing in CSE or Constant Pooling (#19576)

Summary:
We can't introduce aliasing to a graph output, since they may be mutated after.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/19576

Differential Revision: D15057734

Pulled By: eellison

fbshipit-source-id: 33594c05d985a0c58edebd6252e1ee2c0efb6f0e
test/cpp/jit/test_alias_analysis.h
test/cpp/jit/test_constant_pooling.h
test/test_jit.py
torch/csrc/jit/autodiff.cpp
torch/csrc/jit/passes/alias_analysis.cpp
torch/csrc/jit/passes/alias_analysis.h
torch/csrc/jit/passes/common_subexpression_elimination.cpp
torch/csrc/jit/passes/constant_pooling.cpp
torch/csrc/jit/passes/create_autodiff_subgraphs.cpp
torch/csrc/jit/passes/utils/memory_dag.cpp
torch/csrc/jit/passes/utils/memory_dag.h