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

Side by Side Diff: cc/resources/raster_worker_pool_perftest.cc

Issue 137893023: cc_perftests: Don't count number of tasks required for activation twice (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/resources/raster_worker_pool.h" 5 #include "cc/resources/raster_worker_pool.h"
6 6
7 #include "base/time/time.h" 7 #include "base/time/time.h"
8 #include "cc/test/lap_timer.h" 8 #include "cc/test/lap_timer.h"
9 #include "testing/gtest/include/gtest/gtest.h" 9 #include "testing/gtest/include/gtest/gtest.h"
10 #include "testing/perf/perf_test.h" 10 #include "testing/perf/perf_test.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 perf_tasks[task] = new_perf_task; 68 perf_tasks[task] = new_perf_task;
69 } 69 }
70 70
71 perf_tasks_.swap(perf_tasks); 71 perf_tasks_.swap(perf_tasks);
72 } 72 }
73 73
74 void BuildTaskGraph() { 74 void BuildTaskGraph() {
75 unsigned priority = 0; 75 unsigned priority = 0;
76 TaskGraph graph; 76 TaskGraph graph;
77 77
78 size_t raster_tasks_required_for_activation_count = 0u;
79 for (RasterTaskVector::const_iterator it = raster_tasks().begin();
80 it != raster_tasks().end(); ++it) {
81 if (IsRasterTaskRequiredForActivation(it->get()))
82 raster_tasks_required_for_activation_count++;
83 }
84
85 scoped_refptr<internal::WorkerPoolTask> 78 scoped_refptr<internal::WorkerPoolTask>
86 raster_required_for_activation_finished_task( 79 raster_required_for_activation_finished_task(
87 CreateRasterRequiredForActivationFinishedTask( 80 CreateRasterRequiredForActivationFinishedTask(
88 raster_tasks_required_for_activation_count)); 81 raster_tasks_required_for_activation().size()));
89 internal::GraphNode* raster_required_for_activation_finished_node = 82 internal::GraphNode* raster_required_for_activation_finished_node =
90 CreateGraphNodeForTask( 83 CreateGraphNodeForTask(
91 raster_required_for_activation_finished_task.get(), 84 raster_required_for_activation_finished_task.get(),
92 priority++, 85 priority++,
93 &graph); 86 &graph);
94 87
95 scoped_refptr<internal::WorkerPoolTask> raster_finished_task( 88 scoped_refptr<internal::WorkerPoolTask> raster_finished_task(
96 CreateRasterFinishedTask()); 89 CreateRasterFinishedTask());
97 internal::GraphNode* raster_finished_node = 90 internal::GraphNode* raster_finished_node =
98 CreateGraphNodeForTask(raster_finished_task.get(), 91 CreateGraphNodeForTask(raster_finished_task.get(),
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 /*RunBuildTaskGraphTest("100_4", 100, 4); 217 /*RunBuildTaskGraphTest("100_4", 100, 4);
225 RunBuildTaskGraphTest("1000_4", 1000, 4); 218 RunBuildTaskGraphTest("1000_4", 1000, 4);
226 RunBuildTaskGraphTest("10_16", 10, 16); 219 RunBuildTaskGraphTest("10_16", 10, 16);
227 RunBuildTaskGraphTest("100_16", 100, 16); 220 RunBuildTaskGraphTest("100_16", 100, 16);
228 RunBuildTaskGraphTest("1000_16", 1000, 16);*/ 221 RunBuildTaskGraphTest("1000_16", 1000, 16);*/
229 } 222 }
230 223
231 } // namespace 224 } // namespace
232 225
233 } // namespace cc 226 } // namespace cc
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698