From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2816CC43467 for ; Sat, 17 Oct 2020 23:14:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E374A20897 for ; Sat, 17 Oct 2020 23:14:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1602976483; bh=eUbd2W90+RDXkzNB16/AG7mgOK8GmWj7wUP2cWH9jFE=; h=Date:From:To:Subject:In-Reply-To:Reply-To:List-ID:From; b=PtB3BDhIJVxLJQ9rvz+Ewt8CeC6hFafwazVLLyYpFimSPPNrU3wKHahs1PpBAOkm1 sacySBBoB7VVpeOBHlWeq+dPScaogAfirPsxPHRBPbXaNzQMnUGDUIr1tY0+2MD2s7 zL5fexp5y1BEvoLlmbYP5H0l81aDUzHDbXAIyu8w= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2439901AbgJQXOm (ORCPT ); Sat, 17 Oct 2020 19:14:42 -0400 Received: from mail.kernel.org ([198.145.29.99]:48452 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2439878AbgJQXOm (ORCPT ); Sat, 17 Oct 2020 19:14:42 -0400 Received: from localhost.localdomain (c-73-231-172-41.hsd1.ca.comcast.net [73.231.172.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4AE08208B6; Sat, 17 Oct 2020 23:14:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1602976481; bh=eUbd2W90+RDXkzNB16/AG7mgOK8GmWj7wUP2cWH9jFE=; h=Date:From:To:Subject:In-Reply-To:From; b=yIQhyZ803u9buW9NwiwW76XSboLapA5nGZ1foW8UU9OFt9+YyWnwVG2Q8c18YJYgo foeAVglJ5fW/lbOgcQP2R7cVb36PICC6i/cng0m2IPhmW6kMGCLlj8TQXO8mZgZSsM z6SLf8m9jtHc+0VWfJsV4M4I7t2GNl/fpMDlTryM= Date: Sat, 17 Oct 2020 16:14:40 -0700 From: Andrew Morton To: akpm@linux-foundation.org, corbet@lwn.net, jglisse@redhat.com, jhubbard@nvidia.com, linux-mm@kvack.org, mm-commits@vger.kernel.org, rcampbell@nvidia.com, shuah@kernel.org, torvalds@linux-foundation.org Subject: [patch 21/40] selftests/vm: run_vmtests.sh: update and clean up gup_test invocation Message-ID: <20201017231440.9OlmYk2Ol%akpm@linux-foundation.org> In-Reply-To: <20201017161314.88890b87fae7446ccc13c902@linux-foundation.org> User-Agent: s-nail v14.8.16 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk Reply-To: linux-kernel@vger.kernel.org List-ID: X-Mailing-List: mm-commits@vger.kernel.org =46rom: John Hubbard Subject: selftests/vm: run_vmtests.sh: update and clean up gup_test invocat= ion Run benchmarks on the _fast variants of gup and pup, as originally intended. Run the new gup_test sub-test: dump pages. In addition to exercising the dump_page() call, it also demonstrates the various options you can use to specify which pages to dump, and how. Link: https://lkml.kernel.org/r/20200929212747.251804-8-jhubbard@nvidia.com Signed-off-by: John Hubbard Cc: J=C3=A9r=C3=B4me Glisse Cc: Jonathan Corbet Cc: Ralph Campbell Cc: Shuah Khan Signed-off-by: Andrew Morton --- tools/testing/selftests/vm/run_vmtests.sh | 24 +++++++++++++++----- 1 file changed, 18 insertions(+), 6 deletions(-) --- a/tools/testing/selftests/vm/run_vmtests.sh~selftests-vm-run_vmtestsh-u= pdate-and-clean-up-gup_test-invocation +++ a/tools/testing/selftests/vm/run_vmtests.sh @@ -124,9 +124,9 @@ else fi =20 echo "--------------------------------------------" -echo "running 'gup_test -U' (normal/slow gup)" +echo "running 'gup_test -u' (fast gup benchmark)" echo "--------------------------------------------" -./gup_test -U +./gup_test -u if [ $? -ne 0 ]; then echo "[FAIL]" exitcode=3D1 @@ -134,10 +134,22 @@ else echo "[PASS]" fi =20 -echo "------------------------------------------" -echo "running gup_test -b (pin_user_pages)" -echo "------------------------------------------" -./gup_test -b +echo "---------------------------------------------------" +echo "running gup_test -a (pin_user_pages_fast benchmark)" +echo "---------------------------------------------------" +./gup_test -a +if [ $? -ne 0 ]; then + echo "[FAIL]" + exitcode=3D1 +else + echo "[PASS]" +fi + +echo "--------------------------------------------------------------" +echo "running gup_test -ct -F 0x1 0 19 0x1000" +echo " Dumps pages 0, 19, and 4096, using pin_user_pages (-F 0x1)" +echo "--------------------------------------------------------------" +./gup_test -ct -F 0x1 0 19 0x1000 if [ $? -ne 0 ]; then echo "[FAIL]" exitcode=3D1 _