On Thu, Mar 11, 2021 at 10:08 PM Tyler Retzlaff
<roret...@linux.microsoft.com> wrote:
>
> Avoid expanding v and mul parameters multiple times in the macro. based
> on usage of the macro it seems like side effects were not intended.
>
> For example:
>   ``return RTE_ALIGN_MUL_NEAR(rte_rdtsc() - start, CYC_PER_10MHZ);''

That's the beauty of macros.
How about updating the unit tests so that this kind of issue is not
reintroduced?


Are other RTE_ALIGN_* macro affected with similar issues?
Like mul expression passed to RTE_ALIGN_MUL_FLOOR and RTE_ALIGN_MUL_CEIL.


-- 
David Marchand

Reply via email to