From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E5D6FC7EE37 for ; Tue, 6 Jun 2023 22:42:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239957AbjFFWmt (ORCPT ); Tue, 6 Jun 2023 18:42:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36660 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234076AbjFFWmq (ORCPT ); Tue, 6 Jun 2023 18:42:46 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6553811A for ; Tue, 6 Jun 2023 15:42:45 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id EC043638A5 for ; Tue, 6 Jun 2023 22:42:44 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id D6F22C433EF; Tue, 6 Jun 2023 22:42:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686091364; bh=+n808blosC/qLl1eZ4095f2Bmo/aBhslqGveoyXYm2Y=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eFY/e0XpVlocWZkoUScoOR7yNC7lgB+fnWMjacweQWFGKIXr09adD5f6NZHXIEfXi Qx1/AUEvMwilU3+jU2whAbqlRzBQgGXcCWhVwbHw3qtxFZQ1aRwsCVhxBWQyQAwifF MxTXAYkX+FExjudRnmA1Dv8CxIJDiHPspu6gmqpbkKFFw+iOD7ApqXpyRPFU3bbygH osSzhDQD37uKhoQ9/E3TE6DMbhGiSNKosQWO8U9msnsRC6FJoSL5p1HUaHwkvlmb1F C+3lBR78LwEemt+xquwrghiJ3qSGROCWTvDgxtwOnDYUcm+wLbWmCvbOk8G26gjvB5 WE7NdINyXKK8A== Date: Tue, 6 Jun 2023 15:42:42 -0700 From: Nathan Chancellor To: Naresh Kamboju Cc: open list , clang-built-linux , lkft-triage@lists.linaro.org, Nick Desaulniers , Arnd Bergmann , Anders Roxell , Masahiro Yamada Subject: Re: powerpc: clang: arch/powerpc/kernel/exceptions-64s.S:2976: Error: junk at end of line: `0b01010' Message-ID: <20230606224242.GA3590526@dev-arch.thelio-3990X> References: <20230606153150.GA128872@dev-arch.thelio-3990X> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230606153150.GA128872@dev-arch.thelio-3990X> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 06, 2023 at 08:31:50AM -0700, Nathan Chancellor wrote: > Hi Naresh, > > On Tue, Jun 06, 2023 at 01:57:46PM +0530, Naresh Kamboju wrote: > > Linux next-20230606 powerpc build failed. > > > > Regressions found on powerpc: > > > > - build/clang-16-maple_defconfig > > - build/clang-nightly-maple_defconfig > > - build/clang-16-defconfig > > - build/clang-nightly-defconfig > > - build/clang-nightly-cell_defconfig > > - build/clang-16-cell_defconfig > > > > Boot: > > ===== > > make --silent --keep-going --jobs=8 > > O=/home/tuxbuild/.cache/tuxmake/builds/1/build ARCH=powerpc > > CROSS_COMPILE=powerpc64le-linux-gnu- > > HOSTCC=clang > > CC=clang > > LLVM=1 > > LLVM_IAS=0 > > LD=powerpc64le-linux-gnu-ld > > > > arch/powerpc/kernel/exceptions-64s.S: Assembler messages: > > arch/powerpc/kernel/exceptions-64s.S:2976: Error: junk at end of line: `0b01010' > > arch/powerpc/kernel/exceptions-64s.S:2996: Error: junk at end of line: `0b01010' > > arch/powerpc/kernel/exceptions-64s.S:3011: Error: junk at end of line: `0b01010' > > arch/powerpc/kernel/exceptions-64s.S:3029: Error: junk at end of line: `0b01010' > > arch/powerpc/kernel/exceptions-64s.S:3049: Error: junk at end of line: `0b01010' > > arch/powerpc/kernel/exceptions-64s.S:3096: Error: junk at end of line: `0b01010' > > clang: error: assembler command failed with exit code 1 (use -v to see > > invocation) > > make[4]: *** [scripts/Makefile.build:374: arch/powerpc/kernel/head_64.o] Error 1 > > arch/powerpc/kernel/entry_64.S: Assembler messages: > > arch/powerpc/kernel/entry_64.S:174: Error: junk at end of line: `0b01010' > > clang: error: assembler command failed with exit code 1 (use -v to see > > invocation) > > make[4]: *** [scripts/Makefile.build:374: > > arch/powerpc/kernel/entry_64.o] Error 1 > > make[4]: Target 'arch/powerpc/kernel/' not remade because of errors. > > make[3]: *** [scripts/Makefile.build:494: arch/powerpc/kernel] Error 2 > > arch/powerpc/lib/copyuser_power7.S: Assembler messages: > > arch/powerpc/lib/copyuser_power7.S:305: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/copyuser_power7.S:306: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/copyuser_power7.S:308: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/copyuser_power7.S:309: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/copyuser_power7.S:311: Error: junk at end of line: `0b01010' > > clang: error: assembler command failed with exit code 1 (use -v to see > > invocation) > > make[4]: *** [scripts/Makefile.build:374: > > arch/powerpc/lib/copyuser_power7.o] Error 1 > > arch/powerpc/lib/copypage_power7.S: Assembler messages: > > arch/powerpc/lib/copypage_power7.S:34: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/copypage_power7.S:35: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/copypage_power7.S:37: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/copypage_power7.S:38: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/copypage_power7.S:40: Error: junk at end of line: `0b01010' > > clang: error: assembler command failed with exit code 1 (use -v to see > > invocation) > > make[4]: *** [scripts/Makefile.build:374: > > arch/powerpc/lib/copypage_power7.o] Error 1 > > arch/powerpc/lib/memcpy_power7.S: Assembler messages: > > arch/powerpc/lib/memcpy_power7.S:250: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/memcpy_power7.S:251: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/memcpy_power7.S:252: Error: junk at end of line: `0b01000' > > arch/powerpc/lib/memcpy_power7.S:253: Error: junk at end of line: `0b01010' > > arch/powerpc/lib/memcpy_power7.S:255: Error: junk at end of line: `0b01010' > > clang: error: assembler command failed with exit code 1 (use -v to see > > invocation) > > make[4]: *** [scripts/Makefile.build:374: > > arch/powerpc/lib/memcpy_power7.o] Error 1 > > > > Reported-by: Linux Kernel Functional Testing > > Thank you for the report, this is caused by the move of CLANG_FLAGS from > KBUILD_{A,C}FLAGS to KBUILD_CPPFLAGS, as as-option does not contain > KBUILD_CPPFLAGS, so we fail to pass necessary flags to the assembler. > The following diff resolves this particular issue for me, can you test > it to make sure it works for you? I will write up a changelog and sent > along a formal patch later today. I have now sent [1] to address this, please consider providing a tag there assuming it passes all of your tests. [1]: https://lore.kernel.org/20230606-fix-as-option-after-clang_flags-move-v1-1-a7f7b23a35e3@kernel.org/ Cheers, Nathan > diff --git a/scripts/Makefile.compiler b/scripts/Makefile.compiler > index 437013f8def3..e31f18625fcf 100644 > --- a/scripts/Makefile.compiler > +++ b/scripts/Makefile.compiler > @@ -32,7 +32,7 @@ try-run = $(shell set -e; \ > # Usage: aflags-y += $(call as-option,-Wa$(comma)-isa=foo,) > > as-option = $(call try-run,\ > - $(CC) -Werror $(KBUILD_AFLAGS) $(1) -c -x assembler-with-cpp /dev/null -o "$$TMP",$(1),$(2)) > + $(CC) -Werror $(KBUILD_CPPFLAGS) $(KBUILD_AFLAGS) $(1) -c -x assembler-with-cpp /dev/null -o "$$TMP",$(1),$(2)) > > # as-instr > # Usage: aflags-y += $(call as-instr,instr,option1,option2) >