From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f46.google.com (mail-wm0-f46.google.com [74.125.82.46]) by dpdk.org (Postfix) with ESMTP id 100D75A95 for ; Fri, 27 May 2016 17:05:47 +0200 (CEST) Received: by mail-wm0-f46.google.com with SMTP id n129so141064837wmn.1 for ; Fri, 27 May 2016 08:05:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=TQwG5UL+0DnPKrqbGsgFhmDUbBcc75zOPeIvRfmxih4=; b=eghwuY11AVPbh22Jg2J4aQVKkGmspl91FfFxXXsQ+BPkKJTVPmMCfXOLJRmMSpY0uW RvzVobygAs60AvZH6Vs1yzq/RmNVi9QcGZSuXk+gieXbroHLtytjPMGwXJ+vq/i2zLz3 pjfsOGfnT3JxYTKyLAJ+7hWuLOTmZEGp7cRPFo3IGZqAssfeP59/kw9fVkGyS+9e49+y 5mURCgLZFOO8Cb5Ubzc5oFphzXgVbk3TbwIcROQDkZSuPMmHtKKG9JPUWMNJhXLCp+kk qGVk1+buc5qL1iCAPerORc7QHwALLGa1kYb4vG8WW8w1/7lWdUuBHDJa7eHLHENIa+iC kJtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=TQwG5UL+0DnPKrqbGsgFhmDUbBcc75zOPeIvRfmxih4=; b=RVKOOwJXUvZYUrdbJVO8+SEPbnZpaqtHfN+QrncNYmC+WvBGAQNq55SGsqkdioXkki AlEn3QGbSO5A/4++CVfgZzR+ta4vtYhmzE7Hf82dGoVZ38MzyHGADa007WPbEnHy+MiZ xaxna8H0Z15onejhrSOQEIkUWftIuAcAT5oa4g+5dkCJKPFIaFfQH2rMakkI2ZUlTxOT fmCPeY7cz2uo9xutve98My5d8zlTqXTvQCHauYpvyEyK0miP6RLKdioVz3PGGJP6/jI9 QBzoDVasJzYaipSXWTpxmn4tMq1ODCdr9pgZJ37gu6nGJNW0eWocB51mlRmbGaTE5+DD bI3g== X-Gm-Message-State: ALyK8tIzHsody23t16pRUBmtLu1DTHPgVB85FqwYN4GWzTArfEmJYrDw8P1sVSF20sIZLXDr X-Received: by 10.28.148.136 with SMTP id w130mr9718254wmd.10.1464361546680; Fri, 27 May 2016 08:05:46 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id on2sm19825744wjc.32.2016.05.27.08.05.45 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 27 May 2016 08:05:45 -0700 (PDT) From: Thomas Monjalon To: Jerin Jacob Cc: "Hunt, David" , Olivier Matz , dev@dpdk.org, bruce.richardson@intel.com, konstantin.ananyev@intel.com Date: Fri, 27 May 2016 17:05:45 +0200 Message-ID: <4125316.GWKk7IhZzc@xps13> User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <20160527114205.GA15118@localhost.localdomain> References: <1464101442-10501-1-git-send-email-jerin.jacob@caviumnetworks.com> <57482079.1050605@intel.com> <20160527114205.GA15118@localhost.localdomain> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH] mbuf: replace c memcpy code semantics with optimized rte_memcpy 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: Fri, 27 May 2016 15:05:47 -0000 2016-05-27 17:12, Jerin Jacob: > IMHO, I think we should have means to abstract this _logical_ changes > under conditional compilation flags and any arch/platform can choose > to select what it suites better for that arch/platform. > > We may NOT need to have frequent patches to select the specific > configuration, but logical patches under compilation flags can be accepted and > each arch/platform can choose specific set configuration when we make > the final release candidate for the release. > > Any thoughts? Yes having some #ifdefs for arch configuration may be reasonnable. But other methods must be preffered first: 1/ try implementing the function in arch-specific files 2/ and check at runtime if (rte_cpu_get_flag_enabled(RTE_CPUFLAG_X 3/ or check #ifdef RTE_MACHINE_CPUFLAG_X 4/ or check #ifdef RTE_ARCH_Y 5/ or check a specific #ifdef RTE_FEATURE_NAME to choose in config files The option 2 is a nice to have which implies other options. Maybe that doc/guides/contributing/design.rst needs to be updated.