[v8,0/1] New software event timer adapter
mbox series

Message ID 1560961558-26005-1-git-send-email-erik.g.carrillo@intel.com
Headers show
Series
  • New software event timer adapter
Related show

Message

Carrillo, Erik G June 19, 2019, 4:25 p.m. UTC
This patch introduces a new version of the event timer adapter software
PMD [1]. In the original design, timer event producer lcores in the primary
and secondary processes enqueued event timers into a ring, and a service
core in the primary process dequeued them and processed them further.  To
improve performance, this version does away with the ring and lets lcores in
both primary and secondary processes insert timers directly into timer
skiplist data structures; the service core directly accesses the lists as
well, when looking for timers that have expired.

[1] https://doc.dpdk.org/guides/prog_guide/event_timer_adapter.html

Changes in v8:
 - I generated the v7 patch from the wrong commit, so the first two bullets
   listed in the v7 changes below were not included.  This version includes
   them.

Changes in v7:
 - Remove unecessary lock protecting array of lcore ids whose timer lists
   should be processed in service function, and the count of elements
   in that array.
 - When adding rte_timers to a buffer to be freed later, first check if
   the buffer is full and empty it before adding a new element.
 - Update commit log with command used to compare performance, and
   amount of improvement seen. (Jerin)

Changes in v6:
 - Fix implicit type conversion bug that caused full event buffer to 
   sometimes not be correctly detected, resulting in lost events
 - Check return value of alt_timer_reset when resetting timer in event
   buffer full condition
 - Add timer list corresponding to service core to set of lists to scan
   when timers are reset by service core in event buffer full condition

Changes in v5:
 - Rebase patch to apply with latest timer library
 - Fix event buffering bug where full buffer was treated as empty
 - Return rte_timer objects back to mempool after service function has
   returned from timer_manage() call instead of in callback

Changes in v4:
 - Addressed the following comments from Mattias Ronnblom:
   - remove unnecessary header include
   - add missing read barrier in timer cancel function

Changes in v3:
 - Addressed comments from Mattias Ronnblom:
   - remove unnecessary header include
   - remove unnecessary cast in mempool_put() call
   - update alignment of elements of array to avoid false sharing issue

Changes in v2:
 - split this change out into its own patch series

Erik Gabriel Carrillo (1):
  eventdev: add new software event timer adapter

 lib/librte_eventdev/rte_event_timer_adapter.c | 734 +++++++++++---------------
 1 file changed, 315 insertions(+), 419 deletions(-)