You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently Rust package manager has to build each dependency in the host, this can take minutes and is very inefficient, for example the most common way to build rust Docker images is to build all the dependencies from scratch each time.
The cause of this issue is that Rust doesn’t have a stable ABI between compiler versions, from rust-lang/cargo#1139 (comment)
This is a Rust problem even more than a Cargo problem. You can't guarantee that a pre-built Rust library will work unless it's built with the exact same SHA of the compiler.
I think this problem is possible to fix if taken in consideration early in development, if Mojo can build libraries that can be used across compiler versions the package manager could be many orders of magnitudes more efficient:
For example you could move the compilation of dependencies from the host computer to the package manager servers, instead of building a dependency thousands of times for each host you build it only once for each architecture triplet and cache it. This is even more impactful for dependencies that depend on c libraries, just install them in the package manager instead of the host computer.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Currently Rust package manager has to build each dependency in the host, this can take minutes and is very inefficient, for example the most common way to build rust Docker images is to build all the dependencies from scratch each time.
The cause of this issue is that Rust doesn’t have a stable ABI between compiler versions, from rust-lang/cargo#1139 (comment)
I think this problem is possible to fix if taken in consideration early in development, if Mojo can build libraries that can be used across compiler versions the package manager could be many orders of magnitudes more efficient:
For example you could move the compilation of dependencies from the host computer to the package manager servers, instead of building a dependency thousands of times for each host you build it only once for each architecture triplet and cache it. This is even more impactful for dependencies that depend on c libraries, just install them in the package manager instead of the host computer.
Beta Was this translation helpful? Give feedback.
All reactions