[dpdk-dev] [PATCH 2/2] bitmap: deprecate and rename rte_bsf64

Thomas Monjalon thomas at monjalon.net
Thu Nov 22 23:44:50 CET 2018


22/11/2018 19:56, Ananyev, Konstantin:
> > Rename rte_bsf64 to rte_bsf64_safe (this is a "safe" version in
> > that it prevents undefined behavior by checking if incoming
> > parameter is zero) and move it to common header.
> 
> Probably a stupid one: why to rename?
> Why just not fix rte_bsf64 to make it work with zero value,
> and keep the same function name?

Because there are different parameters and returned value
than rte_bsf32.
In the next release, we will have rte_bsf64 function,
behaving as rte_bsf32.
This is explained in the deprecation notice.

[...]
> > +static inline int
> > +rte_bsf64_safe(uint64_t v, uint32_t *pos)






More information about the dev mailing list