Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-10 08:42:52

0001 //===-- SymbolVendor.h ------------------------------------------*- C++ -*-===//
0002 //
0003 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
0004 // See https://llvm.org/LICENSE.txt for license information.
0005 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
0006 //
0007 //===----------------------------------------------------------------------===//
0008 
0009 #ifndef LLDB_SYMBOL_SYMBOLVENDOR_H
0010 #define LLDB_SYMBOL_SYMBOLVENDOR_H
0011 
0012 #include <vector>
0013 
0014 #include "lldb/Core/ModuleChild.h"
0015 #include "lldb/Core/PluginInterface.h"
0016 #include "lldb/Symbol/SourceModule.h"
0017 #include "lldb/Symbol/SymbolFile.h"
0018 #include "lldb/Symbol/TypeMap.h"
0019 #include "lldb/lldb-private.h"
0020 #include "llvm/ADT/DenseSet.h"
0021 
0022 namespace lldb_private {
0023 
0024 // The symbol vendor class is designed to abstract the process of searching for
0025 // debug information for a given module. Platforms can subclass this class and
0026 // provide extra ways to find debug information. Examples would be a subclass
0027 // that would allow for locating a stand alone debug file, parsing debug maps,
0028 // or runtime data in the object files. A symbol vendor can use multiple
0029 // sources (SymbolFile objects) to provide the information and only parse as
0030 // deep as needed in order to provide the information that is requested.
0031 class SymbolVendor : public ModuleChild, public PluginInterface {
0032 public:
0033   static SymbolVendor *FindPlugin(const lldb::ModuleSP &module_sp,
0034                                   Stream *feedback_strm);
0035 
0036   // Constructors and Destructors
0037   SymbolVendor(const lldb::ModuleSP &module_sp);
0038 
0039   void AddSymbolFileRepresentation(const lldb::ObjectFileSP &objfile_sp);
0040 
0041   SymbolFile *GetSymbolFile() { return m_sym_file_up.get(); }
0042 
0043   // PluginInterface protocol
0044   llvm::StringRef GetPluginName() override { return "vendor-default"; }
0045 
0046 protected:
0047   std::unique_ptr<SymbolFile> m_sym_file_up; // A single symbol file. Subclasses
0048                                              // can add more of these if needed.
0049 };
0050 
0051 } // namespace lldb_private
0052 
0053 #endif // LLDB_SYMBOL_SYMBOLVENDOR_H