Skip to content

chore(memory): sort all by retainer size#1963

Open
Lightning00Blade wants to merge 5 commits intomainfrom
sort-nodes
Open

chore(memory): sort all by retainer size#1963
Lightning00Blade wants to merge 5 commits intomainfrom
sort-nodes

Conversation

@Lightning00Blade
Copy link
Copy Markdown
Collaborator

@Lightning00Blade Lightning00Blade commented Apr 27, 2026

This is a better measurement as if object self size is X and the retainerSize Y. X will always be smaller then Y, there Y will be the actual size on the Heap.

@Lightning00Blade Lightning00Blade changed the title chore(memory): sort nodes by size chore(memory): sort all by retainer size Apr 27, 2026
@Lightning00Blade Lightning00Blade requested a review from OrKoN April 27, 2026 20:23
@@ -1,31 +1,4 @@
exports[`THIRD_PARTY_NOTICES > matches snapshot if exists 1`] = `
Name: urlpattern-polyfill
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you need to revert this change


#getSortedAggregates(): AggregatedInfoWithUid[] {
return Object.values(this.#aggregates).sort((a, b) => b.self - a.self);
return Object.values(this.#aggregates).sort((a, b) => b.maxRet - a.maxRet);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we re-use any code from the dtf to handle the various sorting and lookups?

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.

2 participants