"make check" times

Carlos O'Donell carlos@redhat.com
Wed Apr 1 03:37:56 GMT 2020


On 3/11/20 3:32 PM, DJ Delorie via Libc-alpha wrote:
> 
> Pinging this ancient patch, now that I've finished the build times
> report which answers the questions asked about this:
> 
> Original patch thread:
> https://sourceware.org/pipermail/libc-alpha/2019-July/105187.html
> Build times report thread:
> https://sourceware.org/pipermail/libc-alpha/2020-March/111782.html
> 
> DJ Delorie <dj@redhat.com> writes:
>> While digging for some low-hanging fruit in "make" times, I did this:
>>
>> diff --git a/scripts/merge-test-results.sh b/scripts/merge-test-results.sh
>> index 919bbae253..7088ef6996 100755
>> --- a/scripts/merge-test-results.sh
>> +++ b/scripts/merge-test-results.sh
>> @@ -35,7 +35,11 @@ case $type in
>>      subdir=${subdir:+$subdir/}
>>      for t in "$@"; do
>>        if [ -s "$objpfx$t.test-result" ]; then
>> -	head -n1 "$objpfx$t.test-result"
>> +	  #head -n1 "$objpfx$t.test-result"
>> +	  exec 6<"$objpfx$t.test-result"
>> +	  read line <&6
>> +	  echo $line
>> +	  exec 6<&-
>>        else
>>  	echo "UNRESOLVED: $subdir$t"
>>        fi
>>
>> That one instance of "head" is called over 6000 times per "make
>> check", and as it's the only non-builtin in that script, it adds about
>> 11 seconds of overhead compared to just reading that one line with
>> builtins.
>>
>> My question here is: how much of a time savings is worth the
>> complexity of said savings?
> 

This is worth it.

OK for master.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>

-- 
Cheers,
Carlos.



More information about the Libc-alpha mailing list