[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAK7LNAS+3gq-uL6HF=o2NbZ2udkr+dqAhsvs-XxFs0M9wShJbw@mail.gmail.com>
Date: Thu, 26 Mar 2020 15:13:50 +0900
From: Masahiro Yamada <masahiroy@...nel.org>
To: Nick Desaulniers <ndesaulniers@...gle.com>
Cc: Linux Kbuild mailing list <linux-kbuild@...r.kernel.org>,
"David S . Miller" <davem@...emloft.net>,
Network Development <netdev@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>,
Michal Marek <michal.lkml@...kovi.net>,
clang-built-linux <clang-built-linux@...glegroups.com>
Subject: Re: [PATCH 3/3] kbuild: remove AS variable
Hi Nick,
On Wed, Mar 25, 2020 at 4:59 AM Nick Desaulniers
<ndesaulniers@...gle.com> wrote:
>
> On Tue, Mar 24, 2020 at 12:38 PM Nick Desaulniers
> <ndesaulniers@...gle.com> wrote:
> > consistent in this regard (and not using the compiler as the driver),
>
> Ah, the preprocessor; we need to preprocess the .S files, .s files are
> fine (though we have .lds.S files that are not `-x
> assembler-with-cpp`)
Right, there is no '*.s' source file in the kernel tree.
If we want to de-couple $(AS), we must the compilation
before the assemble stage ( $(CC) -S ), but
doing so does not buy us.
So, $(CC) always works as the front-end
for compiling both .c and .S files.
You can see the internal database by
'make --print-data-base'.
I see the following for *.S -> *.o rule.
# default
COMPILE.S = $(CC) $(ASFLAGS) $(CPPFLAGS) $(TARGET_MACH) -c
So, using $(CC) is the right thing.
Even if we keep AS, we cannot do like AS=llvm-as
since llvm-as is a different kind of tool
that processes LLVM assembly (.ll) .
--
Best Regards
Masahiro Yamada
Powered by blists - more mailing lists