https://github.com/AviadCo commented: I am not sure the fix is correct, Please see my comments. I suggest to block the transformation in such case instead as this is not fully safe or maintain the signess of the loops in another way. https://github.com/llvm/llvm-project/pull/223256