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

Laziness and Sharing #5

Open
ejgallego opened this issue Sep 23, 2021 · 0 comments
Open

Laziness and Sharing #5

ejgallego opened this issue Sep 23, 2021 · 0 comments

Comments

@ejgallego
Copy link
Owner

This is a general issue to discuss laziness and sharing w.r.t. the seralization of objects.

A motivating example is the following usual Coq snippet:

type a = { foo : bar (* some data *) ; env : Environ.env}

now imagine we have in Python, an object a of type a_class, with methods a.foo and a.env.

It would be great if we could avoid the conversion of a.env until it is actually accessed, as env is actually a huge object. That would mean which a.foo could be done quickly.

A problem we have with the delay in indeed the imperative nature of some code. So that approach, could be only used for objects that we mark as "safe" [that is to say, purely functional so themselves are closed].

Another approach could be actually to use some form of sharing, as done in the OCaml "runtime"; however, this may still be too expensive in some use cases.

Improvements on this pattern are also due in Coq's side.

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

1 participant