>>> On 22.04.19 at 18:49, <julien.gr...@arm.com> wrote:
> The pattern _AC(1, UL{,L}) << X is commonly used in the headers to make
> define usuable in both assembly and C.
> 
> So introduce _BITUL and _BITULL to make the code slightly more readable.

I don't particularly like the names, and I specifically object to
the leading underscores. I'm afraid I don't have better
suggestions for the names, but what I'd like to ask for is that
at least the UL / ULL be somehow separated from BIT. One
option might be something like

#define BIT(pos, sfx) (_AC(1, sfx) << (pos))

albeit BIT may be a little too generic a name, yet something
like DEFINE_BIT looks a little longish. But at least it would also
allow e.g. plain unsigned (non-long) constants to be defined
without yet another new construct.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

Reply via email to