|
LLVM
4.0.0
|
#include "llvm/MC/SubtargetFeature.h"#include "llvm/ADT/ArrayRef.h"#include "llvm/ADT/StringExtras.h"#include "llvm/Support/Debug.h"#include "llvm/Support/Format.h"#include "llvm/Support/raw_ostream.h"#include <algorithm>#include <cassert>#include <cctype>#include <cstdlib>Go to the source code of this file.
Functions | |
| static bool | hasFlag (StringRef Feature) |
| hasFlag - Determine if a feature has a flag; '+' or '-' More... | |
| static std::string | StripFlag (StringRef Feature) |
| StripFlag - Return string stripped of flag. More... | |
| static bool | isEnabled (StringRef Feature) |
| isEnabled - Return true if enable flag; '+'. More... | |
| static void | Split (std::vector< std::string > &V, StringRef S) |
| Split - Splits a string of comma separated items in to a vector of strings. More... | |
| static const SubtargetFeatureKV * | Find (StringRef S, ArrayRef< SubtargetFeatureKV > A) |
| Find KV in array using binary search. More... | |
| static size_t | getLongestEntryLength (ArrayRef< SubtargetFeatureKV > Table) |
| getLongestEntryLength - Return the length of the longest entry in the table. More... | |
| static void | Help (ArrayRef< SubtargetFeatureKV > CPUTable, ArrayRef< SubtargetFeatureKV > FeatTable) |
| Display help for feature choices. More... | |
| static void | SetImpliedBits (FeatureBitset &Bits, const SubtargetFeatureKV *FeatureEntry, ArrayRef< SubtargetFeatureKV > FeatureTable) |
| SetImpliedBits - For each feature that is (transitively) implied by this feature, set it. More... | |
| static void | ClearImpliedBits (FeatureBitset &Bits, const SubtargetFeatureKV *FeatureEntry, ArrayRef< SubtargetFeatureKV > FeatureTable) |
| ClearImpliedBits - For each feature that (transitively) implies this feature, clear it. More... | |
|
static |
ClearImpliedBits - For each feature that (transitively) implies this feature, clear it.
Definition at line 151 of file SubtargetFeature.cpp.
References llvm::SubtargetFeatureKV::Value.
Referenced by llvm::SubtargetFeatures::ApplyFeatureFlag(), and llvm::SubtargetFeatures::ToggleFeature().
|
static |
Find KV in array using binary search.
Definition at line 74 of file SubtargetFeature.cpp.
References llvm::ArrayRef< T >::begin(), llvm::ArrayRef< T >::end(), and F.
Referenced by llvm::SubtargetFeatures::ApplyFeatureFlag(), llvm::SubtargetFeatures::getFeatureBits(), and llvm::SubtargetFeatures::ToggleFeature().
|
static |
getLongestEntryLength - Return the length of the longest entry in the table.
Definition at line 86 of file SubtargetFeature.cpp.
References I.
Referenced by Help().
hasFlag - Determine if a feature has a flag; '+' or '-'
Definition at line 32 of file SubtargetFeature.cpp.
References assert(), and llvm::StringRef::empty().
Referenced by llvm::SubtargetFeatures::AddFeature(), llvm::SubtargetFeatures::ApplyFeatureFlag(), and StripFlag().
|
static |
Display help for feature choices.
Definition at line 95 of file SubtargetFeature.cpp.
References llvm::errs(), llvm::format(), and getLongestEntryLength().
Referenced by llvm::SubtargetFeatures::getFeatureBits().
isEnabled - Return true if enable flag; '+'.
Definition at line 48 of file SubtargetFeature.cpp.
References assert(), and llvm::StringRef::empty().
Referenced by llvm::SubtargetFeatures::ApplyFeatureFlag().
|
static |
SetImpliedBits - For each feature that is (transitively) implied by this feature, set it.
Definition at line 135 of file SubtargetFeature.cpp.
References llvm::SubtargetFeatureKV::Implies, and llvm::SubtargetFeatureKV::Value.
Referenced by llvm::SubtargetFeatures::ApplyFeatureFlag(), llvm::SubtargetFeatures::getFeatureBits(), and llvm::SubtargetFeatures::ToggleFeature().
|
static |
Split - Splits a string of comma separated items in to a vector of strings.
Definition at line 58 of file SubtargetFeature.cpp.
References llvm::SmallVectorTemplateCommon< T >::begin(), llvm::SmallVectorTemplateCommon< T >::end(), and llvm::StringRef::split().
Referenced by llvm::changeToInvokeAndSplitBasicBlock(), getConstVector(), getTargetShuffleMaskIndices(), performSTORECombine(), printHelpStr(), split(), llvm::Regex::sub(), and llvm::SubtargetFeatures::SubtargetFeatures().
|
inlinestatic |
StripFlag - Return string stripped of flag.
Definition at line 42 of file SubtargetFeature.cpp.
References hasFlag(), and llvm::StringRef::substr().
Referenced by llvm::SubtargetFeatures::ApplyFeatureFlag(), and llvm::SubtargetFeatures::ToggleFeature().
1.8.6