Skip to content

Conversation

boomanaiden154
Copy link
Contributor

Finish the TODO that was here in line with several of the other functions in TargetRegistry now that we have access to a triple through llvm::Module.

Finish the TODO that was here in line with several of the other
functions in TargetRegistry now that we have access to a triple through
llvm::Module.
@boomanaiden154
Copy link
Contributor Author

@boomanaiden154 boomanaiden154 marked this pull request as ready for review October 6, 2025 23:58
@boomanaiden154 boomanaiden154 requested review from arsenm and nikic October 6, 2025 23:58
@llvmbot llvmbot added the llvm:mc Machine (object) code label Oct 6, 2025
@llvmbot
Copy link
Member

llvmbot commented Oct 6, 2025

@llvm/pr-subscribers-llvm-mc

Author: Aiden Grossman (boomanaiden154)

Changes

Finish the TODO that was here in line with several of the other functions in TargetRegistry now that we have access to a triple through llvm::Module.


Full diff: https://github.com/llvm/llvm-project/pull/162188.diff

1 Files Affected:

  • (modified) llvm/include/llvm/MC/TargetRegistry.h (+2-1)
diff --git a/llvm/include/llvm/MC/TargetRegistry.h b/llvm/include/llvm/MC/TargetRegistry.h
index 570d4c0e8d272..234c587c8e951 100644
--- a/llvm/include/llvm/MC/TargetRegistry.h
+++ b/llvm/include/llvm/MC/TargetRegistry.h
@@ -737,7 +737,8 @@ struct TargetRegistry {
   /// \param TripleStr - The triple to use for finding a target.
   /// \param Error - On failure, an error string describing why no target was
   /// found.
-  // TODO: Drop this in favor of the method accepting Triple.
+  // TODO(boomanaiden154): Remove this function after LLVM 22 branches.
+  [[deprecated("Use overload accepting Triple instead")]]
   static const Target *lookupTarget(StringRef TripleStr, std::string &Error) {
     return lookupTarget(Triple(TripleStr), Error);
   }

@boomanaiden154 boomanaiden154 enabled auto-merge (squash) October 7, 2025 00:03
@boomanaiden154 boomanaiden154 merged commit 009da92 into llvm:main Oct 7, 2025
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
llvm:mc Machine (object) code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants