aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/ARM/ARMSubtarget.h
diff options
context:
space:
mode:
authorAnton Korobeynikov <asl@math.spbu.ru>2009-05-23 19:50:50 +0000
committerAnton Korobeynikov <asl@math.spbu.ru>2009-05-23 19:50:50 +0000
commit7357d8f48490c42cf6237c3a8f982a36258248db (patch)
tree84e4c7c067cf7671696a466e471ce202604ffb81 /lib/Target/ARM/ARMSubtarget.h
parentdc3e36dd1f8485f55a28fac99fa23a5bfb011e61 (diff)
downloadexternal_llvm-7357d8f48490c42cf6237c3a8f982a36258248db.zip
external_llvm-7357d8f48490c42cf6237c3a8f982a36258248db.tar.gz
external_llvm-7357d8f48490c42cf6237c3a8f982a36258248db.tar.bz2
Propagate CPU string out of SubtargetFeatures
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72335 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMSubtarget.h')
-rw-r--r--lib/Target/ARM/ARMSubtarget.h10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/Target/ARM/ARMSubtarget.h b/lib/Target/ARM/ARMSubtarget.h
index fbc9e57..870a8c7 100644
--- a/lib/Target/ARM/ARMSubtarget.h
+++ b/lib/Target/ARM/ARMSubtarget.h
@@ -47,6 +47,9 @@ protected:
/// entry to the function and which must be maintained by every function.
unsigned stackAlignment;
+ /// CPUString - String name of used CPU.
+ std::string CPUString;
+
public:
enum {
isELF, isDarwin
@@ -71,7 +74,8 @@ protected:
}
/// ParseSubtargetFeatures - Parses features string setting specified
/// subtarget options. Definition of function is auto generated by tblgen.
- void ParseSubtargetFeatures(const std::string &FS, const std::string &CPU);
+ std::string ParseSubtargetFeatures(const std::string &FS,
+ const std::string &CPU);
bool hasV4TOps() const { return ARMArchVersion >= V4T; }
bool hasV5TOps() const { return ARMArchVersion >= V5T; }
@@ -79,7 +83,7 @@ protected:
bool hasV6Ops() const { return ARMArchVersion >= V6; }
bool hasVFP2() const { return HasVFP2; }
-
+
bool isTargetDarwin() const { return TargetType == isDarwin; }
bool isTargetELF() const { return TargetType == isELF; }
@@ -91,6 +95,8 @@ protected:
bool useThumbBacktraces() const { return UseThumbBacktraces; }
bool isR9Reserved() const { return IsR9Reserved; }
+ const std::string & getCPUString() const { return CPUString; }
+
/// getStackAlignment - Returns the minimum alignment known to hold of the
/// stack frame on entry to the function and which must be maintained by every
/// function for this subtarget.