-
Notifications
You must be signed in to change notification settings - Fork 273
Java frontend needs to be lazier converting methods #284
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
Comments
Yes, indeed! Please keep me up-to-date. |
cristina-david@04a0ca5 and cristina-david@a9fe0bf provide a rough sketch of what we could do without much effort. They shrink the memory requirement for the basic program above to 1.2GB, which is of course still not good, but at least it's loadable (in around 2 seconds). I'll put pull request against master together once I'm happy it's reliable. It still can't be fed into CBMC however because it does lots of unwinding and unrolling down paths that build exception error messages in the standard library. They could perhaps be blacklisted to make including |
This is extended a little further in my branch |
Committed to master in #407 |
…erate_empty_jar SEC-142: Bugfix: prevent generation of empty JAR (when no class files are found).
…rry-pick FP constant folding fix cherry pick
At present the Java frontend walks the classpath looking for any type reference and converting any method defined on such a type. When the standard library JAR is available this results in far too much getting loaded, due to obscure references that most programs don't use-- for example, loading all of
java.lang.System
due to some trivial reference in a deserialization routine. To improve on this I am currently working on a simple lazy loading scheme, where all methods are initially stubbed, and then each is converted only when we find a call that may reach it (including through virtual dispatch). For example the following program currently runs out of memory when the standard library is available to parse:With these changes the dependencies for simple construct, add and get should hopefully be much smaller.
Note that the types are still loaded eagerly, for simplicity-- only method bodies are populated on demand.
The text was updated successfully, but these errors were encountered: