ktkachov wrote: I'm not familiar enough with the LLVM code here to tell if this is a problem, but this transform is only valid if the NZCV output of WHILELE is unused, right? Otherwise it'd have to fold to PTRUES https://github.com/llvm/llvm-project/pull/111183