summaryrefslogtreecommitdiffstats
path: root/media/cast/logging
diff options
context:
space:
mode:
authormiu <miu@chromium.org>2016-01-04 16:45:25 -0800
committerCommit bot <commit-bot@chromium.org>2016-01-05 00:46:34 +0000
commit8f10a44b8d95cf06e5652bf346ae7a260ff4f771 (patch)
treee8b9abe3d6f9674ff4a5502d7b5fe39ecda8b1a1 /media/cast/logging
parentb45e6de2eb286ae0a245a2d56fd851a3b20a83f4 (diff)
downloadchromium_src-8f10a44b8d95cf06e5652bf346ae7a260ff4f771.zip
chromium_src-8f10a44b8d95cf06e5652bf346ae7a260ff4f771.tar.gz
chromium_src-8f10a44b8d95cf06e5652bf346ae7a260ff4f771.tar.bz2
Optimizations to improve run times of cast_unittests.
Overall, this change improved the total "--single-process-tests" run time from 14599 ms to 6958 ms on a high-performance developer desktop. This over-50% improvement should also carry over into sanitizer test runs, and help to alleviate test timeouts (e.g., on Dr Memory bots). I identified all individual tests that were running over 100 ms, and reduced their run-time by: 1. Reducing loop iterations to just the amount needed to appropriately test the implementation. 2. Reducing data volume by using smaller-sized VideoFrames in tests. 3. Optimizing media::cast::FakeSingleThreadTaskRunner, the task scheduler used by most of the tests. 4. Merging multiple end-to-end tests into a smaller set that still tests all the same end-to-end functionality. BUG=530842,487033 Review URL: https://codereview.chromium.org/1551063002 Cr-Commit-Position: refs/heads/master@{#367431}
Diffstat (limited to 'media/cast/logging')
-rw-r--r--media/cast/logging/logging_defines.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/media/cast/logging/logging_defines.h b/media/cast/logging/logging_defines.h
index 4780d84..455f85d 100644
--- a/media/cast/logging/logging_defines.h
+++ b/media/cast/logging/logging_defines.h
@@ -37,7 +37,9 @@ enum CastLoggingEvent {
PACKET_RTX_REJECTED,
// Receiver side packet events.
PACKET_RECEIVED,
- kNumOfLoggingEvents = PACKET_RECEIVED
+};
+enum {
+ kNumOfLoggingEvents = PACKET_RECEIVED + 1,
};
const char* CastLoggingToString(CastLoggingEvent event);