# editor: Improve performance of \`update_visible_edit_prediction\` \(\#44161\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/93bc6616c697bee1ecf178e41597f0b294b0826b)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 93bc6616c697bee1ecf178e41597f0b294b0826b

Requested commit: 93bc6616c697bee1ecf178e41597f0b294b0826b

Commit: 93bc6616c697bee1ecf178e41597f0b294b0826b

Tree: 38e00e25dfb4a861fd4bf99e741c7e0ab1558dc9

Author: Lukas Wirth

Committer: GitHub

## Message

```
editor: Improve performance of `update_visible_edit_prediction` (#44161)

One half of https://github.com/zed-industries/zed/issues/42861

This basically reduces the main thread work for large enough json (and
other) files from multiple milliseconds (15ms was observed in that test
case) down to microseconds (100ms here).

Release Notes:

- Improved cursor movement performance when edit predictions are enabled
```

## Parents

- [a33e8819066331c12f2d025d1de789cb41375c8b](https://git.cafe/gitcafe/zed/commit/a33e8819066331c12f2d025d1de789cb41375c8b?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/93bc6616c697bee1ecf178e41597f0b294b0826b?format=markdown)
