summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAbdoulaye Walsimou Gaye <awg@embtoolkit.org>2013-05-05 17:14:02 +0200
committerAbdoulaye Walsimou Gaye <awg@embtoolkit.org>2013-05-10 16:12:52 +0200
commit0bac2ab46d722dd6a6354194903e9b213c80806d (patch)
tree6fef2169b96ac2f8c58d85be70e9934c4a7a85c6 /include
parent189c63f34b16c293f2282669392024711a97f078 (diff)
downloadllvm-0bac2ab46d722dd6a6354194903e9b213c80806d.tar.gz
llvm-0bac2ab46d722dd6a6354194903e9b213c80806d.tar.bz2
llvm-0bac2ab46d722dd6a6354194903e9b213c80806d.tar.xz
[Embtk] give ability to specify default FPU to use at configure time
Signed-off-by: Abdoulaye Walsimou Gaye <awg@embtoolkit.org> (cherry picked from commit 32e1613ce8f734d858831c228c36da70d783c0cd)
Diffstat (limited to 'include')
-rw-r--r--include/llvm/Config/config.h.cmake3
-rw-r--r--include/llvm/Config/config.h.in3
-rw-r--r--include/llvm/Config/llvm-config.h.cmake3
-rw-r--r--include/llvm/Config/llvm-config.h.in3
-rw-r--r--include/llvm/Support/Host.h8
5 files changed, 20 insertions, 0 deletions
diff --git a/include/llvm/Config/config.h.cmake b/include/llvm/Config/config.h.cmake
index 69876d3686..9c7f362493 100644
--- a/include/llvm/Config/config.h.cmake
+++ b/include/llvm/Config/config.h.cmake
@@ -573,6 +573,9 @@
/* Default float abi to use to all compiler invocations. */
#cmakedefine LLVM_DEFAULT_TARGET_FLOAT "${LLVM_DEFAULT_TARGET_FLOAT}"
+/* Default FPU to use to all compiler invocations, in case of hard float. */
+#cmakedefine LLVM_DEFAULT_TARGET_FPU "${LLVM_DEFAULT_TARGET_FPU}"
+
/* Default cpu (-mcpu=cpu) to use to all compiler invocations. */
#cmakedefine LLVM_DEFAULT_TARGET_MCPU "${LLVM_DEFAULT_TARGET_MCPU}"
diff --git a/include/llvm/Config/config.h.in b/include/llvm/Config/config.h.in
index e595aca501..86ed49dea3 100644
--- a/include/llvm/Config/config.h.in
+++ b/include/llvm/Config/config.h.in
@@ -578,6 +578,9 @@
/* Default float abi to use to all compiler invocations. */
#undef LLVM_DEFAULT_TARGET_FLOAT
+/* Default FPU to use to all compiler invocations, in case of hard float. */
+#undef LLVM_DEFAULT_TARGET_FPU
+
/* Default cpu (-mcpu=cpu) to use to all compiler invocations. */
#undef LLVM_DEFAULT_TARGET_MCPU
diff --git a/include/llvm/Config/llvm-config.h.cmake b/include/llvm/Config/llvm-config.h.cmake
index 993a9df69d..a8fcf91560 100644
--- a/include/llvm/Config/llvm-config.h.cmake
+++ b/include/llvm/Config/llvm-config.h.cmake
@@ -28,6 +28,9 @@
/* Default float abi to use to all compiler invocations. */
#cmakedefine LLVM_DEFAULT_TARGET_FLOAT "${LLVM_DEFAULT_TARGET_FLOAT}"
+/* Default FPU to use to all compiler invocations, in case of hard float. */
+#cmakedefine LLVM_DEFAULT_TARGET_FPU "${LLVM_DEFAULT_TARGET_FPU}"
+
/* Default cpu (-mcpu=cpu) to use to all compiler invocations. */
#cmakedefine LLVM_DEFAULT_TARGET_MCPU "${LLVM_DEFAULT_TARGET_MCPU}"
diff --git a/include/llvm/Config/llvm-config.h.in b/include/llvm/Config/llvm-config.h.in
index f25af09391..270628d00b 100644
--- a/include/llvm/Config/llvm-config.h.in
+++ b/include/llvm/Config/llvm-config.h.in
@@ -28,6 +28,9 @@
/* Default float abi to use to all compiler invocations. */
#undef LLVM_DEFAULT_TARGET_FLOAT
+/* Default FPU to use to all compiler invocations, in case of hard float. */
+#undef LLVM_DEFAULT_TARGET_FPU
+
/* Default cpu (-mcpu=cpu) to use to all compiler invocations. */
#undef LLVM_DEFAULT_TARGET_MCPU
diff --git a/include/llvm/Support/Host.h b/include/llvm/Support/Host.h
index 6cca3b2acd..45566302d1 100644
--- a/include/llvm/Support/Host.h
+++ b/include/llvm/Support/Host.h
@@ -63,6 +63,14 @@ namespace sys {
/// otherwise.
bool hasDefaultTargetFloat();
+ /// getDefaultTargetFpu() - Return the default target FPU for which the
+ /// compiler is configured to generate code for, or "" if empty.
+ std::string getDefaultTargetFpu();
+
+ /// hasDefaultTargetFpu() - Return true if the compiler was configured to
+ /// generate by default code for a given FPU and false otherwise.
+ bool hasDefaultTargetFpu();
+
/// getProcessTriple() - Return an appropriate target triple for generating
/// code to be loaded into the current process, e.g. when using the JIT.
std::string getProcessTriple();