[llvm] [TableGen] Add a bitvector of members of CodeGenRegisterClass (PR #149122)

Jason Eckhardt via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 16 09:30:06 PDT 2025


nvjle wrote:

> I tried measuring peak memory usage using:
> 
> ```
> /usr/bin/time -v llvm-tblgen -gen-register-info -I include -I lib/Target/AMDGPU lib/Target/AMDGPU/AMDGPU.td
> ```
> 
> I couldn't measure any increase from this patch. The results fluctuate by around +/- 0.1% anyway so I guess it is lost in the noise.

The new patch appears obviously faster (and definitely cleaner), but you might also try using `TGTimer` to measure any compile-time difference for this area of code. FWIW, I've also applied the patch locally to a downstream back-end with a register hierarchy that is similarly complicated to AMDGPU (or worse), and all is well.

LGTM.

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


More information about the llvm-commits mailing list