[Reland][DDP] log bucket sizes (#62625)
Summary:
Pull Request resolved: https://github.com/pytorch/pytorch/pull/62625
reland of https://github.com/pytorch/pytorch/pull/62232 which ran into a land race.
Test Plan: ci
Reviewed By: SciPioneer
Differential Revision: D30058217
fbshipit-source-id: 1454dd481e630f3de9ec6111b3f2e18cd8976091