From patchwork Tue Jan 5 15:29:32 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mike Holmes X-Patchwork-Id: 59196 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp6033245lbb; Tue, 5 Jan 2016 07:31:43 -0800 (PST) X-Received: by 10.140.167.86 with SMTP id n83mr50453584qhn.41.1452007871768; Tue, 05 Jan 2016 07:31:11 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id c69si96935356qkb.11.2016.01.05.07.31.09; Tue, 05 Jan 2016 07:31:11 -0800 (PST) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 91DA6615E7; Tue, 5 Jan 2016 15:31:09 +0000 (UTC) Authentication-Results: lists.linaro.org; dkim=fail reason="verification failed; unprotected key" header.d=linaro.org header.i=@linaro.org header.b=Od2ueKQq; dkim-adsp=none (unprotected policy); dkim-atps=neutral X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,T_DKIM_INVALID,URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id F418A61777; Tue, 5 Jan 2016 15:29:53 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 5D97C6176D; Tue, 5 Jan 2016 15:29:46 +0000 (UTC) Received: from mail-qg0-f47.google.com (mail-qg0-f47.google.com [209.85.192.47]) by lists.linaro.org (Postfix) with ESMTPS id AC0DA610AE for ; Tue, 5 Jan 2016 15:29:43 +0000 (UTC) Received: by mail-qg0-f47.google.com with SMTP id o11so280501453qge.2 for ; Tue, 05 Jan 2016 07:29:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=bHlWzoflEZ7xiBnHCQByD5XF/pe41qhLbXVJd9jQh9o=; b=Od2ueKQqx048PL0h297jQKqarexIIxnm0ZiK7B7KxoiFbQqrqJJFPbg38OIYq4BrH5 okYCpa+mvkYokMOqlP5G/0qcQ9NcOXiiQkPVjNPCoMkLy1IB97I2NXyj0zCzpoc4atPx EF75Lm+EbsbWiWoTm9KFyjNV287z+pxtyOF2E= 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:in-reply-to :references; bh=bHlWzoflEZ7xiBnHCQByD5XF/pe41qhLbXVJd9jQh9o=; b=UwFROWw8W5bOHHpQP7tq2IEqEbIG1JtZqJOG5wIdVur4gmyV0r0XUi+VBhS/T1Z3JZ lm4BdMgbZUTGgVEFULtIBPpD/Hf7kLHweAhkHgPMXCa7TQZKoWGMeC1FR8dQ82b/+My/ if9eAblHLm8ssyXvJHoSsoYkgItn6NtfDl3fTyGjSakVul9xJGpnFXT+OiimCvV7cs2/ zWoHPSzZaoRRMZxFCHAflGj1UATzfkCtAXa0Qxls8myr1WISXrTHMGAKWeFUVAgxJ8au pOGWt6/7tJJpDf0oiD0l599eZN39eHgimovo36gFLbop8zt9Ezz2SCA9nAqes81jTgBh bJ2w== X-Gm-Message-State: ALoCoQm+4ixFIh85Bf2IEnf1QrBr8vSaBl4zu1MSlKTkhPA9BTVidWPkEILHedKevr/BqHLSS0CPgr8t7KuLvkuBO545MyuAeA== X-Received: by 10.140.234.17 with SMTP id f17mr132873446qhc.19.1452007783450; Tue, 05 Jan 2016 07:29:43 -0800 (PST) Received: from localhost.localdomain (c-98-221-136-245.hsd1.nj.comcast.net. [98.221.136.245]) by smtp.gmail.com with ESMTPSA id w14sm42157266qge.24.2016.01.05.07.29.42 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 05 Jan 2016 07:29:43 -0800 (PST) From: Mike Holmes To: lng-odp@lists.linaro.org Date: Tue, 5 Jan 2016 10:29:32 -0500 Message-Id: <1452007772-11744-3-git-send-email-mike.holmes@linaro.org> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1452007772-11744-1-git-send-email-mike.holmes@linaro.org> References: <1452007772-11744-1-git-send-email-mike.holmes@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH 2/2] linux-generic: test: add performance test framework X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Add infrastructure for platform dependent performance testing. Added scheduler performance test using process mode. Signed-off-by: Mike Holmes --- platform/linux-generic/m4/configure.m4 | 1 + platform/linux-generic/test/Makefile.am | 4 ++++ .../linux-generic/test/performance/Makefile.am | 13 +++++++++++ .../test/performance/odp_scheduling_proc_run | 25 ++++++++++++++++++++++ .../test/performance/tests-performance.env | 3 +++ 5 files changed, 46 insertions(+) create mode 100644 platform/linux-generic/test/performance/Makefile.am create mode 100755 platform/linux-generic/test/performance/odp_scheduling_proc_run create mode 100644 platform/linux-generic/test/performance/tests-performance.env diff --git a/platform/linux-generic/m4/configure.m4 b/platform/linux-generic/m4/configure.m4 index 97c15fa..82b7c5e 100644 --- a/platform/linux-generic/m4/configure.m4 +++ b/platform/linux-generic/m4/configure.m4 @@ -23,5 +23,6 @@ m4_include([platform/linux-generic/m4/odp_pcap.m4]) AC_CONFIG_FILES([platform/linux-generic/Makefile platform/linux-generic/test/Makefile + platform/linux-generic/test/performance/Makefile platform/linux-generic/test/validation/Makefile platform/linux-generic/test/validation/pktio/Makefile]) diff --git a/platform/linux-generic/test/Makefile.am b/platform/linux-generic/test/Makefile.am index 3cf638d..7fe79c9 100644 --- a/platform/linux-generic/test/Makefile.am +++ b/platform/linux-generic/test/Makefile.am @@ -4,6 +4,10 @@ if test_vald SUBDIRS += validation endif +if test_perf +SUBDIRS += performance +endif + if test_installdir installcheck-local: $(DESTDIR)/$(testdir)/run-test diff --git a/platform/linux-generic/test/performance/Makefile.am b/platform/linux-generic/test/performance/Makefile.am new file mode 100644 index 0000000..22d46d5 --- /dev/null +++ b/platform/linux-generic/test/performance/Makefile.am @@ -0,0 +1,13 @@ +include $(top_srcdir)/test/Makefile.inc +TESTS_ENVIRONMENT += TEST_DIR=${top_builddir}/test/performance + +TESTS = odp_scheduling_proc_run + +dist_check_SCRIPTS = odp_scheduling_proc_run tests-performance.env + +test_SCRIPTS = $(dist_check_SCRIPTS) + +tests-performance.env: + echo "TESTS=\"$(TESTS)\"" > $@ + echo "$(TESTS_ENVIRONMENT)" >> $@ + echo "$(LOG_COMPILER)" >> $@ diff --git a/platform/linux-generic/test/performance/odp_scheduling_proc_run b/platform/linux-generic/test/performance/odp_scheduling_proc_run new file mode 100755 index 0000000..0fbb5ca --- /dev/null +++ b/platform/linux-generic/test/performance/odp_scheduling_proc_run @@ -0,0 +1,25 @@ +#!/bin/sh +# +# Copyright (c) 2015, Linaro Limited +# All rights reserved. +# +# SPDX-License-Identifier: BSD-3-Clause +# +# Script that passes command line arguments to odp_scheduling test when +# launched by 'make check' + +TEST_DIR="${TEST_DIR:-$(dirname $0)}" +ret=0 + +run() +{ + echo odp_scheduling_proc_run starts with $1 worker threads + echo =============================================== + + $TEST_DIR/odp_scheduling${EXEEXT} -c $1 --proc || ret=1 +} + +run 1 +run 8 + +exit $ret diff --git a/platform/linux-generic/test/performance/tests-performance.env b/platform/linux-generic/test/performance/tests-performance.env new file mode 100644 index 0000000..dd18b80 --- /dev/null +++ b/platform/linux-generic/test/performance/tests-performance.env @@ -0,0 +1,3 @@ +TESTS="" +ODP_PLATFORM=linux-generic EXEEXT= TEST_DIR=../../../../test/performance +