From patchwork Thu Nov 5 10:01:39 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Derek Morton X-Patchwork-Id: 7559681 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 5463ABEEA4 for ; Thu, 5 Nov 2015 10:02:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9381020721 for ; Thu, 5 Nov 2015 10:01:52 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id CA9A4206A9 for ; Thu, 5 Nov 2015 10:01:47 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A70C06E9CC; Thu, 5 Nov 2015 02:01:46 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by gabe.freedesktop.org (Postfix) with ESMTP id 5A22F6E9CC for ; Thu, 5 Nov 2015 02:01:45 -0800 (PST) Received: from orsmga001.jf.intel.com ([10.7.209.18]) by orsmga103.jf.intel.com with ESMTP; 05 Nov 2015 02:01:45 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,247,1444719600"; d="scan'208";a="812327678" Received: from djmorton-linux2.isw.intel.com ([10.102.226.90]) by orsmga001.jf.intel.com with ESMTP; 05 Nov 2015 02:01:43 -0800 From: Derek Morton To: intel-gfx@lists.freedesktop.org Date: Thu, 5 Nov 2015 10:01:39 +0000 Message-Id: <1446717699-26805-1-git-send-email-derek.j.morton@intel.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 Cc: thomas.wood@intel.com Subject: [Intel-gfx] [PATCH i-g-t v2] tests/gem_exec_nop: Improved test run time X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Reduced the Sleep period to 200mS and reduced the repetition count to 7 to decrease the test run time significantly. Also fixed a non ascii character that messed up the results table formatting. v2: Changed uS to us Signed-off-by: Derek Morton --- tests/gem_exec_nop.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/gem_exec_nop.c b/tests/gem_exec_nop.c index a287d08..998e0eb 100644 --- a/tests/gem_exec_nop.c +++ b/tests/gem_exec_nop.c @@ -133,7 +133,7 @@ static void loop(int fd, uint32_t handle, unsigned ring_id, const char *ring_nam gem_sync(fd, handle); for (count = 1; count <= SLOW_QUICK(1<<17, 1<<4); count <<= 1) { - const int reps = 13; + const int reps = 7; igt_stats_t stats; int n; @@ -142,7 +142,7 @@ static void loop(int fd, uint32_t handle, unsigned ring_id, const char *ring_nam for (n = 0; n < reps; n++) { struct timespec start, end; int loops = count; - sleep(1); /* wait for the hw to go back to sleep */ + usleep(200000); /* wait 200mS for the hw to go back to sleep */ clock_gettime(CLOCK_MONOTONIC, &start); while (loops--) do_ioctl(fd, DRM_IOCTL_I915_GEM_EXECBUFFER2, &execbuf); @@ -151,7 +151,7 @@ static void loop(int fd, uint32_t handle, unsigned ring_id, const char *ring_nam igt_stats_push(&stats, elapsed(&start, &end, count)); } - igt_info("Time to exec x %d: %7.3fµs (ring=%s)\n", + igt_info("Time to exec x %d: %7.3fus (ring=%s)\n", count, igt_stats_get_trimean(&stats)/1000, ring_name); fflush(stdout);