perf: optimize performance of the DoubleLinkedList get#1220
perf: optimize performance of the DoubleLinkedList get#1220YunFeng0817 merged 2 commits intorrweb-io:masterfrom
Conversation
🦋 Changeset detectedLatest commit: d4e1a64 The changes in this PR will be included in the next version bump. This PR includes changesets to release 8 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Hi. Recently we were looking into the same issue it seems. I was just about to open a PR when I noticed yours. We came up with a pretty similar change in the end. The one difference is that instead of building the array of I could share a diff if you are interested. |
|
@charliegracie Sure, I am really really interested in your change and it seems more elegant than this. |
4464146 to
80ceb0e
Compare
|
@YunFeng0817 @charliegracie I updated this PR with the tail pointer scheme and updated the benchmark tests. According to the last benchmark test( Could your please help me review this change at your convenience? |
YunFeng0817
left a comment
There was a problem hiding this comment.
@charliegracie Could you please also take a look at this? Is this similar to your solution?
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
* perf: optimize performance of the DoubleLinkedList get * fix: delete addedNodeIndexArr
benchmark-dom-mutation.html
almost the same
before:
after:
benchmark-dom-mutation-add-and-remove.html
almost the same
before:
after:
benchmark-dom-mutation-multiple-descendant-add.html
almost the same
before:
after:
benchmark-dom-mutation-add-and-move.html
decrease by about 86.11%
before:
after: