[llvm] [VPlan] Passing non-null instruction when creating VPReductionRecipe in unit test. NFC (PR #120053)

Elvis Wang via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 17 17:53:17 PST 2024


ElvisWang123 wrote:

> After recent changes to #120054 IIUC the patch won't be needed any longer?

Yes, not needed but good to have. 
Current structure of VPReductionRecipe is based on assumption of non-null underlying instruction.  (`print()` and `clone()`)
Testing with `nullptr` seems not that appropriate. 

An alternative implementation is that we could remove all underlying instruction dependency in VPReductionRecipe and not modify the unit test.

https://github.com/llvm/llvm-project/pull/120053


More information about the llvm-commits mailing list