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

Fix issue #2330 by limiting the vector size that can be reserve'd #2404

Closed
wants to merge 387 commits into from

Conversation

greg7mdp
Copy link
Contributor

Resolves #2330.

The deserialization of arrays involves reading a size, and then the array elements which are emplace'd back into a std::vector. For normal vectors, since we know the size in advance, it is beneficial to call std::vector::reserve() to prevent quadratic reallocations of the vector's buffer as the values are read. Still, limit the size that can be reserved to 1024 fc::variant values, or 16KB since sizeof(fc::variant) == 16).

heifner and others added 30 commits November 7, 2023 10:04
[5.0 -> main] PH: Improve error handling and use one strand
[5.0 -> main] Disable EOS VM OC's subjective compilation limits in unit tests
[5.0 -> main] Prometheus: Ensure valid unique_conn_node_id
[5.0 -> main] Fix chainbase issue when shrinking the database size.
…main

[5.0 -> main] Add additional tests for mapped_private
[5.0 -> main] Revert "Fix base64 encoding"
[5.0 -> main] Fix base64 encoding - take 2
[5.0 -> main] Add dynamic check for pagemap support
greg7mdp and others added 26 commits March 18, 2024 17:54
Replace hacky version of `calculate_max_depth` with simpler one.
Perf issue: avoid vector copy at each insertion.
make EOS VM signal handler less greedy: only handle signals from expected memory range
[5.0 -> main] avoid using a stack variable after return
fix `db_modes_test` when nodeos built with ASAN
[5.0 -> main] Update to latest version of BLS12 submodule with clearer conversion parameters
TraceAPI: Remove sync() to improve performance
remove executable bit from a lot of files
use github provided token for git in submodule regression check
@heifner heifner changed the base branch from main to release/5.0 August 20, 2024 17:30
@heifner
Copy link
Member

heifner commented Aug 20, 2024

Should target release/5.0

@heifner heifner closed this Aug 20, 2024
@greg7mdp greg7mdp deleted the gh_2330 branch August 20, 2024 17:33
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.

abi_tests/abi_large_array test fails with swap space less than 2GB
6 participants