[llvm] [VectorCombine] Use InstSimplifyFolder to simplify instrs on creation. (PR #146350)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 30 07:43:08 PDT 2025


https://github.com/fhahn commented:

> InstSimplifyFolder is incompatible with setting instruction flags after the fact, so this code should be adjusted:
> 
> https://github.com/llvm/llvm-project/blob/2c60d7dfcfe7b52db7b563db8306a8ee569975b4/llvm/lib/Transforms/Vectorize/VectorCombine.cpp#L1465-L1468

Updated the code, but I had to create a new variant of `CreateOr`. Not sure if there's a nicer way to pass through possible flags to creation

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


More information about the llvm-commits mailing list