Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
7390cc5c
Unverified
Commit
7390cc5c
authored
Feb 16, 2019
by
liyuqian
Committed by
GitHub
Feb 16, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Increase our build budget to 16ms (#27709)
Because we now have 2 separate GPU and UI threads.
parent
f9a60900
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
39 additions
and
39 deletions
+39
-39
timeline_summary.dart
packages/flutter_driver/lib/src/driver/timeline_summary.dart
+1
-1
timeline_summary_test.dart
packages/flutter_driver/test/src/timeline_summary_test.dart
+38
-38
No files found.
packages/flutter_driver/lib/src/driver/timeline_summary.dart
View file @
7390cc5c
...
...
@@ -16,7 +16,7 @@ const JsonEncoder _prettyEncoder = JsonEncoder.withIndent(' ');
/// The maximum amount of time considered safe to spend for a frame's build
/// phase. Anything past that is in the danger of missing the frame as 60FPS.
const
Duration
kBuildBudget
=
Duration
(
milliseconds:
8
);
const
Duration
kBuildBudget
=
Duration
(
milliseconds:
16
);
/// Extracts statistics from a [Timeline].
class
TimelineSummary
{
...
...
packages/flutter_driver/test/src/timeline_summary_test.dart
View file @
7390cc5c
...
...
@@ -103,9 +103,9 @@ void main() {
group
(
'computeMissedFrameBuildBudgetCount'
,
()
{
test
(
'computes the number of missed build budgets'
,
()
{
final
TimelineSummary
summary
=
summarize
(<
Map
<
String
,
dynamic
>>[
build
(
1000
,
9
000
),
build
(
1
1000
,
1
000
),
build
(
13000
,
10
000
),
build
(
1000
,
17
000
),
build
(
1
9000
,
9
000
),
build
(
29000
,
18
000
),
]);
expect
(
summary
.
countFrames
(),
3
);
...
...
@@ -244,9 +244,9 @@ void main() {
group
(
'computeMissedFrameRasterizerBudgetCount'
,
()
{
test
(
'computes the number of missed rasterizer budgets'
,
()
{
final
TimelineSummary
summary
=
summarize
(<
Map
<
String
,
dynamic
>>[
begin
(
1000
),
end
(
1
0
000
),
begin
(
1
1000
),
end
(
12
000
),
begin
(
13000
),
end
(
23
000
),
begin
(
1000
),
end
(
1
8
000
),
begin
(
1
9000
),
end
(
28
000
),
begin
(
29000
),
end
(
47
000
),
]);
expect
(
summary
.
computeMissedFrameRasterizerBudgetCount
(),
2
);
...
...
@@ -257,27 +257,27 @@ void main() {
test
(
'computes and returns summary as JSON'
,
()
{
expect
(
summarize
(<
Map
<
String
,
dynamic
>>[
begin
(
1000
),
end
(
1
1
000
),
begin
(
1
1000
),
end
(
13
000
),
begin
(
13000
),
end
(
25
000
),
build
(
1000
,
9
000
),
build
(
1
1000
,
1
000
),
build
(
13000
,
11
000
),
begin
(
1000
),
end
(
1
9
000
),
begin
(
1
9000
),
end
(
29
000
),
begin
(
29000
),
end
(
49
000
),
build
(
1000
,
17
000
),
build
(
1
9000
,
9
000
),
build
(
29000
,
19
000
),
]).
summaryJson
,
<
String
,
dynamic
>{
'average_frame_build_time_millis'
:
7
.0
,
'90th_percentile_frame_build_time_millis'
:
1
1
.0
,
'99th_percentile_frame_build_time_millis'
:
1
1
.0
,
'worst_frame_build_time_millis'
:
1
1
.0
,
'average_frame_build_time_millis'
:
15
.0
,
'90th_percentile_frame_build_time_millis'
:
1
9
.0
,
'99th_percentile_frame_build_time_millis'
:
1
9
.0
,
'worst_frame_build_time_millis'
:
1
9
.0
,
'missed_frame_build_budget_count'
:
2
,
'average_frame_rasterizer_time_millis'
:
8
.0
,
'90th_percentile_frame_rasterizer_time_millis'
:
12
.0
,
'99th_percentile_frame_rasterizer_time_millis'
:
12
.0
,
'worst_frame_rasterizer_time_millis'
:
12
.0
,
'average_frame_rasterizer_time_millis'
:
16
.0
,
'90th_percentile_frame_rasterizer_time_millis'
:
20
.0
,
'99th_percentile_frame_rasterizer_time_millis'
:
20
.0
,
'worst_frame_rasterizer_time_millis'
:
20
.0
,
'missed_frame_rasterizer_budget_count'
:
2
,
'frame_count'
:
3
,
'frame_build_times'
:
<
int
>[
9000
,
1000
,
11
000
],
'frame_rasterizer_times'
:
<
int
>[
1
0000
,
2000
,
12
000
],
'frame_build_times'
:
<
int
>[
17000
,
9000
,
19
000
],
'frame_rasterizer_times'
:
<
int
>[
1
8000
,
10000
,
20
000
],
}
);
});
...
...
@@ -307,29 +307,29 @@ void main() {
test
(
'writes summary to JSON file'
,
()
async
{
await
summarize
(<
Map
<
String
,
dynamic
>>[
begin
(
1000
),
end
(
1
1
000
),
begin
(
1
1000
),
end
(
13
000
),
begin
(
13000
),
end
(
25
000
),
build
(
1000
,
9
000
),
build
(
1
1000
,
1
000
),
build
(
13000
,
11
000
),
begin
(
1000
),
end
(
1
9
000
),
begin
(
1
9000
),
end
(
29
000
),
begin
(
29000
),
end
(
49
000
),
build
(
1000
,
17
000
),
build
(
1
9000
,
9
000
),
build
(
29000
,
19
000
),
]).
writeSummaryToFile
(
'test'
,
destinationDirectory:
tempDir
.
path
);
final
String
written
=
await
fs
.
file
(
path
.
join
(
tempDir
.
path
,
'test.timeline_summary.json'
)).
readAsString
();
expect
(
json
.
decode
(
written
),
<
String
,
dynamic
>{
'average_frame_build_time_millis'
:
7
.0
,
'worst_frame_build_time_millis'
:
1
1
.0
,
'90th_percentile_frame_build_time_millis'
:
1
1
.0
,
'99th_percentile_frame_build_time_millis'
:
1
1
.0
,
'average_frame_build_time_millis'
:
15
.0
,
'worst_frame_build_time_millis'
:
1
9
.0
,
'90th_percentile_frame_build_time_millis'
:
1
9
.0
,
'99th_percentile_frame_build_time_millis'
:
1
9
.0
,
'missed_frame_build_budget_count'
:
2
,
'average_frame_rasterizer_time_millis'
:
8
.0
,
'90th_percentile_frame_rasterizer_time_millis'
:
12
.0
,
'99th_percentile_frame_rasterizer_time_millis'
:
12
.0
,
'worst_frame_rasterizer_time_millis'
:
12
.0
,
'average_frame_rasterizer_time_millis'
:
16
.0
,
'90th_percentile_frame_rasterizer_time_millis'
:
20
.0
,
'99th_percentile_frame_rasterizer_time_millis'
:
20
.0
,
'worst_frame_rasterizer_time_millis'
:
20
.0
,
'missed_frame_rasterizer_budget_count'
:
2
,
'frame_count'
:
3
,
'frame_build_times'
:
<
int
>[
9000
,
1000
,
11
000
],
'frame_rasterizer_times'
:
<
int
>[
1
0000
,
2000
,
12
000
],
'frame_build_times'
:
<
int
>[
17000
,
9000
,
19
000
],
'frame_rasterizer_times'
:
<
int
>[
1
8000
,
10000
,
20
000
],
});
});
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment