Add xlogy and xlog1py references (#77712)
* Add reference implementations for `xlogy` and `xlog1py`
* Replace `_wrap_scalar` helper function with `scalar_tensor` prim
Pull Request resolved: https://github.com/pytorch/pytorch/pull/77712
Approved by: https://github.com/mruberry