[dynamo] Minifier fixes for reproducing segfault (#89712)
Helped with minifying the segfault in https://github.com/pytorch/torchdynamo/issues/1928
Tests not really needed. It improves quality of life as segfault can fail anywhere (when CUDA_LAUNCH_BLOCKING is off)
Pull Request resolved: https://github.com/pytorch/pytorch/pull/89712
Approved by: https://github.com/mlazos, https://github.com/ngimel