This is the mail archive of the
mailing list for the GCC project.
Re: libatomic Makefile unconditionally sets -march=armv7-a when configuring with ifunc support
- From: Richard Henderson <rth at redhat dot com>
- To: Kyrill Tkachov <kyrylo dot tkachov at arm dot com>
- Cc: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Thu, 16 Jan 2014 10:13:34 -0800
- Subject: Re: libatomic Makefile unconditionally sets -march=armv7-a when configuring with ifunc support
- Authentication-results: sourceware.org; auth=none
- References: <52D7E3DA dot 2010201 at arm dot com>
On 01/16/2014 05:51 AM, Kyrill Tkachov wrote:
> Hi Richard,
> I noticed that Makefile.in in libatomic sets -march=armv7-a when compiling for
> arm linux targets with ifunc support:
> @ARCH_ARM_LINUX_TRUE@@HAVE_IFUNC_TRUE@IFUNC_OPTIONS = -march=armv7-a
> Is there any particular reason why it must do that?
Because armv7-a is required to enable the strexb, strexh, and strexd insns.
Then the ifunc selects between the kernel, armv6 and armv7 versions.
> Would there be any fallout I'm not seeing from removing -march=armv7-a from there?
You'd break the build for any configuration where strex[bhd] aren't enabled.
There are extensions to libatomic that could be made for armv8 support,
what with the new load-acquire etc insns. But merely using -march=armv8
doesn't achieve that.
I.e. it doesn't do you any good to just remove the flag.