Skip to content

Commit a69b98b

Browse files
committed
llvm: add patch for f6fca6f
1 parent f6fca6f commit a69b98b

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
commit f6fca6f4d4241d2624759734c6b91e42e4f7bf22
2+
Author: Patrick Wildt <patrick@blueri.se>
3+
Date: Sat May 2 21:12:49 2015 +0200
4+
5+
llvm: disable NEON on ARM targets
6+
7+
The Marvell Armada XP does not have NEON/SIMD. Our default target
8+
defaults to using NEON, so we have to disable this.
9+
10+
It's more of a workaround, I'm not happy with it, but there's not
11+
really a better way.
12+
13+
diff --git a/contrib/llvm/tools/clang/lib/Driver/Tools.cpp b/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
14+
index a1c6bee..e69c8c2 100644
15+
--- a/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
16+
+++ b/contrib/llvm/tools/clang/lib/Driver/Tools.cpp
17+
@@ -730,6 +730,13 @@ static void getARMTargetFeatures(const Driver &D, const llvm::Triple &Triple,
18+
Features.push_back("+soft-float-abi");
19+
}
20+
21+
+ /* Disable NEON on Bitrig unless overridden. */
22+
+ if (Triple.getOS() == llvm::Triple::Bitrig &&
23+
+ !Args.getLastArg(options::OPT_mfpu_EQ)) {
24+
+ Features.push_back("+vfp3");
25+
+ Features.push_back("-neon");
26+
+ }
27+
+
28+
// Honor -mfpu=.
29+
if (const Arg *A = Args.getLastArg(options::OPT_mfpu_EQ))
30+
getARMFPUFeatures(D, A, Args, Features);

0 commit comments

Comments
 (0)