diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2015-01-07 19:37:26 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2015-01-07 19:37:26 +0000 |
commit | 6849e1fd53da79e0b1dd6dadd75cd9e7ad8734be (patch) | |
tree | be85874b371f0d2f5d3cfa42258f7ae53f0e916b /contrib/llvm/lib/Target | |
parent | a737d64c08e5b1a3f707329862c99440afe4a8ce (diff) | |
download | src-6849e1fd53da79e0b1dd6dadd75cd9e7ad8734be.tar.gz src-6849e1fd53da79e0b1dd6dadd75cd9e7ad8734be.zip |
Pull in r222292 from upstream llvm trunk (by Weiming Zhao):
[Aarch64] Customer lowering of CTPOP to SIMD should check for NEON
availability
This ensures llvm's AArch64 backend does not emit floating point
instructions if they are disabled.
Notes
Notes:
svn path=/head/; revision=276786
Diffstat (limited to 'contrib/llvm/lib/Target')
-rw-r--r-- | contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp b/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp index f2004ea1899d..df5b3e042f38 100644 --- a/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp +++ b/contrib/llvm/lib/Target/AArch64/AArch64ISelLowering.cpp @@ -3062,6 +3062,9 @@ SDValue AArch64TargetLowering::LowerCTPOP(SDValue Op, SelectionDAG &DAG) const { AttributeSet::FunctionIndex, Attribute::NoImplicitFloat)) return SDValue(); + if (!Subtarget->hasNEON()) + return SDValue(); + // While there is no integer popcount instruction, it can // be more efficiently lowered to the following sequence that uses // AdvSIMD registers/instructions as long as the copies to/from |