diff options
author | dim <dim@FreeBSD.org> | 2012-08-15 19:34:23 +0000 |
---|---|---|
committer | dim <dim@FreeBSD.org> | 2012-08-15 19:34:23 +0000 |
commit | 721c201bd55ffb73cb2ba8d39e0570fa38c44e15 (patch) | |
tree | eacfc83d988e4b9d11114387ae7dc41243f2a363 /lib/MC/SubtargetFeature.cpp | |
parent | 2b2816e083a455f7a656ae88b0fd059d1688bb36 (diff) | |
download | FreeBSD-src-721c201bd55ffb73cb2ba8d39e0570fa38c44e15.zip FreeBSD-src-721c201bd55ffb73cb2ba8d39e0570fa38c44e15.tar.gz |
Vendor import of llvm trunk r161861:
http://llvm.org/svn/llvm-project/llvm/trunk@161861
Diffstat (limited to 'lib/MC/SubtargetFeature.cpp')
-rw-r--r-- | lib/MC/SubtargetFeature.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/MC/SubtargetFeature.cpp b/lib/MC/SubtargetFeature.cpp index be41579..0a44e77 100644 --- a/lib/MC/SubtargetFeature.cpp +++ b/lib/MC/SubtargetFeature.cpp @@ -92,7 +92,7 @@ static void Split(std::vector<std::string> &V, const StringRef S) { static std::string Join(const std::vector<std::string> &V) { // Start with empty string. std::string Result; - // If the vector is not empty + // If the vector is not empty if (!V.empty()) { // Start with the first feature Result = V[0]; @@ -104,7 +104,7 @@ static std::string Join(const std::vector<std::string> &V) { Result += V[i]; } } - // Return the features string + // Return the features string return Result; } @@ -205,7 +205,7 @@ void SetImpliedBits(uint64_t &Bits, const SubtargetFeatureKV *FeatureEntry, /// ClearImpliedBits - For each feature that (transitively) implies this /// feature, clear it. -/// +/// static void ClearImpliedBits(uint64_t &Bits, const SubtargetFeatureKV *FeatureEntry, const SubtargetFeatureKV *FeatureTable, @@ -252,7 +252,7 @@ SubtargetFeatures::ToggleFeature(uint64_t Bits, const StringRef Feature, return Bits; } - + /// getFeatureBits - Get feature bits a CPU. /// @@ -279,7 +279,7 @@ uint64_t SubtargetFeatures::getFeatureBits(const StringRef CPU, // Check if help is needed if (CPU == "help") Help(CPUTable, CPUTableSize, FeatureTable, FeatureTableSize); - + // Find CPU entry if CPU name is specified. if (!CPU.empty()) { const SubtargetFeatureKV *CPUEntry = Find(CPU, CPUTable, CPUTableSize); @@ -304,11 +304,11 @@ uint64_t SubtargetFeatures::getFeatureBits(const StringRef CPU, // Iterate through each feature for (size_t i = 0, E = Features.size(); i < E; i++) { const StringRef Feature = Features[i]; - + // Check for help if (Feature == "+help") Help(CPUTable, CPUTableSize, FeatureTable, FeatureTableSize); - + // Find feature in table. const SubtargetFeatureKV *FeatureEntry = Find(StripFlag(Feature), FeatureTable, FeatureTableSize); @@ -349,7 +349,7 @@ void *SubtargetFeatures::getItinerary(const StringRef CPU, // Find entry const SubtargetInfoKV *Entry = Find(CPU, Table, TableSize); - + if (Entry) { return Entry->Value; } else { |