summaryrefslogtreecommitdiff
path: root/tests/perf.c
AgeCommit message (Collapse)Author
2017-08-04tests/perf: don't assume constant of 40 EUsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: s/test_perf_ctx_mi_rpc/hsw_test_single_ctx_counters/Robert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: allow 10% margin matching oa/sysfs freq in test_oa_exponentsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: avoid assumptions about oa exponent <-> freq mappingsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: handling printing gen8 formatsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: wrap emission of MI_REPORT_PERF_COUNTRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: move timebase + oa exponent utilities upRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: generalize reading gpu ticks from reportsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: generalize checks for undefined A countersRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: fix a counter indexingRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: add gen8 formatsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: update init_sys_info for skl with per-gt configsRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-08-04tests/perf: init timestamp freq and oa format per devidRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
2017-08-04tests/perf: improve robustness of polling/blocking testsRobert Bragg
There were a couple of problems with both of these tests that could lead to false negatives addressed by this patch. 1) The upper limit for the number of iterations missed a +1 to consider that there might be a sample immediately available at the start of the loop. 2) The tests didn't consider that a duration measured in terms of (end-start) ticks could be +- 1 tick since we don't know the fractional part of the tick counts. Our threshold for stime being < one tick could have a false negative for any real stime between 1 to 10 milliseconds depending on luck. The tests now both run for a lot longer (1000 x tick duration, or typically 10 seconds each) so that a single tick represents a much smaller proportion of the total duration (0.1%) and the stime thresholds are now set at 1% of the total duration. Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
2017-08-04tests/perf: generalize lookup for test metric setRobert Bragg
Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
2017-03-24lib/debugfs: Phase out igt_debugfs_fopen()Chris Wilson
Wrapping fdopen() proved dangerous, the underlying fd is not refcounted, and we must close it in the library or else we easily leak and exhaust all fd. Since we can't provide igt_debugfs_fopen(), move the burden onto the caller for those that require a stream FILE*. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-03-21Restore "lib: Open debugfs files for the given DRM device"Chris Wilson
This reverts commit 25fbae15262cf570e207e62f50e7c5233e06bc67, restoring commit 301ad44cdf1b868b1ab89096721da91fa8541fdc Author: Tomeu Vizoso <tomeu.vizoso@collabora.com> Date: Thu Mar 2 10:37:11 2017 +0100 lib: Open debugfs files for the given DRM device with fixes. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-03-21Revert "lib: Open debugfs files for the given DRM device"Tomeu Vizoso
This reverts commit 301ad44cdf1b868b1ab89096721da91fa8541fdc. When a render-only device is opened and gem_quiescent_gpu is called, we need to use the debugfs dir for the master device instead. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com>
2017-03-21lib: Open debugfs files for the given DRM deviceTomeu Vizoso
When opening a DRM debugfs file, locate the right path based on the given DRM device FD. This is needed so, in setups with more than one DRM device, any operations on debugfs files affect the expected DRM device. v2: - rebased and fixed new API additions v3: - updated chamelium test, which was missed previously - use the minor of the device for the debugfs path, not the major - have a proper exit handler for calling igt_hpd_storm_reset with the right device fd. Signed-off-by: Tomeu Vizoso <tomeu.vizoso@collabora.com> Reviewed-by: Robert Foss <robert.foss@collabora.com> Acked-by: Chris Wilson <chris@chris-wilson.co.uk>
2017-01-02tests/perf: Fix pointer length compilation errors on 32-bit systemsRobert Foss
Fix pointer length compilations errors on 32-bit systems. Signed-off-by: Robert Foss <robert.foss@collabora.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-17tests/perf: Remove duplicate NSEC_PER_SEC defineChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2016-12-16igt/perf: add i915 perf stream tests for HaswellRobert Bragg
This bumps the libdrm_intel version required to 2.4.74 for the drm_intel_context_get_id api used in these tests. Signed-off-by: Robert Bragg <robert@sixbynine.org> Reviewed-by: Matthew Auld <matthew.auld@intel.com>