On Fri, Jun 30, 2023 at 08:45:38PM +0800, Kito Cheng wrote: > Hmmm, I think maybe what we need is to leverage C++ language features > to declare enum with underlying types like that: > > enum machine_mode : uint16_t
What would be the advantage of doing that? I mean, on most hosts using unsigned rather than unsigned short is actually faster, and for the cases where we care about the size (e.g. mode in RTL, DECLs and the like) we already use enum bitfields. Jakub