Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp1003112pxu; Mon, 26 Oct 2020 01:13:02 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwShglDWXbqO1VL7B7RQbkk/Au4F1kuhmVzJo0sjXGceP61mRYJbWlcJvRf+gwQL6MuFFko X-Received: by 2002:a17:906:4bc2:: with SMTP id x2mr14938898ejv.525.1603699981963; Mon, 26 Oct 2020 01:13:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603699981; cv=none; d=google.com; s=arc-20160816; b=xG4sMvQW7e1HeVXkFzjR+6iKB5cVd9K8ErUf4Ypn5ohOJNv3oOGWTTZgXhz0S8b49D bCtKpeylNcUxhhqjt3J5iZcncjD7AlCWNcfnysmzysUvLWaNes1Xsxvk09q2yMcx7Bpo 6tuG4REyJuXqcXbiH/rwc0xYPBx8FmOo52TtE3JNVA+H1QHlqs/61uY0xrszOPOoSNNM TId1u7SK0gATLwVmqVC+QM2XElfiEQoRybI26KCNaG1q1bpOv3MGsyfoZl9WVgpn3Ti0 Tn8dxo3FCFCgL8lLo/6Un2F/s6a14X//RBtCKlHz854A4Ct9sffC8NO7GsSlLy5/efSF E3kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:dkim-signature:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from; bh=YaxNbn53iJTo0Zqqd0XK0hs/zmsFR5Tq5VhzHL3FjMc=; b=rsLHHOOO42UJMDH42Yjqewx6/ir51RHUyaarb2pf676ngGYP2dwIHeZimYFgZ4TtD8 V30RqSfUKXyTzHhnMD+fpkFRG1NsWCCyYgP1mMcRXAkng6ekDgvZcVziTT1M8xlm8k6d GpGZXzfgJJc1gR28zkqQbGY51j249Ym9x7b5NPt4ibMNTk/s44u3vgzIYPANRUIouQ5h 3PdLy+B0/KzNZQsfOELfq6cYR2wn3zQ3ELNYrJiwzAvVC2wyg+xyxWUNvXlJ8Gw/8kWZ JQsxI9/1wTsk6VaAoPvDceF4vRrOLwqAcF8Xv16u4mqQb9WGTwwS6traec1zFDUW9Cnr cARw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b="Z2utBgK/"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a2si6187552edt.376.2020.10.26.01.12.40; Mon, 26 Oct 2020 01:13:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b="Z2utBgK/"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1770578AbgJZGlM (ORCPT + 99 others); Mon, 26 Oct 2020 02:41:12 -0400 Received: from hqnvemgate25.nvidia.com ([216.228.121.64]:13010 "EHLO hqnvemgate25.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1770549AbgJZGlC (ORCPT ); Mon, 26 Oct 2020 02:41:02 -0400 Received: from hqmail.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate25.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Sun, 25 Oct 2020 23:41:07 -0700 Received: from HQMAIL111.nvidia.com (172.20.187.18) by HQMAIL105.nvidia.com (172.20.187.12) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Mon, 26 Oct 2020 06:41:02 +0000 Received: from sandstorm.nvidia.com (10.124.1.5) by mail.nvidia.com (172.20.187.18) with Microsoft SMTP Server id 15.0.1473.3 via Frontend Transport; Mon, 26 Oct 2020 06:41:02 +0000 From: John Hubbard To: Andrew Morton CC: Shuah Khan , Mike Rapoport , Ralph Campbell , =?UTF-8?q?J=C3=A9r=C3=B4me=20Glisse?= , Jonathan Corbet , LKML , , , John Hubbard Subject: [PATCH v3 9/9] selftests/vm: 2x speedup for run_vmtests.sh Date: Sun, 25 Oct 2020 23:40:21 -0700 Message-ID: <20201026064021.3545418-10-jhubbard@nvidia.com> X-Mailer: git-send-email 2.29.0 In-Reply-To: <20201026064021.3545418-1-jhubbard@nvidia.com> References: <20201026064021.3545418-1-jhubbard@nvidia.com> MIME-Version: 1.0 X-NVConfidentiality: public Content-Transfer-Encoding: quoted-printable Content-Type: text/plain DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1603694467; bh=YaxNbn53iJTo0Zqqd0XK0hs/zmsFR5Tq5VhzHL3FjMc=; h=From:To:CC:Subject:Date:Message-ID:X-Mailer:In-Reply-To: References:MIME-Version:X-NVConfidentiality: Content-Transfer-Encoding:Content-Type; b=Z2utBgK/QM6HMt/paiqpFJE3pN4KXFgyn2VjwwMQYkBlAY26mL/4fqFu2U2oWYhvt A4JIP9Tm2a1OaJLI2cAtKONTtVkSrKBFK997J+1I3S6R2C2X62Jw7MJ5JbNCrDWFSi jPzil8KDf5D+qjiHvLialCa6RNpR3llgKttBzRXZnEoDIeLRUvkr/WudssyyLF1Xof do61iGiBi01RNougugJsQcI4Ni3kAK5YQVFrC7nkX9u0YTg0GmsMRdmIKRWpnfbuaM HecH/4Ayj7vpIJfPk07ociCu/2kK6qWHSqCRPvvzBqxQj5ML/hSHJN7JdKU3k5dxPl ryhHtakDhFAoA== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Each invocation of userfaultfd for "anon" and "shmem" was taking about 6.5 sec to run, contributing to an overall run time of about 22 sec for run_vmtests.sh. Reduce the size and bounce input values to the userfaultfd invocation within run_vmtests.sh, enough to get each invocation down to about 1.0 sec. This should still provide a reasonable smoke test, while staying within a nominal time budget of around 1 second or so per test. And this brings the overall running time of run_vmtests.sh down to 11 second. Cc: Mike Rapoport Cc: Shuah Khan Signed-off-by: John Hubbard --- tools/testing/selftests/vm/run_vmtests.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/vm/run_vmtests.sh b/tools/testing/self= tests/vm/run_vmtests.sh index 4ac84b350d9f..9e8837768ee2 100755 --- a/tools/testing/selftests/vm/run_vmtests.sh +++ b/tools/testing/selftests/vm/run_vmtests.sh @@ -160,7 +160,7 @@ fi echo "-------------------" echo "running userfaultfd" echo "-------------------" -./userfaultfd anon 128 32 +./userfaultfd anon 20 16 if [ $? -ne 0 ]; then echo "[FAIL]" exitcode=3D1 @@ -185,7 +185,7 @@ rm -f $mnt/ufd_test_file echo "-------------------------" echo "running userfaultfd_shmem" echo "-------------------------" -./userfaultfd shmem 128 32 +./userfaultfd shmem 20 16 if [ $? -ne 0 ]; then echo "[FAIL]" exitcode=3D1 --=20 2.29.0