autoconf-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 09/12] use a shell function for AC_CHECK_TYPE


From: Paolo Bonzini
Subject: Re: [PATCH 09/12] use a shell function for AC_CHECK_TYPE
Date: Sat, 01 Nov 2008 18:54:11 +0100
User-agent: Thunderbird 2.0.0.17 (Macintosh/20080914)

Eric Blake wrote:
> According to Eric Blake on 10/27/2008 8:18 AM:
>> Not for this patch, but food for thought for a subsequent improvement.  We 
>> are 
>> spending quite a few forks building two different test files; it should be 
>> possible to build a single test file that does:
> 
>> if (sizeof ($[]2))
>>   return 0;
>> #ifdef AC_SECOND
>> if (sizeof (($[]2)))
>>   return 0;
>> #endif
> 
>> then invoke the compiler with -DAC_SECOND added to CFLAGS on the second run, 
>> to 
>> reduce the overhead inherent in two full-blown AC_COMPILE_IFELSE.  I don't 
>> think we can skip two separate compile runs, however, as I don't think we'll 
>> be 
>> lucky enough to accurately parse error messages to the point where we verify 
>> that the compiler only complained about the second statement.
> 
> What do you think of this patch?  It doesn't reduce the size of configure
> much (now that a single shell function body is the only place where this
> is expanded), but does remove two cat processes.  On the other hand, it
> adds an rm process, so I only see a net drop of one process per type
> check.  Maybe we can still figure out a slicker way to reduce the number
> of rm processes.

I must say I don't like it much, unless it gives a net improvement of at
least 2-3% on coreutils, say.  But I disagree on the math: doesn't it
save only one cat *but also* one rm?

Paolo




reply via email to

[Prev in Thread] Current Thread [Next in Thread]