https://github.com/jeanPerier commented: Ah that ` if (user.index() > 2)` should have been ` if (user.index() > 1)`... (but your fix is better since it is better to still optimize this case). Thanks for the fix ! https://github.com/llvm/llvm-project/pull/201214