Open RyanGlScott opened 2 months ago
Won't it still need to be a submodule of crucible (or at least want to be, for the same reasons we just added mir-json in saw)? That kind of defeats point 2. Not that this matters, since point 1 is ample reason to do this :-)
Won't it still need to be a submodule of crucible (or at least want to be, for the same reasons we just added mir-json in saw)? That kind of defeats point 2.
Yes, that is fair. Let me revise point (2), then: one disadvantage of versioning the crux-mir
standard libraries in the same repo as crucible
is that the git
history for the crux-mir
standard libraries is very large and messy, and it would be better to keep it as separate as possible. (For an example of what I'm taking about, check out the sheer number of commits from the last time we updated these standard libraries: https://github.com/GaloisInc/mir-json/pull/49)
Oof. point taken 😀
Currently, we vendor in our modified copies of the Rust standard libraries (as well as the associated
translate_libs.sh
script, which runsmir-json
on these modified standard libraries to compile them) as a subdirectory incrux-mir
. Historically, this made sense, ascrux-mir
was the sole consumer of these files. It is unclear if this arrangement makes as much sense nowadays, however, for the following reasons:crux-mir
and SAW (the latter of which now has a MIR backend) need to make use oftranslate_libs.sh
. Telling SAW users to downloadcrux-mir
for the sole purpose of runningtranslate_libs.sh
doesn't make much sense, given thatcrux-mir
is otherwise unrelated to SAW.crucible
repo. This is a bit of a shame, considering that manycrucible
developers aren't going to be using the MIR-related parts.To address both of these concerns, I propose that we factor out the modified Rust standard libraries (and
translate_libs.sh
) into a separate repo. I'll tentatively call this repo "mir-json-libs
" until I can think of something better. That way,mir-json-libs
development can live outside ofcrucible
(thereby avoiding further bloating of thecrucible
repo), and there is now a central location for further standard library modifications needed to supportcrux-mir
and SAW.