From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 71DD97D36 for ; Wed, 23 Aug 2017 16:47:32 +0200 (CEST) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 23 Aug 2017 07:47:31 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.41,417,1498546800"; d="scan'208";a="127404982" Received: from txasoft-yocto.an.intel.com (HELO txasoft-yocto.an.intel.com.) ([10.123.72.111]) by orsmga002.jf.intel.com with ESMTP; 23 Aug 2017 07:47:30 -0700 From: Gabriel Carrillo To: rsanford@akamai.com Cc: dev@dpdk.org Date: Wed, 23 Aug 2017 09:47:21 -0500 Message-Id: <1503499644-29432-1-git-send-email-erik.g.carrillo@intel.com> X-Mailer: git-send-email 1.7.10 Subject: [dpdk-dev] [PATCH 0/3] *** timer library enhancements *** X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Aug 2017 14:47:32 -0000 In the current implementation of the DPDK timer library, timers can be created and set to be handled by a target lcore by adding it to a skiplist that corresponds to that lcore. However, if an application enables multiple lcores, and each of these lcores repeatedly attempts to install timers on the same target lcore, overall application throughput will be reduced as all lcores contend to acquire the lock guarding the single skiplist of pending timers. This patchset addresses this scenario by adding an array of skiplists to each lcore's priv_timer struct, such that when lcore i installs a timer on lcore k, the timer will be added to the ith skiplist for lcore k. If lcore j installs a timer on lcore k simultaneously, lcores i and j can both proceed since they will be acquiring different locks for different lists. When lcore k processes its pending timers, it will traverse each skiplist in its array and acquire a skiplist's lock while a run list is broken out; meanwhile, all other lists can continue to be modified. Then, all run lists for lcore k are collected and traversed together so timers are executed in their global order. Gabriel Carrillo (3): timer: add per-installer pending lists for each lcore timer: handle timers installed from non-EAL threads doc: update timer lib docs doc/guides/prog_guide/timer_lib.rst | 19 ++- lib/librte_timer/rte_timer.c | 329 +++++++++++++++++++++++------------- lib/librte_timer/rte_timer.h | 9 +- 3 files changed, 231 insertions(+), 126 deletions(-) -- 2.6.4