[jit] Add support for dynamic shape fusion in JIT. (#69474)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/69474
This diff adds support for dynamic shape fusion in JIT. This is done
by performing fusion with the static shapes observed on the first run,
generalizing the fused subgraphs and generating code for the generalized fused
subgraphs with dynamic shapes.
ghstack-source-id: 146059044
Test Plan:
```
buck test mode/dev-nosan //caffe2/test/cpp/jit:jit
```
Reviewed By: eellison
Differential Revision: D32781307
fbshipit-source-id: f821d9f8c271bcb78babcb4783d66f2f0020b0ea