3 ms·
This sounds pretty nice. In Lisp, this would be considered a "tree shaker" (mind I don't know how they're plan to use this). Currently, we rely on the Java Mod
by whartung 3y ago
This sounds pretty nice. In Lisp, this would be considered a "tree shaker" (mind I don't know how they're plan to use this).
Currently, we rely on the Java Module system to make reduced runtimes. It works, but is necessarily coarse.
You'd think you'd be able run the application for a "suitable amount of time, and a suitable amount of use cases" and monitor what classes were loaded, etc. and use that information to make the smallest runtime possible. The addition of the sealing mechanism is a bonus, most apps simply don't need to be that configurable and flexible. You could do that analysis once, and update it manually (so you don't have to do it all the time), or have some automated service that you run routinely.
I have a simple GUI program, getting ready to distribute. It's 5000 lines of code, and has a couple of windows. Admittedly, it also includes WebKit (which alone can be large), but with all the the distribution is 70M. That's tuned using the module system, so it leaves stuff out.
That's "good". Many other cross platform solutions are larger.
It would be great for something like this to knock that down to 20M (cough).
- ezst 3y agoI bet a majority of those 70M is WebKit itself, and I don't think there's any way to "condense" any of this since it lives outside of the JVM.
- whartung 3y agoAfter some very quick butchery, WebKit turns out to be about 30M of it, just so you know next time you're at a party and it comes up during a drinking game, or something. I wonder how hard it would be to write a simple ("simple") HTML renderer enough to show my documentation (which is all I use it for). "Look a rabbit hole! Let's go inside!!"