This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [toplevel] Toplevel bootstrap fixes 2/4, bootstrap-lean


On Dec 22, 2005, Paolo Bonzini <bonzini@gnu.org> wrote:

> Paolo Bonzini wrote:
>> This patch implements bootstrap-lean for the new toplevel bootstrap.
>> It is simple to do it by passing recursively a variable which is set
>> to either ":" (for non-lean bootstraps) or the empty string (for
>> lean bootstraps).
>> All bootstrap targets have a `lean' variation, even `bootstrap2'.
>> With this patch, as a small benefit over GCC-directory bootstrap, we
>> get profiledbootstrap-lean.

> Yesterday I forgot the patch and then the battery power exhausted
> before I could pick it up and send it, so gere it is.  I also tested
> it with a "make -j4 bootstrap-lean" to cover the possibility of race
> conditions.

> It applies on top of part 3/4, and I tested them together.

> Ok for gcc/src?

> +# Disable commands for lean bootstrap.
> +NOT_LEAN=#

I'm pretty sure this will not do what you want in the case below:

> -	  $(MAKE) stage[+id+]-start; \
> +	  $(MAKE) stage[+id+]-start; \[+IF lean +]
> +	  $(NOT_LEAN) rm -rf stage[+lean+]-* ; \
> +	  $(NOT_LEAN) $(STAMP) stage[+lean+]-lean ; \[+ ENDIF lean +]
>  	  $(MAKE) $(RECURSE_FLAGS_TO_PASS) all-stage[+id+]; \
>  	fi[+ IF compare-target +]

When you have shell comments within Makefile line continuations, at
least some makes will ellide `\\\n' so the whole thing will turn into:

          cmd ; # cmd; # cmd; fi

and then you'll get an unterminated if/then/else/fi sequence.  You
should probably go back to using `:' as in the textual description.

Other than that, it looks good to me.

-- 
Alexandre Oliva         http://www.lsd.ic.unicamp.br/~oliva/
Red Hat Compiler Engineer   aoliva@{redhat.com, gcc.gnu.org}
Free Software Evangelist  oliva@{lsd.ic.unicamp.br, gnu.org}


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]