Fix more JIT tests under Python-3.9 (#51182)
Summary:
Mostly replace `global Foo` with `make_global(Foo)`
The only real fix is generating Subscript annotation, which is a follow up from https://github.com/pytorch/pytorch/pull/48676
Fixes https://github.com/pytorch/pytorch/issues/49617
Pull Request resolved: https://github.com/pytorch/pytorch/pull/51182
Reviewed By: gmagogsfm
Differential Revision: D26095244
Pulled By: malfet
fbshipit-source-id: 0e043d9a2cf43fff71dfbb341f708cd7af87c39a