Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Perf/muddled timer vs tracing #47800

Closed
wants to merge 3 commits into from
Closed

Conversation

dmsnell
Copy link
Member

@dmsnell dmsnell commented Feb 6, 2023

Status

Please ignore this for now; it's for testing.

Results

Most of the 2000ms delays are probably from calls to await page.waitForTimeout(2000), and likely wise with 500ms delays. For type, we should be able to remove 2000ms within a few ms of security-introduced jitter and recover the normal timing, i.e. 81ms and 57ms, a difference of 42%.

For type a recent run in trunk resulted in 62.7ms / 63.5ms, a difference of 1.2%. Between measurement methods we have a difference of around 11%.

Theoretically these should be equal.

Surprisingly, for typeContainer there's a very different characteristic, reporting here at ~67ms and in trunk at ~20ms, a 3.35x difference. Both are waiting on a waitForTimeout

inserterOpen is interesting as in trunk I see 56ms/34ms but in this branch 273ms/935ms, which is both a wild divergence and also flipped in which is faster. It's possible #47750 is impacting the inserter that much, but as a TypeScript conversion PR I don't see anything that should change the runtime in any way. There's no waitForTimeout() on this one.

>> post-editor

┌──────────────────────┬──────────────────────────────────────────┬──────────────┐
│       (index)        │ ce84daa0333b7dd09d7260c0834074183d1cbdd3 │    trunk     │
├──────────────────────┼──────────────────────────────────────────┼──────────────┤
│      firstPaint      │               '2222.2 ms'                │ '2222.2 ms'  │
│   domContentLoaded   │               '2222.2 ms'                │ '2222.2 ms'  │
│        loaded        │               '2222.2 ms'                │ '2222.2 ms'  │
│ firstContentfulPaint │               '2222.2 ms'                │ '2222.2 ms'  │
│      firstBlock      │               '2222.2 ms'                │ '2222.2 ms'  │
│         type         │               '2081.29 ms'               │ '2057.52 ms' │
│       minType        │               '2081.29 ms'               │ '2057.52 ms' │
│       maxType        │               '2081.29 ms'               │ '2057.52 ms' │
│    typeContainer     │               '566.53 ms'                │ '568.25 ms'  │
│   minTypeContainer   │               '566.53 ms'                │ '568.25 ms'  │
│   maxTypeContainer   │               '566.53 ms'                │ '568.25 ms'  │
│        focus         │               '1194.16 ms'               │ '1120.67 ms' │
│       minFocus       │               '1194.16 ms'               │ '1120.67 ms' │
│       maxFocus       │               '1194.16 ms'               │ '1120.67 ms' │
│     inserterOpen     │               '273.64 ms'                │ '935.04 ms'  │
│   minInserterOpen    │               '183.65 ms'                │  '824.1 ms'  │
│   maxInserterOpen    │               '892.82 ms'                │ '1487.69 ms' │
│    inserterSearch    │                 '94 ms'                  │  '47.94 ms'  │
│  minInserterSearch   │                '66.57 ms'                │  '12.17 ms'  │
│  maxInserterSearch   │               '113.23 ms'                │ '113.78 ms'  │
│    inserterHover     │               '287.52 ms'                │ '247.28 ms'  │
│   minInserterHover   │               '235.14 ms'                │ '214.89 ms'  │
│   maxInserterHover   │               '366.42 ms'                │ '299.77 ms'  │
│     listViewOpen     │               '417.39 ms'                │ '814.07 ms'  │
│   minListViewOpen    │               '263.82 ms'                │ '725.58 ms'  │
│   maxListViewOpen    │               '1203.72 ms'               │ '1444.29 ms' │
└──────────────────────┴──────────────────────────────────────────┴──────────────┘

@dmsnell dmsnell requested a review from sgomes February 6, 2023 22:39
@dmsnell
Copy link
Member Author

dmsnell commented Feb 7, 2023

Closing since this is not obviously better or worse than the profiling traces.

@dmsnell dmsnell closed this Feb 7, 2023
@dmsnell dmsnell deleted the perf/muddled-timer-vs-tracing branch February 7, 2023 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant