[llvm] [TableGen] Rework error reporting for duplicate Feature/Processor. (PR #102257)
    Rahul Joshi via llvm-commits 
    llvm-commits at lists.llvm.org
       
    Tue Aug  6 20:30:04 PDT 2024
    
    
  
================
@@ -250,34 +250,37 @@ void SubtargetEmitter::EmitSubtargetInfoMacroCalls(raw_ostream &OS) {
 //
 unsigned SubtargetEmitter::FeatureKeyValues(
     raw_ostream &OS, const DenseMap<Record *, unsigned> &FeatureMap) {
-  // Gather and sort all the features
+  // Gather and sort all the features.
   std::vector<Record *> FeatureList =
       Records.getAllDerivedDefinitions("SubtargetFeature");
 
-  if (FeatureList.empty())
+  // Remove features with empty name.
+  auto End = llvm::remove_if(FeatureList, [](const Record *Rec) {
----------------
jurahul wrote:
Done.
https://github.com/llvm/llvm-project/pull/102257
    
    
More information about the llvm-commits
mailing list