[LoopUtils] Rename {check->find}StringMetadata{Into->For}Loop. NFC

"Into" was misleading.  I am also planning to use this helper to look
for loop metadata and return the argument, so find seems like a better
name.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@267013 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Adam Nemet 2016-04-21 17:33:12 +00:00
parent 58cd23c522
commit 94253c1835
2 changed files with 7 additions and 7 deletions

View File

@ -385,9 +385,9 @@ void computeLICMSafetyInfo(LICMSafetyInfo *, Loop *);
/// \brief Returns the instructions that use values defined in the loop.
SmallVector<Instruction *, 8> findDefsUsedOutsideOfLoop(Loop *L);
/// \brief Check string metadata into loop, if it exist return true,
/// else return false.
bool checkStringMetadataIntoLoop(Loop *TheLoop, StringRef Name);
/// \brief Find string metadata for loop, if it exist return true, else return
/// false.
bool findStringMetadataForLoop(Loop *TheLoop, StringRef Name);
/// \brief Set input string into loop metadata by keeping other values intact.
void addStringMetadataToLoop(Loop *TheLoop, const char *MDString,

View File

@ -121,9 +121,9 @@ static MDNode *createStringMetadata(Loop *TheLoop, StringRef Name, unsigned V) {
return MDNode::get(Context, MDs);
}
/// \brief Check string metadata in loop, if it exist return true,
/// else return false.
bool llvm::checkStringMetadataIntoLoop(Loop *TheLoop, StringRef Name) {
/// \brief Find string metadata for loop, if it exist return true, else return
/// false.
bool llvm::findStringMetadataForLoop(Loop *TheLoop, StringRef Name) {
MDNode *LoopID = TheLoop->getLoopID();
// Return false if LoopID is false.
if (!LoopID)
@ -474,7 +474,7 @@ bool LoopVersioningLICM::legalLoopInstructions() {
/// else false.
bool LoopVersioningLICM::isLoopAlreadyVisited() {
// Check LoopVersioningLICM metadata into loop
if (checkStringMetadataIntoLoop(CurLoop, LICMVersioningMetaData)) {
if (findStringMetadataForLoop(CurLoop, LICMVersioningMetaData)) {
return true;
}
return false;