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

Clean up and streamline snapshot data structures #55906

Merged
merged 8 commits into from
Nov 25, 2018

Commits on Nov 25, 2018

  1. Update to ena 0.11.0.

    This version has some significant speed-ups relating to snapshotting.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    1e34dfc View commit details
    Browse the repository at this point in the history
  2. Remove insert_noop.

    Because it's as useless as its name suggests.
    
    This commit also renames `UndoLog::Noop` as `UndoLog::Purged`, because
    (a) that's a more descriptive name and (b) it matches the name used in
    similar code in `librustc/infer/region_constraints/mod.rs`.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    9847b5c View commit details
    Browse the repository at this point in the history
  3. Rename UndoLogEntry as UndoLog.

    So that it matches `librustc_data_structures/snapshot_map/mod.rs` and
    the `ena` crate.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    c86bbd4 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    7fe09a6 View commit details
    Browse the repository at this point in the history
  5. Make commit and rollback_to methods take ownership of the snapshots.

    Because they shouldn't be reused. This provides consistency with the
    `ena` crate.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    f5624e4 View commit details
    Browse the repository at this point in the history
  6. Introduce in_snapshot and assert_open_snapshot methods.

    This makes the two snapshot implementations more consistent with each
    other and with crate `ena`.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    f23c969 View commit details
    Browse the repository at this point in the history
  7. Remove OpenSnapshot and CommittedSnapshot markers from `SnapshotM…

    …ap`.
    
    They're not strictly necessary, and they result in the `Vec` being
    allocated even for the trivial (and common) case where a
    `start_snapshot` is immediately followed by a `commit` or `rollback_to`.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    2d68fa0 View commit details
    Browse the repository at this point in the history
  8. Remove OpenSnapshot and CommittedSnapshot markers from `RegionCon…

    …straintCollector`.
    
    They're not strictly necessary, and they result in the `Vec` being
    allocated even for the trivial (and common) case where a
    `start_snapshot` is immediately followed by a `commit` or `rollback_to`.
    
    The commit also removes a now-unnecessary argument of
    `pop_placeholders()`.
    nnethercote committed Nov 25, 2018
    Configuration menu
    Copy the full SHA
    94967ae View commit details
    Browse the repository at this point in the history