[TableGen] Add `countRendererFns` to `InstructionOperandMatcher`
authorPierre van Houtryve <pierre.vanhoutryve@amd.com>
Thu, 29 Sep 2022 08:11:09 +0000 (08:11 +0000)
committerPierre van Houtryve <pierre.vanhoutryve@amd.com>
Fri, 30 Sep 2022 07:26:30 +0000 (07:26 +0000)
commit6886f094e8af1a4db31c22678f431f0c45dac781
tree541a95c88379a5deafad1010ab5382dd4d272631
parent924996e0a011eb833a72d2a2cac9b40fa8a42e34
[TableGen] Add `countRendererFns` to `InstructionOperandMatcher`

Without it, the count of renderer functions is inaccurate and, in some
edge cases (like the patterns added in D134354), we can actually
go out of bounds (run out of pre-allocated renderer function spaces
in the GISel state)

Reviewed By: arsenm

Differential Revision: https://reviews.llvm.org/D134861
llvm/test/TableGen/GlobalISelEmitter.td
llvm/utils/TableGen/GlobalISelEmitter.cpp