[llvm] [GlobalISel][TableGen] Take first result for multi-output instructions (PR #81130)

Sergei Barannikov via llvm-commits llvm-commits at lists.llvm.org
Sun Feb 11 06:09:55 PST 2024


s-barannikov wrote:

@bjope 

Thanks for the example, I didn't notice the added test. It indeed looks like that you're addressing a different issue than mine. Unfortunately :slightly_smiling_face: 

> Are you sure that the pattern really works as intended with SDagISel?

Yes, I'm pretty sure. I was surprised that it works, but it does, and is very handy. I'm selecting all ALU instructions this way with no custom C++ code.
The support is built around `CodeGenInstruction::HasOneImplicitDefWithKnownVT()` somehow. I tried to port this approach to GISel but couldn't finish the job quickly and switched to another task.


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


More information about the llvm-commits mailing list