You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flex.apache.org by Christofer Dutz <ch...@c-ware.de> on 2016/12/25 16:23:14 UTC

[FlexJS] parallel compilation now possible

Hi Guys,

I just pushed my changed to the compiler, which eliminate the usage of some of the static variables for sharing compiler state. Now multiple instances of the compilers should be able to run in paralell.
With this, it is now possible to use one neat Maven option to speed up build time dramatically.

By using the config option „-T 1C“ for example Maven will execute the build of modules in paralell using a maximum of one job per CPU core. This cut down the build-time of the framework, including assembly and example compilation from 1:55 to 0:54 – so it reduced the build time about by half.
One thing you should keep in mind though. With this setting multiple module builds will run in paralell and hereby the plugins will log stuff to the console in paralell. This will make the console-output allmost useless. So if you are having build problems, be sure to turn the paralell compilation off first or I guarantee you won’t make any sense out of the output ;-)

Chris


Re: [FlexJS] parallel compilation now possible

Posted by Josh Tynjala <jo...@gmail.com>.
Good stuff. That static state definitely needed to go. Thanks for figuring
out the refactor, Chris!

- Josh

On Dec 25, 2016 8:23 AM, "Christofer Dutz" <ch...@c-ware.de>
wrote:

> Hi Guys,
>
> I just pushed my changed to the compiler, which eliminate the usage of
> some of the static variables for sharing compiler state. Now multiple
> instances of the compilers should be able to run in paralell.
> With this, it is now possible to use one neat Maven option to speed up
> build time dramatically.
>
> By using the config option „-T 1C“ for example Maven will execute the
> build of modules in paralell using a maximum of one job per CPU core. This
> cut down the build-time of the framework, including assembly and example
> compilation from 1:55 to 0:54 – so it reduced the build time about by half.
> One thing you should keep in mind though. With this setting multiple
> module builds will run in paralell and hereby the plugins will log stuff to
> the console in paralell. This will make the console-output allmost useless.
> So if you are having build problems, be sure to turn the paralell
> compilation off first or I guarantee you won’t make any sense out of the
> output ;-)
>
> Chris
>
>

Re: [FlexJS] parallel compilation now possible

Posted by Carlos Rovira <ca...@codeoscopic.com>.
thanks Chris for explanation. For what I understand there should no be
problem in parallel building regarding the examples you posted. So this
looks really good and we should not find any mess in log reports.

Thanks!


2016-12-27 20:56 GMT+01:00 Christofer Dutz <ch...@c-ware.de>:

> Hi Carlos,
>
> Maven will only build two modules in parallel, if there is no dependency
> in between them and all modules these depend on have been built. So if B
> depends on A there is no way to force both to be built in parallel. But if
> B and C both depend on A but B and C are independent from each other, Maven
> will build A first and then B and C in parallel.
>
> Hope that explains things.
>
> Chris
>
>
> Am 27.12.16, 11:16 schrieb "carlos.rovira@gmail.com im Auftrag von Carlos
> Rovira" <carlos.rovira@gmail.com im Auftrag von
> carlos.rovira@codeoscopic.com>:
>
>     Hi Chris!,
>
>     this sound pretty good! :)
>     For the parallel compilation problem, if some module depends on others,
>     there's not way to enforce compilation of depends first?
>
>     Thanks!
>
>
>
>     2016-12-25 21:15 GMT+01:00 Alex Harui <ah...@adobe.com>:
>
>     > Excellent!  Thanks for doing it.
>     >
>     > -Alex
>     >
>     > On 12/25/16, 8:23 AM, "Christofer Dutz" <ch...@c-ware.de>
> wrote:
>     >
>     > >Hi Guys,
>     > >
>     > >I just pushed my changed to the compiler, which eliminate the usage
> of
>     > >some of the static variables for sharing compiler state. Now
> multiple
>     > >instances of the compilers should be able to run in paralell.
>     > >With this, it is now possible to use one neat Maven option to speed
> up
>     > >build time dramatically.
>     > >
>     > >By using the config option „-T 1C“ for example Maven will execute
> the
>     > >build of modules in paralell using a maximum of one job per CPU
> core.
>     > >This cut down the build-time of the framework, including assembly
> and
>     > >example compilation from 1:55 to 0:54 – so it reduced the build time
>     > >about by half.
>     > >One thing you should keep in mind though. With this setting multiple
>     > >module builds will run in paralell and hereby the plugins will log
> stuff
>     > >to the console in paralell. This will make the console-output
> allmost
>     > >useless. So if you are having build problems, be sure to turn the
>     > >paralell compilation off first or I guarantee you won’t make any
> sense
>     > >out of the output ;-)
>     > >
>     > >Chris
>     > >
>     >
>     >
>
>
>     --
>
>     Carlos Rovira
>     Director General
>     M: +34 607 22 60 05
>     http://www.codeoscopic.com
>     http://www.avant2.es
>
>     Este mensaje se dirige exclusivamente a su destinatario y puede
> contener
>     información privilegiada o confidencial. Si ha recibido este mensaje
> por
>     error, le rogamos que nos lo comunique inmediatamente por esta misma
> vía y
>     proceda a su destrucción.
>
>     De la vigente Ley Orgánica de Protección de Datos (15/1999), le
> comunicamos
>     que sus datos forman parte de un fichero cuyo responsable es
> CODEOSCOPIC
>     S.A. La finalidad de dicho tratamiento es facilitar la prestación del
>     servicio o información solicitados, teniendo usted derecho de acceso,
>     rectificación, cancelación y oposición de sus datos dirigiéndose a
> nuestras
>     oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación
>     necesaria.
>
>
>


-- 

Carlos Rovira
Director General
M: +34 607 22 60 05
http://www.codeoscopic.com
http://www.avant2.es

Este mensaje se dirige exclusivamente a su destinatario y puede contener
información privilegiada o confidencial. Si ha recibido este mensaje por
error, le rogamos que nos lo comunique inmediatamente por esta misma vía y
proceda a su destrucción.

De la vigente Ley Orgánica de Protección de Datos (15/1999), le comunicamos
que sus datos forman parte de un fichero cuyo responsable es CODEOSCOPIC
S.A. La finalidad de dicho tratamiento es facilitar la prestación del
servicio o información solicitados, teniendo usted derecho de acceso,
rectificación, cancelación y oposición de sus datos dirigiéndose a nuestras
oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación
necesaria.

Re: [FlexJS] parallel compilation now possible

Posted by Christofer Dutz <ch...@c-ware.de>.
Hi Carlos,

Maven will only build two modules in parallel, if there is no dependency in between them and all modules these depend on have been built. So if B depends on A there is no way to force both to be built in parallel. But if B and C both depend on A but B and C are independent from each other, Maven will build A first and then B and C in parallel.

Hope that explains things.

Chris


Am 27.12.16, 11:16 schrieb "carlos.rovira@gmail.com im Auftrag von Carlos Rovira" <carlos.rovira@gmail.com im Auftrag von carlos.rovira@codeoscopic.com>:

    Hi Chris!,
    
    this sound pretty good! :)
    For the parallel compilation problem, if some module depends on others,
    there's not way to enforce compilation of depends first?
    
    Thanks!
    
    
    
    2016-12-25 21:15 GMT+01:00 Alex Harui <ah...@adobe.com>:
    
    > Excellent!  Thanks for doing it.
    >
    > -Alex
    >
    > On 12/25/16, 8:23 AM, "Christofer Dutz" <ch...@c-ware.de> wrote:
    >
    > >Hi Guys,
    > >
    > >I just pushed my changed to the compiler, which eliminate the usage of
    > >some of the static variables for sharing compiler state. Now multiple
    > >instances of the compilers should be able to run in paralell.
    > >With this, it is now possible to use one neat Maven option to speed up
    > >build time dramatically.
    > >
    > >By using the config option „-T 1C“ for example Maven will execute the
    > >build of modules in paralell using a maximum of one job per CPU core.
    > >This cut down the build-time of the framework, including assembly and
    > >example compilation from 1:55 to 0:54 – so it reduced the build time
    > >about by half.
    > >One thing you should keep in mind though. With this setting multiple
    > >module builds will run in paralell and hereby the plugins will log stuff
    > >to the console in paralell. This will make the console-output allmost
    > >useless. So if you are having build problems, be sure to turn the
    > >paralell compilation off first or I guarantee you won’t make any sense
    > >out of the output ;-)
    > >
    > >Chris
    > >
    >
    >
    
    
    -- 
    
    Carlos Rovira
    Director General
    M: +34 607 22 60 05
    http://www.codeoscopic.com
    http://www.avant2.es
    
    Este mensaje se dirige exclusivamente a su destinatario y puede contener
    información privilegiada o confidencial. Si ha recibido este mensaje por
    error, le rogamos que nos lo comunique inmediatamente por esta misma vía y
    proceda a su destrucción.
    
    De la vigente Ley Orgánica de Protección de Datos (15/1999), le comunicamos
    que sus datos forman parte de un fichero cuyo responsable es CODEOSCOPIC
    S.A. La finalidad de dicho tratamiento es facilitar la prestación del
    servicio o información solicitados, teniendo usted derecho de acceso,
    rectificación, cancelación y oposición de sus datos dirigiéndose a nuestras
    oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación
    necesaria.
    


Re: [FlexJS] parallel compilation now possible

Posted by Carlos Rovira <ca...@codeoscopic.com>.
Hi Chris!,

this sound pretty good! :)
For the parallel compilation problem, if some module depends on others,
there's not way to enforce compilation of depends first?

Thanks!



2016-12-25 21:15 GMT+01:00 Alex Harui <ah...@adobe.com>:

> Excellent!  Thanks for doing it.
>
> -Alex
>
> On 12/25/16, 8:23 AM, "Christofer Dutz" <ch...@c-ware.de> wrote:
>
> >Hi Guys,
> >
> >I just pushed my changed to the compiler, which eliminate the usage of
> >some of the static variables for sharing compiler state. Now multiple
> >instances of the compilers should be able to run in paralell.
> >With this, it is now possible to use one neat Maven option to speed up
> >build time dramatically.
> >
> >By using the config option „-T 1C“ for example Maven will execute the
> >build of modules in paralell using a maximum of one job per CPU core.
> >This cut down the build-time of the framework, including assembly and
> >example compilation from 1:55 to 0:54 – so it reduced the build time
> >about by half.
> >One thing you should keep in mind though. With this setting multiple
> >module builds will run in paralell and hereby the plugins will log stuff
> >to the console in paralell. This will make the console-output allmost
> >useless. So if you are having build problems, be sure to turn the
> >paralell compilation off first or I guarantee you won’t make any sense
> >out of the output ;-)
> >
> >Chris
> >
>
>


-- 

Carlos Rovira
Director General
M: +34 607 22 60 05
http://www.codeoscopic.com
http://www.avant2.es

Este mensaje se dirige exclusivamente a su destinatario y puede contener
información privilegiada o confidencial. Si ha recibido este mensaje por
error, le rogamos que nos lo comunique inmediatamente por esta misma vía y
proceda a su destrucción.

De la vigente Ley Orgánica de Protección de Datos (15/1999), le comunicamos
que sus datos forman parte de un fichero cuyo responsable es CODEOSCOPIC
S.A. La finalidad de dicho tratamiento es facilitar la prestación del
servicio o información solicitados, teniendo usted derecho de acceso,
rectificación, cancelación y oposición de sus datos dirigiéndose a nuestras
oficinas c/ Paseo de la Habana 9-11, 28036, Madrid con la documentación
necesaria.

Re: [FlexJS] parallel compilation now possible

Posted by Alex Harui <ah...@adobe.com>.
Excellent!  Thanks for doing it.

-Alex

On 12/25/16, 8:23 AM, "Christofer Dutz" <ch...@c-ware.de> wrote:

>Hi Guys,
>
>I just pushed my changed to the compiler, which eliminate the usage of
>some of the static variables for sharing compiler state. Now multiple
>instances of the compilers should be able to run in paralell.
>With this, it is now possible to use one neat Maven option to speed up
>build time dramatically.
>
>By using the config option „-T 1C“ for example Maven will execute the
>build of modules in paralell using a maximum of one job per CPU core.
>This cut down the build-time of the framework, including assembly and
>example compilation from 1:55 to 0:54 – so it reduced the build time
>about by half.
>One thing you should keep in mind though. With this setting multiple
>module builds will run in paralell and hereby the plugins will log stuff
>to the console in paralell. This will make the console-output allmost
>useless. So if you are having build problems, be sure to turn the
>paralell compilation off first or I guarantee you won’t make any sense
>out of the output ;-)
>
>Chris
>