[0/2] ring: empty optimization
mbox series

Message ID 20200519152725.63486-1-mb@smartsharesystems.com
Headers show
Series
  • ring: empty optimization
Related show

Message

Morten Brørup May 19, 2020, 3:27 p.m. UTC
Testing if the ring is empty is as simple as comparing the producer and
consumer pointers.

Checkpatch complains about existing coding style violations, so the first
part of the patch fixes those, and contains no functional changes.

Morten Brørup (2):
  ring: coding style cleanup
  ring: empty optimization

 lib/librte_ring/rte_ring.c      |  4 +--
 lib/librte_ring/rte_ring.h      | 46 +++++++++++++++++----------------
 lib/librte_ring/rte_ring_elem.h | 10 +++----
 lib/librte_ring/rte_ring_hts.h  |  8 +++---
 lib/librte_ring/rte_ring_rts.h  |  8 +++---
 5 files changed, 39 insertions(+), 37 deletions(-)

Comments

David Marchand July 1, 2020, 9:20 a.m. UTC | #1
On Tue, May 19, 2020 at 5:27 PM Morten Brørup <mb@smartsharesystems.com> wrote:
>
> Testing if the ring is empty is as simple as comparing the producer and
> consumer pointers.
>
> Checkpatch complains about existing coding style violations, so the first
> part of the patch fixes those, and contains no functional changes.
>
> Morten Brørup (2):
>   ring: coding style cleanup
>   ring: empty optimization
>
>  lib/librte_ring/rte_ring.c      |  4 +--
>  lib/librte_ring/rte_ring.h      | 46 +++++++++++++++++----------------
>  lib/librte_ring/rte_ring_elem.h | 10 +++----
>  lib/librte_ring/rte_ring_hts.h  |  8 +++---
>  lib/librte_ring/rte_ring_rts.h  |  8 +++---
>  5 files changed, 39 insertions(+), 37 deletions(-)
>
> --
> 2.17.1
>

Series applied, thanks.