Remove hacked twins from codegen (#36666)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/36666
We need to introduce hacked twin overloads for ops taking lists of optional tensors.
I'm not really sure why actually, but them being a special case in codegen blocks removal of `use_c10_dispatcher: unboxed_only`.
This PR does not remove the "hacked twin" hack, but it removes it from codegen, instead manually specifying them in register_prim_ops.cpp and unblocking removal of `use_c10_dispatcher: unboxed_only`.
Original commit changeset: c5e2386ad06a
ghstack-source-id: 102507901
Test Plan: waitforsandcastle
Differential Revision: D21044962
fbshipit-source-id: 9d423aac08a1dd2bab54940ccb6219ebdcb7d230