From: Sascha H. <sa...@xm...> - 2010-08-31 16:19:27
|
Panayotis, just to understand your proposal: Are you talking about trying to reduce the amount of code we need to translate based on a call graph analysis? Thus throwing out methods that are never called in an application and classes that are never referenced? // Sascha On Tue, Aug 31, 2010 at 5:54 PM, Panayotis Katsaloulis < pan...@pa...> wrote: > After the talk about Scala under iPhone, and since the Scala library is too > big (~8MB), I thought to have a look at java shrinkers. > > Since most people were talking about ProGuard & Android projects, I give it > a shot. > If this is successful enough, this will be a gain not only for Scala or > whatever, but also for OpenJDK and similar approaches that depend on other > JAR files :) > > I have to say that I was quite successful with ProGuard. It works even for > strangely crafted classes, like the Scala's ones. > The only problem with ProGuard is that it performs a quick class-based > optimization only. For a simple hello-world application (with some > Scala-based features), it required ~350kb of classes from the Scala > framework (from a total of ~6MB library). Not bad, but not good enough. > > I also had a look at yGuard, which is a free (but not completely open > source) project, which performs method- and variable- based optimizations. > Unfortunately I wasn't lucky, at least with Scala projects, it crashed with > a message: > "yShrink encountered an unknown problem!" > > In ProGuard site there is a list of other shrinkers. Of course we heading > only for open source, or at least free implementations. > Here is the list: > http://proguard.sourceforge.net/alternatives.html > Since ProGuard does a good job with class-based shrinking, we are actually > looking for method-based shrinking. > Even if this is too slow, we could have ProGuard make a pre-selection of > classes and then let the second library do the mathod-based selection. > > What do you think? I believe that this task is really necessary and will > help a lot with every project, especially with the new upcoming C backend, > but it needs testers ;) > > ------------------------------------------------------------------------------ > This SF.net Dev2Dev email is sponsored by: > > Show off your parallel programming skills. > Enter the Intel(R) Threading Challenge 2010. > http://p.sf.net/sfu/intel-thread-sfd > _______________________________________________ > xmlvm-users mailing list > xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlvm-users > |