Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(290)

Unified Diff: tools/perf/page_sets/tough_video_cases.py

Issue 2855133007: Add memory metrics to TBMv2 media benchmarks (Closed)
Patch Set: Rebase Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/perf/benchmarks/media.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/perf/page_sets/tough_video_cases.py
diff --git a/tools/perf/page_sets/tough_video_cases.py b/tools/perf/page_sets/tough_video_cases.py
index 52fee992217d260d225ca263dd2b69954377755e..b55dd50181c3387ee82558136d399cfa999ffd7a 100644
--- a/tools/perf/page_sets/tough_video_cases.py
+++ b/tools/perf/page_sets/tough_video_cases.py
@@ -41,6 +41,9 @@ class ToughVideoCasesPage(page_module.Page):
# Play the media until it has finished or it times out.
action_runner.PlayMedia(playing_event_timeout_in_seconds=60,
ended_event_timeout_in_seconds=60)
+ # Generate memory dump for memoryMetric.
+ if self.page_set.measure_memory:
+ action_runner.MeasureMemory()
def SeekBeforeAndAfterPlayhead(self, action_runner,
action_timeout_in_seconds=60):
@@ -56,6 +59,9 @@ class ToughVideoCasesPage(page_module.Page):
# Seek to after the play-head location.
action_runner.SeekMedia(seconds=9, timeout_in_seconds=timeout,
label='seek_cold')
+ # Generate memory dump for memoryMetric.
+ if self.page_set.measure_memory:
+ action_runner.MeasureMemory()
class Page2(ToughVideoCasesPage):
@@ -401,10 +407,12 @@ class ToughVideoCasesPageSet(story.StorySet):
Description: Video Stack Perf pages that report time_to_play, seek time and
many other media-specific and generic metrics.
"""
- def __init__(self):
+ def __init__(self, measure_memory=False):
super(ToughVideoCasesPageSet, self).__init__(
cloud_storage_bucket=story.PARTNER_BUCKET)
+ self.measure_memory = measure_memory
+
# Normal play tests:
self.AddStory(Page2(self))
self.AddStory(Page4(self))
« no previous file with comments | « tools/perf/benchmarks/media.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698