From patchwork Mon Oct 26 06:40:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Hubbard X-Patchwork-Id: 11855773 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 250A561C for ; Mon, 26 Oct 2020 06:41:25 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id CE52D2225C for ; Mon, 26 Oct 2020 06:41:24 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=nvidia.com header.i=@nvidia.com header.b="Z2utBgK/" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CE52D2225C Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=nvidia.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E97946B0073; Mon, 26 Oct 2020 02:41:05 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 819676B0078; Mon, 26 Oct 2020 02:41:05 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 663346B0074; Mon, 26 Oct 2020 02:41:05 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0152.hostedemail.com [216.40.44.152]) by kanga.kvack.org (Postfix) with ESMTP id 0AE566B007B for ; Mon, 26 Oct 2020 02:41:04 -0400 (EDT) Received: from smtpin27.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id A7180181AC9CB for ; Mon, 26 Oct 2020 06:41:04 +0000 (UTC) X-FDA: 77413129248.27.bite95_5103ac027271 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin27.hostedemail.com (Postfix) with ESMTP id 7B9EC3D674 for ; Mon, 26 Oct 2020 06:41:04 +0000 (UTC) X-Spam-Summary: 1,0,0,,d41d8cd98f00b204,jhubbard@nvidia.com,,RULES_HIT:30054:30056:30064,0,RBL:216.228.121.64:@nvidia.com:.lbl8.mailshell.net-62.18.0.100 64.10.201.10;04yfnm3s5gk4cerfrw8u7d9ezah1oocd7eqdo4ogpjqbqkr3watx3f8moykdx6s.gsbc5jmpuionmrgpaq94ci43hub1u7n5dwxs6be9rbpqss5a3otoy5f6ppr6exs.1-lbl8.mailshell.net-223.238.255.100,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:ft,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:24,LUA_SUMMARY:none X-HE-Tag: bite95_5103ac027271 X-Filterd-Recvd-Size: 3828 Received: from hqnvemgate25.nvidia.com (hqnvemgate25.nvidia.com [216.228.121.64]) by imf16.hostedemail.com (Postfix) with ESMTP for ; Mon, 26 Oct 2020 06:41:03 +0000 (UTC) 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?b?SsOpcsO0bWUgR2xpc3Nl?= , 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 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== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: 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/selftests/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=1 @@ -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=1