Re: [PATCH v19 11/11] perf: arm_pmuv3: Add support for the Branch Record Buffer Extension (BRBE)
From: Leo Yan
Date: Wed Feb 12 2025 - 14:01:20 EST
On Wed, Feb 12, 2025 at 06:52:27PM +0000, Leo Yan wrote:
[...]
> > +static int brbinf_get_mispredict(u64 brbinf)
> > +{
> > + return FIELD_GET(BRBINFx_EL1_MPRED_MASK, brbinf);
> > +}
>
> I would expect the naming of brbinf_get_mispredict() will cause
> confusion. When the function returns 1, it means "Branch was
> incorrectly predicted".
>
> Maybe consider to use '!FIELD_GET(...)' for a reversed value?
Please ignore this comment. Sorry for my misreading and noise.