Skip to content

Add save/load methods for LLVMPointsToSet #411

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

Closed
ga0 opened this issue Aug 5, 2021 · 1 comment
Closed

Add save/load methods for LLVMPointsToSet #411

ga0 opened this issue Aug 5, 2021 · 1 comment

Comments

@ga0
Copy link
Contributor

ga0 commented Aug 5, 2021

Is your feature request related to a problem? Please describe.
LLVMPointsToSet takes too much time.

Describe the solution you'd like
Since parallelize LLVMPointsToSet is too hard ( #305 ), providing methods to serialize/deserialize or save/load LLVMPointsToSet may be very useful.

    ProjectIRDB IRDB({path});
    LLVMPointsToSet PTS(IRDB, false, PointerAnalysisType::CFLAnders);
    std::ofstream PointsToSetCacheFile("/tmp/points_to_set");
    PTS.save(PointsToSetCacheFile);

Next time when we want to analyze the same project.

    ProjectIRDB IRDB({path});
    LLVMPointsToSet PTS(IRDB);
    std::ifstream PointsToSetCacheFile("/tmp/points_to_set");
    PTS.load(PointsToSetCacheFile);

This will save much time.

The PointsToSetMap is an unordered_map of llvm::Value* pointers.
I don't known how to serializing these pointers' relations.
Can you give me some instructions?

@fabianbs96
Copy link
Member

Updates are in #441

@MMory MMory closed this as completed May 6, 2022
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

No branches or pull requests

3 participants