Re: headerscheck ccache support

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: Álvaro Herrera <alvherre(at)kurilemu(dot)de>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: headerscheck ccache support
Date: 2025-12-04 11:03:22
Message-ID: 8ef4f92b-2ba3-4ccb-b437-e66b8f611c58@eisentraut.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 28.11.25 15:16, Álvaro Herrera wrote:
> On 2025-Nov-28, Peter Eisentraut wrote:
>
>> But this doesn't seem to buy very much. The overhead of the shell script to
>> write out the test files appears to become significant compared the the
>> actual compile commands.
>
> If you wanted to save some shell execution time, you could move the `tr`
> calls to the bottom of the loop to avoid doing it for files that the
> `if` block is going to discard. But is that significant? I doubt it.

This actually made a measurable difference, so I included that change in
the committed patch.

> (I didn't quite understand why you use printf instead of echo, given
> that both are shell builtins in any case.)

printf is nowadays preferable over echo in portable shell scripts. See
for example

https://cgit.git.savannah.gnu.org/cgit/autoconf.git/tree/NEWS#n435

and

https://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.72/html_node/Limitations-of-Builtins.html

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message VASUKI M 2025-12-04 11:08:40 Re: BUG #19095: Test if function exit() is used fail when linked static
Previous Message Peter Eisentraut 2025-12-04 10:59:27 Re: headerscheck ccache support