Skip to contentSkip to conversation

intel_gpu_top: Support exiting the tool by pressing 'q'

PATCH New Tvrtko Ursulin 2 participants 4 messages Dec 17, 2020

lore
Share & tools
lore
#0 lore raw

PATCH 1/3 intel_gpu_top: Support exiting the tool by pressing 'q'

From: Tvrtko Ursulin <[email protected]>

Analoguous to top(1) we can enable the user to exit from the tool by pressing 'q' on the console.

v2:
* Fix sleep period with closed stdin. (Chris)

---
 man/intel_gpu_top.rst |  6 ++++
 tools/intel_gpu_top.c | 80 ++++++++++++++++++++++++++++++++++++-------
 2 files changed, 73 insertions(+), 13 deletions(-)
man/intel_gpu_top.rst +6 -0
index 5552e9699d26..2e0c3a05acc1 100644
@@ -48,6 +48,12 @@ OPTIONS
 -d
     Select a specific GPU using supported filter.
 
+RUNTIME CONTROL
+===============
+
+Supported keys:
+
+    'q'    Exit from the tool.
 
 DEVICE SELECTION
 ================
tools/intel_gpu_top.c +67 -13

110 lines not on this page · raw message

Signature · 6 lines
2.25.1

_______________________________________________
igt-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/igt-dev
#1 lore raw

PATCH 2/3 intel_gpu_top: Aggregate engine busyness per class

From: Tvrtko Ursulin <[email protected]>

Similarly to how top(1) handles SMP, we can default to showing engines of a same class as a single bar graph entry.

To achieve this a little bit of hackery is employed. PMU sampling is left as is and only at the presentation layer we create a fake set of engines, one for each class, summing and normalizing the load respectively.

v2:
* Fix building the aggregated engines.
* Tidy static variable handling.

---
 man/intel_gpu_top.rst |   1 +
 tools/intel_gpu_top.c | 209 +++++++++++++++++++++++++++++++++++++++---
 2 files changed, 197 insertions(+), 13 deletions(-)
man/intel_gpu_top.rst +1 -0
index 2e0c3a05acc1..35ab10da9bb4 100644
@@ -54,6 +54,7 @@ RUNTIME CONTROL
 Supported keys:
 
     'q'    Exit from the tool.
+    '1'    Toggle between aggregated engine class and physical engine mode.
 
 DEVICE SELECTION
 ================
tools/intel_gpu_top.c +196 -13

260 lines not on this page · raw message

Signature · 6 lines
2.25.1

_______________________________________________
igt-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/igt-dev
#2 lore raw

PATCH 3/3 intel_gpu_top: Fix interactive mode on serial console

In reply to Tvrtko Ursulin

From: Tvrtko Ursulin <[email protected]>

TIOCGWINSZ returns zero columns and rows on serial so lets assume 80x24.

---
 tools/intel_gpu_top.c | 5 +++++
 1 file changed, 5 insertions(+)
tools/intel_gpu_top.c +5 -0
index d1149eb8e14d..72ad7cbe9a8c 100644
@@ -1640,6 +1640,11 @@ int main(int argc, char **argv)
 		} else if (ioctl(0, TIOCGWINSZ, &ws) != -1) {
 			con_w = ws.ws_col;
 			con_h = ws.ws_row;
+			if (con_w == 0 && con_h == 0) {
+				/* Serial console. */
+				con_w = 80;
+				con_h = 24;
+			}
 		}
 
 		pmu_sample(engines);
Signature · 6 lines
2.25.1

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#3 lore raw

[igt-dev] ✗ Fi.CI.BAT: failure for series starting with [i-g-t,1/3] intel_gpu_top: Support exiting the tool by pressing 'q'

In reply to Tvrtko Ursulin
== Series Details ==

== Series Details ==

Series: series starting with [i-g-t,1/3] intel_gpu_top: Support exiting the tool by pressing 'q'
URL : https://patchwork.freedesktop.org/series/85039/
State : failure

== Summary ==

CI Bug Log - changes from IGT_5906 -> IGTPW_5305
====================================================

Summary
-------

**FAILURE**

Serious unknown changes coming with IGTPW_5305 absolutely need to be verified manually.

If you think the reported changes have nothing to do with the changes introduced in IGTPW_5305, please notify your bug team to allow them to document this new failure mode, which will reduce false positives in CI.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/index.html

Possible new issues
-------------------

Here are the unknown changes that may have been introduced in IGTPW_5305:

### IGT changes ###

#### Possible regressions ####

* igt@i915_selftest@live@gtt:
- fi-bsw-kefka: [PASS][1] -> [DMESG-WARN][2]
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-bsw-kefka/igt@i915_selftest@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-bsw-kefka/igt@i915_selftest@[email protected]

Known issues
------------

Here are the changes found in IGTPW_5305 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@amdgpu/amd_cs_nop@nop-gfx0:
- fi-apl-guc: NOTRUN -> [SKIP][3] ([fdo#109271]) +17 similar issues
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-apl-guc/igt@amdgpu/[email protected]

* igt@i915_getparams_basic@basic-subslice-total:
- fi-tgl-y: [PASS][4] -> [DMESG-WARN][5] ([i915#402]) +1 similar issue
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-tgl-y/igt@[email protected]
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-tgl-y/igt@[email protected]

* igt@i915_selftest@live@gt_heartbeat:
- fi-tgl-y: [PASS][6] -> [DMESG-FAIL][7] ([i915#2601])
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-tgl-y/igt@i915_selftest@live@gt_heartbeat.html
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-tgl-y/igt@i915_selftest@live@gt_heartbeat.html

#### Possible fixes ####

* igt@gem_mmap_gtt@basic:
- fi-tgl-y: [DMESG-WARN][8] ([i915#402]) -> [PASS][9] +1 similar issue
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-tgl-y/igt@[email protected]
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-tgl-y/igt@[email protected]

* igt@i915_pm_rpm@module-reload:
- fi-kbl-guc: [FAIL][10] ([i915#579]) -> [PASS][11]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-kbl-guc/igt@[email protected]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-kbl-guc/igt@[email protected]

* igt@i915_selftest@live@gt_timelines:
- fi-apl-guc: [INCOMPLETE][12] ([i915#2750]) -> [PASS][13]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-apl-guc/igt@i915_selftest@live@gt_timelines.html
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-apl-guc/igt@i915_selftest@live@gt_timelines.html

* igt@i915_selftest@live@hugepages:
- fi-bsw-kefka: [DMESG-WARN][14] -> [PASS][15]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-bsw-kefka/igt@i915_selftest@[email protected]
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-bsw-kefka/igt@i915_selftest@[email protected]

* igt@kms_chamelium@hdmi-edid-read:
- fi-kbl-7500u: [DMESG-FAIL][16] ([i915#165]) -> [PASS][17]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-kbl-7500u/igt@[email protected]
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-kbl-7500u/igt@[email protected]

#### Warnings ####

* igt@i915_pm_rpm@basic-rte:
- fi-kbl-guc: [SKIP][18] ([fdo#109271]) -> [FAIL][19] ([i915#579])
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/IGT_5906/fi-kbl-guc/igt@[email protected]
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/fi-kbl-guc/igt@[email protected]

[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[i915#165]: https://gitlab.freedesktop.org/drm/intel/issues/165
[i915#2601]: https://gitlab.freedesktop.org/drm/intel/issues/2601
[i915#2750]: https://gitlab.freedesktop.org/drm/intel/issues/2750
[i915#402]: https://gitlab.freedesktop.org/drm/intel/issues/402
[i915#579]: https://gitlab.freedesktop.org/drm/intel/issues/579

Participating hosts (42 -> 38)
------------------------------

Missing (4): fi-dg1-1 fi-bsw-cyan fi-bdw-samus fi-hsw-4200u

Build changes
-------------

* CI: CI-20190529 -> None
* IGT: IGT_5906 -> IGTPW_5305

CI-20190529: 20190529
CI_DRM_9496: c1bf99ceda83bcdd33f05515deb9efc3649d449e @ git://anongit.freedesktop.org/gfx-ci/linux
IGTPW_5305: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/index.html
IGT_5906: f5b022a2e5054ee7e335d7856344807308db6d6f @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_5305/index.html

_______________________________________________
igt-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/igt-dev