This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC][ARM] TARGET_ATOMIC_ASSIGN_EXPAND_FENV hook
- From: Ramana Radhakrishnan <ramana dot gcc at googlemail dot com>
- To: Kugan <kugan dot vivekanandarajah at linaro dot org>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, Richard Earnshaw <Richard dot Earnshaw at arm dot com>
- Date: Tue, 10 Jun 2014 15:32:42 +0100
- Subject: Re: [RFC][ARM] TARGET_ATOMIC_ASSIGN_EXPAND_FENV hook
- Authentication-results: sourceware.org; auth=none
- References: <535B89D6 dot 2070309 at linaro dot org> <Pine dot LNX dot 4 dot 64 dot 1405020012530 dot 16441 at digraph dot polyomino dot org dot uk> <53635FBA dot 7060505 at linaro dot org> <53700C12 dot 4000102 at linaro dot org> <5382F4C4 dot 9000508 at linaro dot org> <CAJA7tRayghjpkdKDpzoz6doTQ162N9dwq8w6rkicoXNAHZQrTQ at mail dot gmail dot com> <53964262 dot 5070404 at linaro dot org>
- Reply-to: ramrad01 at arm dot com
On Tue, Jun 10, 2014 at 12:25 AM, Kugan
<kugan.vivekanandarajah@linaro.org> wrote:
> On 30/05/14 18:35, Ramana Radhakrishnan wrote:
>>> + if (!TARGET_VFP)
>>> + return;
>>> +
>>> + /* Generate the equivalence of :
>>
>> s/equivalence/equivalent.
>>
>> Ok with that change and if no regressions.
>
> Hi Ramana,
>
> Sorry, I missed the thumb1 part. There are no mrc/mcr versions of these
> instructions in thumb1. So these should be conditional on not being
> ARM_THUMB1.
>
No, this has nothing to do with TARGET_THUMB1 - the real condition
should be TARGET_VFP && TARGET_HARD_FLOAT. These instructions only
work if TARGET_HARD_FLOAT is true. Thumb1 + VFP instructions is not
possible, similarly if generating code for -mfloat-abi=soft you don't
want these instructions being generated.
Ok if that works.
Ramana
> Is this OK. Regression tested with no new refression on qemu for
> arm-none-linux-gnueabi -march=armv7-a and on arm-none-linux-gnueabi
> --with-mode=thumb and -march=armv5t.
>
> Is this OK?
>
> Thanks,
> Kugan
>
> gcc/
>
> 2014-06-10 Kugan Vivekanandarajah <kuganv@linaro.org>
>
> * config/arm/arm.c (arm_atomic_assign_expand_fenv): call
> default_atomic_assign_expand_fenv for TARGET_THUMB1.
> (arm_init_builtins) : Initialize builtins __builtins_arm_set_fpscr and
> __builtins_arm_get_fpscr only when !TARGET_THUMB1.
> * config/arm/vfp.md (set_fpscr): Make pattern conditional on
> !TARGERT_THUMB1.
> (get_fpscr) : Likewise.