Skip to content

A simple program involving BTreeSet runs out of memory #705

Closed

Description

@zhassan-aws

I tried this code:

use std::collections::BTreeSet;

fn main() {
    let mut set = BTreeSet::<u32>::new();
    set.insert(0);
}

using the following command line invocation:

rmc test.rs --unwind 2

with RMC version: 8de5cd67609

CBMC memory usage went up to 20GB after 1 minute and reached ~30 GB shortly after.

Activity

  1. added
    [C] Bug
    on Dec 17, 2021
  2. added
    [E] Performance
    and removed
    [C] Bug
    on Mar 14, 2022
  3. zhassan-aws commented on Apr 7, 2022

    @zhassan-aws
    ContributorAuthor

    This got fixed by f088f9c, in particular the switch to use assert-false-assume-false for undefined functions as opposed to just assert-false.

  4. zhassan-aws commented on Nov 16, 2022

    @zhassan-aws
    ContributorAuthor

    Reopening: with e4851c1, memory usage exceeds 20 GB with an unwind of 3. With an unwind of 2, it finishes in a few minutes, but an unwinding assertion fails.

  5. tautschnig commented on Nov 16, 2022

    @tautschnig
    Member

    The changes in #1676 make an unwinding 2 terminate in 2.4 seconds (with the expected unwinding failure). An unwinding of 3 takes 3.1 seconds, no more unwinding failures.

  6. added
    T-CBMC
    on Dec 6, 2022
  7. added a commit that references this issue on Dec 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-CBMC[E] Performance

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions