[Lldb-commits] [PATCH] D132187: [LLDB] Remove duplicate loop in FindMatchingModuleSpec.

Zequan Wu via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Aug 18 16:06:59 PDT 2022


zequanwu created this revision.
zequanwu added a reviewer: labath.
Herald added a project: All.
zequanwu requested review of this revision.
Herald added a project: LLDB.
Herald added a subscriber: lldb-commits.

The removed loop is the same as the one above it. If previous one success, it
returns. Otherwise, searching will fail again.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D132187

Files:
  lldb/include/lldb/Core/ModuleSpec.h


Index: lldb/include/lldb/Core/ModuleSpec.h
===================================================================
--- lldb/include/lldb/Core/ModuleSpec.h
+++ lldb/include/lldb/Core/ModuleSpec.h
@@ -341,16 +341,6 @@
       }
     }
 
-    // If there was an architecture, retry with a compatible arch
-    if (module_spec.GetArchitecturePtr()) {
-      exact_arch_match = false;
-      for (auto spec : m_specs) {
-        if (spec.Matches(module_spec, exact_arch_match)) {
-          match_module_spec = spec;
-          return true;
-        }
-      }
-    }
     match_module_spec.Clear();
     return false;
   }


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D132187.453826.patch
Type: text/x-patch
Size: 614 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20220818/dec5fe30/attachment-0001.bin>


More information about the lldb-commits mailing list