/// \return False on error (invalid features).
virtual bool initFeatureMap(llvm::StringMap<bool> &Features,
DiagnosticsEngine &Diags, StringRef CPU,
- std::vector<std::string> &FeatureVec) const {
- for (const auto &F : FeatureVec) {
- const char *Name = F.c_str();
- // Apply the feature via the target.
- bool Enabled = Name[0] == '+';
- setFeatureEnabled(Features, Name + 1, Enabled);
- }
- return true;
- }
+ std::vector<std::string> &FeatureVec) const;
/// \brief Get the ABI currently in use.
virtual StringRef getABI() const { return StringRef(); }
}
}
+bool TargetInfo::initFeatureMap(llvm::StringMap<bool> &Features,
+ DiagnosticsEngine &Diags, StringRef CPU,
+ std::vector<std::string> &FeatureVec) const {
+ for (const auto &F : FeatureVec) {
+ const char *Name = F.c_str();
+ // Apply the feature via the target.
+ bool Enabled = Name[0] == '+';
+ setFeatureEnabled(Features, Name + 1, Enabled);
+ }
+ return true;
+}
+
//===----------------------------------------------------------------------===//