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

Optimize storage for segment information #51383

Merged
merged 5 commits into from
Feb 23, 2021

Commits on Feb 21, 2021

  1. Configuration menu
    Copy the full SHA
    3ea92b2 View commit details
    Browse the repository at this point in the history
  2. Run benchmarks on net5.0

    sharwell committed Feb 21, 2021
    Configuration menu
    Copy the full SHA
    4efde53 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    da87848 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    15e1fd3 View commit details
    Browse the repository at this point in the history

Commits on Feb 22, 2021

  1. Revert "Further optimize SegmentedArray<T> indexer for net5.0"

    There were two situations where the previous code would allow net5.0
    execution to access memory outside array bounds:
    
    1. Replacement of an element in _items with a shorter array. Even though
    _items is indirectly exposed through SyncRoot, this is not a serious
    concern because replacement of an array element means unsafe/bad
    bytecode is already running in the process to perform the replacement.
    
    2. A torn read of SegmentedArray<T> could allow a read of the _items
    field of one structure and the _length field of a different structure.
    This is a concern because it allows concurrent execution to reach a
    state where memory safety is violated without a precondition that unsafe
    code be running.
    
    This reverts commit 15e1fd3.
    sharwell committed Feb 22, 2021
    Configuration menu
    Copy the full SHA
    ddc674a View commit details
    Browse the repository at this point in the history