renlin added a comment. @hfinkel , I have updated the patch as you suggested, and in the latest comment, I showed an artificial test case which could be improved by the change. Do you think you would be able to review this? thanks! https://reviews.llvm.org/D47816