Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Merged by Bors] - Shrink size of IndexedProperties #2757

Closed
wants to merge 2 commits into from

Conversation

HalidOdat
Copy link
Member

@HalidOdat HalidOdat commented Mar 28, 2023

Most objects don't have indexed properties, and those who have, have dense properties, this PR uses ThinVec to reduce the size of dense properties.

It changes the following:

  • Trim 16 bytes from IndexedProperties, this reduces all objects size

@HalidOdat HalidOdat added performance Performance related changes and issues execution Issues or PRs related to code execution labels Mar 28, 2023
@HalidOdat HalidOdat added this to the v0.17.0 milestone Mar 28, 2023
@HalidOdat HalidOdat changed the title Shrink size of IndexedProperties Shrink size of IndexedProperties Mar 28, 2023
@github-actions
Copy link

Test262 conformance changes

Test result main count PR count difference
Total 94,277 94,277 0
Passed 71,094 71,094 0
Ignored 17,324 17,324 0
Failed 5,859 5,859 0
Panics 0 0 0
Conformance 75.41% 75.41% 0.00%

@codecov
Copy link

codecov bot commented Mar 28, 2023

Codecov Report

Merging #2757 (b5ac5af) into main (ceaea32) will increase coverage by 0.24%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #2757      +/-   ##
==========================================
+ Coverage   50.81%   51.06%   +0.24%     
==========================================
  Files         400      396       -4     
  Lines       40121    39939     -182     
==========================================
+ Hits        20387    20394       +7     
+ Misses      19734    19545     -189     
Impacted Files Coverage Δ
boa_gc/src/trace.rs 75.00% <ø> (ø)
boa_engine/src/builtins/array/mod.rs 76.27% <100.00%> (ø)
boa_engine/src/object/property_map.rs 55.59% <100.00%> (ø)

... and 17 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Member

@Razican Razican left a comment

Choose a reason for hiding this comment

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

I guess this should help with performance, cool!

Copy link
Member

@jedel1043 jedel1043 left a comment

Choose a reason for hiding this comment

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

Just a small nitpick. Good optimization :)

boa_engine/src/object/property_map.rs Outdated Show resolved Hide resolved
@jasonwilliams
Copy link
Member

Good optimization

@HalidOdat HalidOdat requested a review from jedel1043 March 29, 2023 22:29
Copy link
Member

@jedel1043 jedel1043 left a comment

Choose a reason for hiding this comment

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

Good work!

@jedel1043
Copy link
Member

Probably needs a rebase cause of #2762

@HalidOdat HalidOdat force-pushed the thin-indexed-properties branch from 024d841 to b5ac5af Compare March 30, 2023 05:28
@HalidOdat
Copy link
Member Author

bors r+

bors bot pushed a commit that referenced this pull request Mar 30, 2023
Most objects don't have indexed properties, and those who have, have dense properties, this PR uses `ThinVec` to reduce the size of dense properties.

It changes the following:
- Trim `16` bytes from `IndexedProperties`, this reduces all objects size
@bors
Copy link

bors bot commented Mar 30, 2023

Pull request successfully merged into main.

Build succeeded:

@bors bors bot changed the title Shrink size of IndexedProperties [Merged by Bors] - Shrink size of IndexedProperties Mar 30, 2023
@bors bors bot closed this Mar 30, 2023
@bors bors bot deleted the thin-indexed-properties branch March 30, 2023 07:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
execution Issues or PRs related to code execution performance Performance related changes and issues
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants