I don't have anything great written up, but here's the gist of it:

Currently, when you do a web mode compile, JDT actually runs twice.  First,
it runs from CompilationStateBuilder and compiles all the source code in
your project.  The output of this is used to build TypeOracle, which is a
reflection-like view of your type model, used by Generators.  This output is
also used for running dev mode.

After all this is done and the JavaToJavaScriptCompiler starts to run, it
actually fires up a second JDT compile-- this recompiles your source files
into one giant, interconnected GWT AST.

The change I'm working on would cut this down to one JDT compile.  During
CompilationState's build, the plan is to analyze each independent unit
(compiled .java file) and produce one partial, disconnected AST per
compilation unit.  Then when it's time to kick off the compiler, we just
grab those independent ASTs and stitch them together, resolving all
references to create the interconnected AST.

This should hopefully cut down on compile time, especially for draft
compiles.  It would also enable us to do a few more tricks in the future,
such as caching compiled .ast files on disk, or even embedded precompiled
.ast files into, say, gwt-user.jar so we don't have to recompile the source
files included with GWT.


On Wed, Jan 26, 2011 at 2:59 PM, Grzegorz Kossakowski <
[email protected]> wrote:

> It looks like you are working on something that might be interesting to me.
>
> Is there any place I can find more information on this change?
>
> --
> http://groups.google.com/group/Google-Web-Toolkit-Contributors

-- 
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to