Migrate kernels with Tensor? to C10 full dispatcher (#54263)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/54263
Codemod commands generated by https://github.com/pytorch/pytorch/pull/54223
Signatures of the following 8 methods in LegacyTHFunctionsCUDA.h are
manually changed.
```
_thnn_multi_margin_loss_forward
_thnn_multi_margin_loss_backward
_thnn_nll_loss_forward
_thnn_nll_loss_backward
_thnn_nll_loss2d_forward
_thnn_nll_loss2d_backward
_thnn_conv2d_forward
_thnn_conv_depthwise2d_forward
```
ghstack-source-id: 124539990
Test Plan: buck build //caffe2/aten/...
Reviewed By: smessmer
Differential Revision: D27164092
fbshipit-source-id: 59062179ffd958ca253cbf63fdd495799b9a9586