Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Add anchor events for developer centric timeline#4105

Merged
B3rn475 merged 7 commits intoflutter:masterfrom
B3rn475:timeline
Sep 15, 2017
Merged

Add anchor events for developer centric timeline#4105
B3rn475 merged 7 commits intoflutter:masterfrom
B3rn475:timeline

Conversation

@B3rn475
Copy link
Contributor

@B3rn475 B3rn475 commented Sep 13, 2017

By adding these events the new developer centric timeline will be able
to identify and correlate events related to the different stages of the
drawing pipeline.

This Pull Request is for review purposes, it needs to wait for the corresponding changes in the Dart VM to land first.

// sizeof(jlong) * 8 / 10 (number of groups of 10 bits)
// sizeof(jlong) * 8 / 10 * 3 (number of digits - 1)
// sizeof(jlong) * 8 / 10 * 3 + 2 (number of digits + \0)
char deadline[sizeof(jlong) * 8 / 10 * 3 + 2];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can these two lines also be made conditional under profile/debug

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

// sizeof(jlong) * 8 / 10 (number of groups of 10 bits)
// sizeof(jlong) * 8 / 10 * 3 (number of digits - 1)
// sizeof(jlong) * 8 / 10 * 3 + 2 (number of digits + \0)
char deadline[sizeof(jlong) * 8 / 10 * 3 + 2];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto comment about these two lines.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done


// This ID is used by the timeline component to correctly align
// GPU Workloads events with their respective Framework Workload.
const char* Animator::FrameId() {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this alternating instead of increasing?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This values is used has a helper by the Frame alignment code to correctly pair Framework Workload events with the relative GPU Workload.
https://github.com/dart-lang/sdk/blob/master/runtime/observatory/web/timeline.js#L284

Due the fact that we can add just strings to the Timeline Events, alternating two constant values avoids us to print the value to it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe FrameParity instead then, since this doesn't identify a unique frame.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Copy link
Contributor

@a-siva a-siva left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@B3rn475
Copy link
Contributor Author

B3rn475 commented Sep 15, 2017

Rebasing

@B3rn475 B3rn475 merged commit 0c1e217 into flutter:master Sep 15, 2017
@B3rn475 B3rn475 deleted the timeline branch September 15, 2017 03:18
@B3rn475 B3rn475 mentioned this pull request Sep 15, 2017
B3rn475 added a commit that referenced this pull request Sep 15, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants