From patchwork Tue Nov 3 16:29:45 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Derek Morton X-Patchwork-Id: 7545681 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id CF0989F36A for ; Tue, 3 Nov 2015 16:30:01 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 17DCA20695 for ; Tue, 3 Nov 2015 16:30:01 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 2B09B20693 for ; Tue, 3 Nov 2015 16:30:00 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A0FC16E779; Tue, 3 Nov 2015 08:29:58 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by gabe.freedesktop.org (Postfix) with ESMTP id 67BC26E779 for ; Tue, 3 Nov 2015 08:29:55 -0800 (PST) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga102.fm.intel.com with ESMTP; 03 Nov 2015 08:29:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,239,1444719600"; d="scan'208";a="842154422" Received: from djmorton-linux2.isw.intel.com ([10.102.226.90]) by fmsmga002.fm.intel.com with ESMTP; 03 Nov 2015 08:29:53 -0800 From: Derek Morton To: intel-gfx@lists.freedesktop.org Date: Tue, 3 Nov 2015 16:29:45 +0000 Message-Id: <1446568185-675-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] 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. 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..5028145 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);