Messages in this thread | | | From | Vincent MAILHOL <> | Date | Sat, 14 May 2022 12:21:24 +0900 | Subject | Re: [RFC PATCH v2 2/2] kbuild: call check-atomics.sh only if prerequisites change |
| |
On Sat. 14 May 2022 at 04:01, Masahiro Yamada <masahiroy@kernel.org> wrote: > On Sat, May 7, 2022 at 10:13 PM Vincent Mailhol > <mailhol.vincent@wanadoo.fr> wrote: > > > > check-atomics.sh is executed unconditionally. Most developers will not > > modify the files being checked by this script and thus do not need to > > execute it again for each iterative make. > > > > We first add an additional dependency to include/linux/atomic/* to > > make sure that the script gets executed again if the headers are > > modified. We then use the if_change macro instead of cmd. c.f. [1] and > > create the dot file scripts/atomic/.check-atomics which is used for > > the target timestamp. Finally, the dot file is added to the > > CLEAN_FILES target. > > > > [1] https://www.kernel.org/doc/html/latest/kbuild/makefiles.html#command-change-detection > > > > Signed-off-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr> > > > I do not like this approach. > > I wrote a different patch. > https://lore.kernel.org/lkml/20220513185340.239753-1-masahiroy@kernel.org/T/#u > > This naturally works by comparing the timestamp > between *_shipped and include/generated/*.
Thank you very much for taking the time to fully rewrite it in order to simply discard the check-atomics.sh. I like the idea.
| |