Commit Graph

27 Commits

Author SHA1 Message Date
Rafael Espindola 0fa668072f Add support for musl-libc on ARM Linux.
Patch by Lei Zhang!

llvm-svn: 273735
2016-06-24 21:35:06 +00:00
Javed Absar 8f16175b60 [ARM]: Extend -mfpu options for half-precision and vfpv3xd
Some of the the permissible ARM -mfpu options, which are supported in GCC,
are currently not present in llvm/clang.This patch adds the options:
'neon-fp16', 'vfpv3-fp16', 'vfpv3-d16-fp16', 'vfpv3xd' and 'vfpv3xd-fp16. 
These are related to half-precision floating-point and single precision.

Reviewers: rengolin, ranjeet.singh

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D10764

llvm-svn: 240929
2015-06-29 09:30:19 +00:00
John Brawn 5a589ad603 [ARM] Use TargetParser to determine FPU subtarget features
The main effect of this is to fix anomalies where certain -mfpu options didn't
disable everything that they should causing strange behaviour when combined
with -mcpu or -march values that themselves enabled fpu subtarget features,
e.g. -mfpu=fpv5-dp-d16 with -march=armv7em previously behaved the same as
-mfpu=fpv5-sp-d16 due to fp-only-sp not being disabled.

Invalid -mfpu options now also give an error, which is consistent with the
handling of the .fpu directive.

Differential Revision: http://reviews.llvm.org/D10239

llvm-svn: 239152
2015-06-05 13:34:11 +00:00
Renato Golin 0600e1ebe9 Using ARMTargetParser in Clang
This is a starting point for using the TargetParser in Clang, in a simple
enough part of the code that can be used without disrupting the crazy
platform support that we need to be compatible with other toolchains.

Also adding a few FIXME on obvious places that need replacing, but those
cases will indeed break a few of the platform assumptions, as arch/cpu names
change multiple times in the driver.

Finally, I'm changing the "neon-vfpv3" behaviour to match standard NEON, since
-mfpu=neon implies vfpv3 by default in both Clang and LLVM. That option
string is still supported as an alias to "neon".

llvm-svn: 236901
2015-05-08 21:04:50 +00:00
Renato Golin e11531f7ea [ARM] Add support for ARMV6K subtarget (Clang)
ARMv6K is another layer between ARMV6 and ARMV6T2. This is the Clang
side of the changes.

ARMV6 family LLVM implementation.

+-------------------------------------+
| ARMV6                               |
+----------------+--------------------+
| ARMV6M (thumb) | ARMV6K (arm,thumb) | <- From ARMV6K and ARMV6M processors
+----------------+--------------------+    have support for hint instructions
| ARMV6T2 (arm,thumb,thumb2)          |    (SEV/WFE/WFI/NOP/YIELD). They can
+-------------------------------------+    be either real or default to NOP.
| ARMV7 (arm,thumb,thumb2)            |    The two processors also use
+-------------------------------------+    different encoding for them.

Patch by Vinicius Tinti.

llvm-svn: 232469
2015-03-17 11:55:43 +00:00
Richard Barton 2c5a89728d Correction to -mfu=neon-vfpv4 to pass the correct backend feature name
Change-Id: I4dbfe1d97670fc4e626368ef1f91fc008778dfca
llvm-svn: 224523
2014-12-18 16:31:18 +00:00
Richard Barton 3b0dcc160a Add additional arguments for -mfpu options
Add neon-vfpv3 to allow specifying both at the same time. This is not an
option that GCC supports, but follows the same track and should be
non-controversial.

Change-Id: Id9ec157c835937d7d11ad0f49dbe5171fac17658
llvm-svn: 222933
2014-11-28 20:39:59 +00:00
Richard Barton 09b60b2a63 Add -mfpu=neon-vfpv4
This enables user to architecturally specify ARMv7A + VFPv4 + NEON.

Change-Id: I779b01fef5c47e5e4ac702ae24ed2f76a0e4c63f
llvm-svn: 222932
2014-11-28 20:39:54 +00:00
Asiri Rathnayake 9e3c7cbfa1 Revert changes in r218863, r218864
Summary: The changes introduced in the above two commits are giving
a rough time to one of the build bots. Reverting the changes for the
moment so that the bot can go green again.

Change-Id: Id19f6cb2a8bc292631fac2262268927563d820c2
llvm-svn: 218970
2014-10-03 09:11:41 +00:00
Asiri Rathnayake fcd41ce5ae [ARM] Handle conflicts between -mfpu and -mfloat-abi options.
Summary: This patch implements warnings/downgradable errors for
invalid -mfpu, -mfloat-abi option combinations (e.g. -mfpu=none
-mfloat-abi=hard).

Change-Id: I94fa664e1bc0b5855ad835abd7a50a3e0395632d
llvm-svn: 218863
2014-10-02 09:56:07 +00:00
Oliver Stannard bfd3ea32b7 [ARM] Add support for Cortex-M7, FPv5-SP and FPv5-DP
The Cortex-M7 has 3 options for its FPU: none, FPv5-SP-D16 and
FPv5-DP-D16. FPv5 has the same instructions as FP-ARMv8, so it can be
modeled using the same target feature, and all double-precision
operations are already disabled by the fp-only-sp target features.

llvm-svn: 218748
2014-10-01 09:03:02 +00:00
Oliver Stannard 96601cad2f Add support for FPv4-SP to the clang driver
Added two new options for -mfpu when targetting ARM:
* fpv4-sp-d16
* fp4-sp-d16

The first is the same spelling as gcc.

The lack of a leading `v' is correct, this is consistent with ARM's
documentation and gcc's spelling of the option.

llvm-svn: 201846
2014-02-21 10:39:15 +00:00
Amara Emerson ecbe18e01d [ARM] Fix NEON wrongly being enabled with soft-float when targeting armv8/Cortex-A53/A57.
This was caused by r200708 which enabled the crypto feature for these cores.

llvm-svn: 201223
2014-02-12 10:22:35 +00:00
Rafael Espindola 9c6fb0f784 Don't pass +soft-float, +soft-float-abi to the arm assembler.
llvm-svn: 195551
2013-11-23 14:36:40 +00:00
Artyom Skrobov 53b000a86c [ARM] add basic support for Cortex-A7 and VFPv4 to Clang
llvm-svn: 195359
2013-11-21 14:04:38 +00:00
Bernard Ogden 18b5701a68 ARM: Add -m[no-]crc to dis/enable CRC subtargetfeature from clang
Allow users to disable or enable CRC subtarget feature.

Differential Revision: http://llvm-reviews.chandlerc.com/D2037

llvm-svn: 193600
2013-10-29 09:47:51 +00:00
Bernard Ogden da13af380a Add driver support for FP, SIMD and crypto defaults.
Although we wire up a bit for v8fp for macro setting
purposes, we don't set a macro yet. Need to ask list
about that.

Change-Id: Ic9819593ce00882fbec72757ffccc6f0b18160a0
llvm-svn: 193367
2013-10-24 18:32:51 +00:00
Amara Emerson 4cdb87b2d5 [ARM] Add -mfpu=none option to the driver.
llvm-svn: 191736
2013-10-01 10:20:54 +00:00
Amara Emerson fc362c62bf [ARMv8] Add crypto-neon-fp-armv8 -mfpu option in driver.
llvm-svn: 191001
2013-09-19 13:54:03 +00:00
Joey Gouly be8c27372a [ARMv8] Change the naming of some options to be more consistent.
Clang side changes for LLVM r190692.

llvm-svn: 190693
2013-09-13 13:48:33 +00:00
Tim Northover 244950d641 ARM: add test for last commit
This time I managed to forget the test.

Patch still by Stephen Kelly.

llvm-svn: 188797
2013-08-20 13:19:43 +00:00
Joey Gouly 7db275b947 Add support for passing v8fp options via -mfpu.
llvm-svn: 185075
2013-06-27 13:19:54 +00:00
Sebastian Pop 422377cfd3 rename -ccc-host-triple into -target
llvm-svn: 148582
2012-01-20 22:01:23 +00:00
Eli Friedman d749c6bf2e Revert r148138; it's causing test failures.
llvm-svn: 148141
2012-01-13 21:33:06 +00:00
Sebastian Pop 9a8d528ddf rename -ccc-host-triple into -target
llvm-svn: 148138
2012-01-13 20:37:02 +00:00
Evgeniy Stepanov a745155d3d More tests for ARM FPU features.
Also remove the svn:eol-style property from the test file.

llvm-svn: 147947
2012-01-11 12:36:39 +00:00
Evgeniy Stepanov 48af2a9e66 Fix -mfpu parsing on ARM.
- Support gcc-compatible vfpv3 name in addition to vfp3.
- Support vfpv3-d16.
- Disable neon feature for -mfpu=vfp* (yes, we were emitting Neon instructions
  for those!).

llvm-svn: 147943
2012-01-11 11:21:31 +00:00