Skip to content

Commit

Permalink
docs: add example traces
Browse files Browse the repository at this point in the history
  • Loading branch information
JoshuaKGoldberg committed Jul 17, 2024
1 parent f99537b commit 8b4df05
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,27 @@ See [typescript-eslint/typescript-eslint#9571 Performance: parserOptions.project
- Example measurements taken on an M1 Max Mac Studio with Node.js 22.4.1
- These results are similar across TypeScript versions: 5.0.4, 5.4.5, and 5.5.3

### Tracing Measurements

See example `traces/Project 1 - Service 2.cpuprofile`.
It was generated with:

```shell
cd cases/files-1024-layout-even-singlerun-true-types-project
node --inspect-brk ../../node_modules/eslint/bin/eslint.js
cd ../files-1024-layout-even-singlerun-true-types-service
node --inspect-brk ../../node_modules/eslint/bin/eslint.js
```

Comparing equivalent code paths:

| Code Path | Project | Service |
| ----------------- | ------- | ------- |
| All `verifyText`s | 2040ms | 2859ms |
| `parseForESLint` | 993ms | 1090ms |

You might consider using [0x](https://github.com/davidmarkclements/0x) for nice flamegraph visuals.

## Contributors

<!-- spellchecker: disable -->
Expand Down
1 change: 1 addition & 0 deletions traces/Project 1 - Service 2.cpuprofile

Large diffs are not rendered by default.

0 comments on commit 8b4df05

Please sign in to comment.