Skip to content

Performance issue: pycpa forces a full garbage collection after every propagation step #15

@IDA-TUBS

Description

@IDA-TUBS

Original report by Anonymous.


See https://bitbucket.org/pycpa/pycpa-git/src/9127bab/pycpa/analysis.py#lines-685

At least on my system, this can be really slow (removing this line reduced analysis time from 12 seconds to 100 milliseconds for my model under analysis).

Johannes already told me that this is necessary for very large task graphs, because Python apparently does not run the garbage collector when it runs out of memory.
To address both use cases, it might make sense to add an optional argument (or check gc.isenabled()) to allow users to opt in or out of the garbage collection. It might also be worthwhile to check if collecting the younger generations suffices.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions