avoid unnecessary copies in MultiDispatchKeySet (#60093)
Summary:
The code would previously pass Generator & optional<Tensor> by value.
Pull Request resolved: https://github.com/pytorch/pytorch/pull/60093
Reviewed By: swolchok
Differential Revision: D29310624
Pulled By: bhosmer
fbshipit-source-id: fb4a9740a57ef319aaf7c778d51430907a7c0cc5