[nnc] Merge inconsistent profiling information (#60510)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/60510
We encountered a situation where loop unrolling caused us to duplicate
profiled tensor types in a manner that wasn't logically consistent (see the
attached test case). When applying this profiling information, we need to
merge the profiled types so that we use a conservative (unspecialized) type.
ghstack-source-id: 132160002
Test Plan: new unit test, plus local predictor using P424983338
Reviewed By: Krovatkin
Differential Revision: D29322487
fbshipit-source-id: 4c18ee69c71bb0622c2e6f6aa361ab5613cbaca4