diff options
author | dim <dim@FreeBSD.org> | 2015-01-07 19:37:26 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2015-01-07 19:37:26 +0000 |
commit | 6e0b7ffb0b48e5c5db771c8ac0a04a701aa69e0a (patch) | |
tree | be85874b371f0d2f5d3cfa42258f7ae53f0e916b /contrib/llvm/lib | |
parent | 3c03afd8958951ee2445ecf2b924c38f7454a751 (diff) | |
download | FreeBSD-src-6e0b7ffb0b48e5c5db771c8ac0a04a701aa69e0a.zip FreeBSD-src-6e0b7ffb0b48e5c5db771c8ac0a04a701aa69e0a.tar.gz |
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.
Diffstat (limited to 'contrib/llvm/lib')
-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 f2004ea..df5b3e0 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 |