measure deferred_decl bucket sizesnightly-2020.11.08
commit0aec6753bc09452a88e8456bd212f177ef2caebc
authorLucian Wischik <[email protected]>
Sat, 7 Nov 2020 19:16:40 +0000 (7 11:16 -0800)
committerFacebook GitHub Bot <[email protected]>
Sat, 7 Nov 2020 19:26:22 +0000 (7 11:26 -0800)
treefef45d2744e432df12dce3898eddb2d5eb994168
parentb5644b79824a1e05c64bace27b6671a923e4589a
measure deferred_decl bucket sizes

Summary:
The earlier diff in this stack introduced telemetry about job sizes from the multiworker typechecker.

I noticed a discrepancy there, when I did a full init, where it claimed the total number of files processed was larger than the number of files in WWW.

The reason for that discrepancy is deferred_decls. It did indeed "process" more files than there are files in WWW, but it only *completed typechecking* of the same number of files as in WWW.

This diff adds telemetry about deferred decls:
* how many files all-up were processed
* how many Check workitems were completed, and how many were deferred until later, and for that deferral how many Decl items were queued up for later
* how many Prefetch workitems were done
* how many Decl workitems were done

The numbers all look reasonable, and pretty much what you'd expect. The total number of checks_done adds up to the total number of php files in WWW.
```
1596 finished_to_end.checks_done.count * 876.543 finished_to_end.checks_done.mean = 1,398,963 finished_to_end.checks_done
2652 finished_early.checks_done.count * 456.7 finished_early.checks_done.mean = 1,211,251 finished_early.checks_done

SUM = 2,422,051 files
```

Reviewed By: CatherineGasnier

Differential Revision: D24771690

fbshipit-source-id: f296e0a75d82543fe9380103a1b5afdd53067a36
hphp/hack/src/typing/typing_check_service.ml