From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58]) by dpdk.org (Postfix) with ESMTP id 8C6B52E8B for ; Tue, 2 Sep 2014 15:38:38 +0200 (CEST) Received: from hmsreliant.think-freely.org ([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost) by smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1XOoMP-0008U1-78; Tue, 02 Sep 2014 09:43:09 -0400 Date: Tue, 2 Sep 2014 09:43:00 -0400 From: Neil Horman To: Konstantin Ananyev Message-ID: <20140902134300.GC29416@hmsreliant.think-freely.org> References: <1409585324-6829-1-git-send-email-konstantin.ananyev@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1409585324-6829-1-git-send-email-konstantin.ananyev@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) X-Spam-Score: -2.9 (--) X-Spam-Status: No Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCHv5] librte_acl make it build/work for 'default' target X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Sep 2014 13:38:38 -0000 On Mon, Sep 01, 2014 at 04:28:44PM +0100, Konstantin Ananyev wrote: > Make ACL library to build/work on 'default' architecture: > - make rte_acl_classify_scalar really scalar > (make sure it wouldn't use sse4 instrincts through resolve_priority()). > - Provide two versions of rte_acl_classify code path: > rte_acl_classify_sse() - could be build and used only on systems with sse4.2 > and upper, return -ENOTSUP on lower arch. > rte_acl_classify_scalar() - a slower version, but could be build and used > on all systems. > - keep common code shared between these two codepaths. > > v2 chages: > run-time selection of most appropriate code-path for given ISA. > By default the highest supprted one is selected. > User can still override that selection by manually assigning new value to > the global function pointer rte_acl_default_classify. > rte_acl_classify() becomes a macro calling whatever rte_acl_default_classify > points to. > > V3 Changes > Updated classify pointer to be a function so as to better preserve ABI > REmoved macro definitions for match check functions to make them static inline > > V4 Changes > Rewrote classification selection mechanim to use a function table, so that we > can just store the preferred alg in the rte_acl_ctx struct so that multiprocess > access works. I understand that leaves us with an extra load instruction, but I > think thats ok, because it also allows... > > Addition of a new function rte_acl_classify_alg. This function lets you > specify an enum value to override the acl contexts default algorith when doing a > classification. This allows an application to specify a classification > algorithm without needing to pulicize each method. I know there was concern > over keeping those methods public, but we don't have a static ABI at the moment, > so this seems to me a reasonable thing to do, as it gives us less of an ABI > surface to worry about. > > Fixed misc missed static declarations > Removed acl_match_check.h and moved match_check function to acl_run.h > typdeffed function pointer to match check. > > V5 Changes > Updated examples/l3fwd-acl to comply with latest changes. > Applied other code review comments (mostly style changes). > > Signed-off-by: Konstantin Ananyev Acked-by: Neil Horman Thanks Konstantin! Neil