https://github.com/lenary approved this pull request. I'm happy with how this works and fixes the issue. I think this should also be backported to the release branch, as I think it will affect a lot of tests that use `-Oz`. https://github.com/llvm/llvm-project/pull/127659