Preliminary work on jdk build time improvements
Kelly.Ohair at Sun.COM
Tue Sep 15 19:26:32 PDT 2009
Brad Wetmore wrote:
> This is a great optimization.
> A couple comments.
> Haven't quite figured out why if MAKELEVEL=0 you export $1:=$2, but only
> export $1 if MAKELEVEL != 0. Sure there's a good reason why, doc'ing it
> would be appreciated.
The $2 is the thing you don't want evaluated on submakes.
I'll expand the comments on this before I'm done.
> 48/49: (if $(strip $1)...
> according to the gnumake docs:
> $(if condition,then-part[,else-part])
> The first argument, condition, first has all preceding and trailing
> whitespace stripped, then is expanded...
> I don't think you need to specifically strip.
That documentation fooled me too. The strip is needed, I suspect
that it may be doing the strip before it evaluates the argument, and if
the argument expands into " xyz", the space is still there.
So I found that I had to use an explicit strip for it to work.
> I like the $(or...) mods. Cleans up the logic very nicely.
Yeah, I thought so too.
> Not sure why you added 2 spaces of indention on lines 85-87.
Yeah, I'll delete that.
The define/endef constructs are whitespace preserving, so they
really should not be indented, but in general I prefer to indent
the makefile logic if I can, makes it easier to read.
But this entire block should not be indented.
Thanks for the review.
> Kelly O'Hair wrote:
>> Here is a preliminary (and incomplete) webrev on some changes
>> I've been working on to reduce the build time.
>> 6875240: Reduce Makefile build time by limiting repeated exec's
>> (mostly for cygwin building)
>> The Windows cygwin builds will benefit the most on this, but
>> all platforms will get some benefits.
>> Comments and suggestions on this are welcome.
More information about the build-dev