How to speed up the GWT compiler ? (Part III)

by Olivier on Jul 31st in Uncategorized

English version

To speed up GWT compiler, the main idea is to reduce GWT permutations.

To manage the permutations, I build my own version of GWT 1.5 named GWT 1.5 r2030-olivier.

I am using 1.5 M1:

  • svn co http://google-web-toolkit.googlecode.com/svn/trunk -r2030
  • Edit I18N.gwt.xml to remove default locale and force "fr_FR" as "default" locale
Index: trunk/user/src/com/google/gwt/i18n/I18N.gwt.xml
===================================================================
--- trunk/user/src/com/google/gwt/i18n/I18N.gwt.xml     (revision 2030)
+++ trunk/user/src/com/google/gwt/i18n/I18N.gwt.xml     (working copy)
@@ -18,7 +18,7 @@

        
        
-       
+       

                
  • Edit UserAgent.gwt.xml and, in my case, remove unused some browsers : safari, opera, gecko (old firefox/mozilla)
Index: trunk/user/src/com/google/gwt/user/UserAgent.gwt.xml
===================================================================
--- trunk/user/src/com/google/gwt/user/UserAgent.gwt.xml        (revision 2030)
+++ trunk/user/src/com/google/gwt/user/UserAgent.gwt.xml        (working copy)
@@ -19,7 +19,7 @@
 

   
-  
+  
= 6000) {
@@ -44,7 +40,6 @@
           if (makeVersion(result) >= 1008)
             return "gecko1_8";
           }
-        return "gecko";
       }
       return "unknown";
   ]]>

With my own build, GWT compiler speeds up my project compilation :

  • 12mn with GWT 1.5 r2030
  • 4mn with GWT 1.5 r2030-olivier
  • 1m15s with GWT 1.5 r2030-olivier + no additional locale
  • 1mn with GWT 1.5 r2030-olivier + no locale + gecko1_8

This is an amazing gain : 12mn to 1mn

French version

Coming soon.

Tags

3 Comments

  1. Sanjeev Kulkarni

    24th February 2009

    It was nice topic I gonna try this and let you know about my experiments.Thanks for such a useful topic

  2. electronicpeter

    13th August 2009

    Hi, thanks. For me it reduced compile time from 2:45 to 0:45.
    After switching i18n from two languages to the default language, the time was reduced to 1:10!
    Changing to gecko only made the rest.

    BTW: though gwt1.7 is released, i still work with 1.5, because my experience was, that my compiletime increased from 1.5 to 1.6 from 2:45 to 4:00.

  3. mike

    18th September 2009

    You can also use the regular build and add specify which locals and browsers you want to be compiled in the module.xml file.
    http://vinaytech.wordpress.com/2008...

Leave a Reply

Please note: Comment moderation is enabled and may delay your comment.

Powered By Wordpress Designed By Ridgey