All of lore.kernel.org
 help / color / mirror / Atom feed
From: John Hubbard <jhubbard@nvidia.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: "Shuah Khan" <shuah@kernel.org>,
	"Mike Rapoport" <rppt@linux.vnet.ibm.com>,
	"Ralph Campbell" <rcampbell@nvidia.com>,
	"Jérôme Glisse" <jglisse@redhat.com>,
	"Jonathan Corbet" <corbet@lwn.net>,
	LKML <linux-kernel@vger.kernel.org>,
	linux-mm@kvack.org, linux-kselftest@vger.kernel.org,
	"John Hubbard" <jhubbard@nvidia.com>
Subject: [PATCH v3 9/9] selftests/vm: 2x speedup for run_vmtests.sh
Date: Sun, 25 Oct 2020 23:40:21 -0700	[thread overview]
Message-ID: <20201026064021.3545418-10-jhubbard@nvidia.com> (raw)
In-Reply-To: <20201026064021.3545418-1-jhubbard@nvidia.com>

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 <rppt@linux.vnet.ibm.com>
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: John Hubbard <jhubbard@nvidia.com>
---
 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
-- 
2.29.0


      parent reply	other threads:[~2020-10-26  6:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-26  6:40 [PATCH v3 0/9] selftests/vm: gup_test, hmm-tests, assorted improvements John Hubbard
2020-10-26  6:40 ` [PATCH v3 1/9] mm/gup_benchmark: rename to mm/gup_test John Hubbard
2020-10-26  6:40 ` [PATCH v3 2/9] selftests/vm: use a common gup_test.h John Hubbard
2020-10-26  6:40 ` [PATCH v3 3/9] selftests/vm: rename run_vmtests --> run_vmtests.sh John Hubbard
2020-10-26  6:40 ` [PATCH v3 4/9] selftests/vm: minor cleanup: Makefile and gup_test.c John Hubbard
2020-10-26  6:40 ` [PATCH v3 5/9] selftests/vm: only some gup_test items are really benchmarks John Hubbard
2020-10-26  6:40 ` [PATCH v3 6/9] selftests/vm: gup_test: introduce the dump_pages() sub-test John Hubbard
2020-10-26  6:40 ` [PATCH v3 7/9] selftests/vm: run_vmtests.sh: update and clean up gup_test invocation John Hubbard
2020-10-26  6:40 ` [PATCH v3 8/9] selftests/vm: hmm-tests: remove the libhugetlbfs dependency John Hubbard
2020-10-26  6:40 ` John Hubbard [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20201026064021.3545418-10-jhubbard@nvidia.com \
    --to=jhubbard@nvidia.com \
    --cc=akpm@linux-foundation.org \
    --cc=corbet@lwn.net \
    --cc=jglisse@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=rcampbell@nvidia.com \
    --cc=rppt@linux.vnet.ibm.com \
    --cc=shuah@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.