From: Russell King - ARM Linux admin <linux@armlinux.org.uk>
To: Stefan Agner <stefan@agner.ch>
Cc: arnd@arndb.de, ard.biesheuvel@linaro.org,
yamada.masahiro@socionext.com, ndesaulniers@google.com,
linux-kernel@vger.kernel.org, jiancai@google.com,
clang-built-linux@googlegroups.com, manojgupta@google.com,
robin.murphy@arm.com, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 0/3] ARM: make use of UAL VFP mnemonics when possible
Date: Sun, 19 Apr 2020 15:12:29 +0100 [thread overview]
Message-ID: <20200419141229.GX25745@shell.armlinux.org.uk> (raw)
In-Reply-To: <cover.1587299429.git.stefan@agner.ch>
On Sun, Apr 19, 2020 at 02:35:48PM +0200, Stefan Agner wrote:
> To build the kernel with Clang's integrated assembler the VFP code needs
> to make use of the unified assembler language (UAL) VFP mnemonics.
>
> At first I tried to get rid of the co-processor instructions to access
> the floating point unit along with the macros completely. However, due
> to missing FPINST/FPINST2 argument support in older binutils versions we
> have to keep them around. Once we drop support for binutils 2.24 and
> older, the move to UAL VFP mnemonics will be straight forward with this
> changes applied.
>
> Tested using Clang with integrated assembler as well as external
> (binutils assembler), various gcc/binutils version down to 4.7/2.23.
> Disassembled and compared the object files in arch/arm/vfp/ to make
> sure this changes leads to the same code. Besides different inlining
> behavior I was not able to spot a difference.
>
> In v2 the check for FPINST argument support is now made in Kconfig.
Given what I said in the other thread, Clang really _should_ allow
the MCR/MRC et.al. instructions to access the VFP registers. There
is no reason to specifically block them.
As we have seen with FPA, having that ability when iWMMXT comes along
is very useful. In any case:
1. The ARM ARM (DDI0406) states that "These instructions are MRC and MCR
instructions for coprocessors 10 and 11." in section A7.8.
2. The ARM ARM (DDI0406) describes the MRC and MCR instructions as
being able to access _any_ co-processor.
So, Clang deciding that it's going to block access to coprocessor 10
and 11 because some version of the architecture _also_ defines these
as VFP instructions is really not on, and Clang needs to be fixed
irrespective of these patches - and I want to know that *is* going to
get fixed before I take these patches into the kernel.
--
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line in suburbia: sync at 10.2Mbps down 587kbps up
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-04-19 14:13 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-19 12:35 [PATCH v2 0/3] ARM: make use of UAL VFP mnemonics when possible Stefan Agner
2020-04-19 12:35 ` [PATCH v2 1/3] ARM: use .fpu assembler directives instead of assembler arguments Stefan Agner
2020-04-19 14:04 ` Russell King - ARM Linux admin
2020-04-19 12:35 ` [PATCH v2 2/3] ARM: use VFP assembler mnemonics in register load/store macros Stefan Agner
2020-04-19 12:35 ` [PATCH v2 3/3] ARM: use VFP assembler mnemonics if available Stefan Agner
2020-04-19 14:12 ` Russell King - ARM Linux admin [this message]
2020-04-19 21:20 ` [PATCH v2 0/3] ARM: make use of UAL VFP mnemonics when possible Stefan Agner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200419141229.GX25745@shell.armlinux.org.uk \
--to=linux@armlinux.org.uk \
--cc=ard.biesheuvel@linaro.org \
--cc=arnd@arndb.de \
--cc=clang-built-linux@googlegroups.com \
--cc=jiancai@google.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=manojgupta@google.com \
--cc=ndesaulniers@google.com \
--cc=robin.murphy@arm.com \
--cc=stefan@agner.ch \
--cc=yamada.masahiro@socionext.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).