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

[feature tracking] Workflow for iterating on a compiler development branch? #19

Open
gasche opened this issue Apr 27, 2021 · 1 comment

Comments

@gasche
Copy link

gasche commented Apr 27, 2021

Currently the opam-compiler README says:

To iterate on a compiler feature and try opam packages at the same time, it supports to ways to reinstall the compiler: either a safe and slow technique that will reinstall all packages, or a quick way that will just overwrite the compiler in place.

but as far as I understand the "quick way" is not implemented yet. This would be a convenient feature when doing compiler development that requires testing on opam packages -- it was the central feature of opam-compiler-conf. We discussed this briefly on Discuss.

I'm opening the present issue to track progress on this feature (if there is interest among opam-compiler developers, no pressure!), as suggested by @avsm in ocaml/ocaml#9632 (comment).

Note: I should point out that this feature is very useful for certain cases of working with the compiler, but that these use-cases are pretty rare. It matters for problems where we need to iterate on the compiler, test on an opam package, and we are confident that the hard-reinstall will preserve the semantics. I've done this in the past to debug and fix compiler issues that break an opam package (a typing issue, a compile-time blowup, a runtime failure, etc.), but I haven't used it myself in the last couple years; other people have (@lthls has developed his own script for this in ocaml/ocaml#9632 ). In the more common cases, we can isolate the issue on a short reproduction case without dependencies, and iterate without needing an opam environment. (And in the bad cases, we need the compiler changes to affect all compiler files, so we need a "full" reinstall anyway.)
I think that it's about a handful of people using it sporadically over years -- but when we need this workflow it is very useful.

@avsm
Copy link

avsm commented Apr 28, 2021

Thanks for creating this issue @gasche. I'll selfishly bump this higher up the priority stack since it's extremely useful for multicore compiler development (where recompiling opam universes happens all the time with compiler changes).

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

2 participants