[llvm] [TableGen] Enhance testability of TableGen-based macro fusion (PR #73075)
Wang Pengcheng via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 21 21:11:10 PST 2023
wangpc-pp wrote:
> Could we have tblgen autogenerate the macrofusion bits onto the end of the existing subtarget feature bits and autogenerate `has*()` functions for them like other subtarget features. It seems like we're now duplicating some of the -mattr functionality.
Yes, I was thinking about making `Fusion` inherit from `SubtargetFuture` so that we can reuse current `-mattr` mechanism. My concern is that `MAX_SUBTARGET_FEATURES` is 320 now and there are more 170 subtarget features in RISCV (270 for AArch64, 223 for ARM and 183 for X86). For the foreseeable future, RISCV, as a modular ISA, may have more than 320 features. We may need to increase `MAX_SUBTARGET_FEATURES` in the near future if we add macrofusion bits to subtarget feature bits.
But it may not be a big problem, I will post another patch for this solution.
https://github.com/llvm/llvm-project/pull/73075
More information about the llvm-commits
mailing list