//------------------------------------------------------------------ /// Get all types matching \a type_mask from debug info in this /// module. /// /// @param[in] type_mask /// A bitfield that consists of one or more bits logically OR'ed /// together from the lldb::TypeClass enumeration. This allows /// you to request only structure types, or only class, struct /// and union types. Passing in lldb::eTypeClassAny will return /// all types found in the debug information for this module. /// /// @return /// A list of types in this module that match \a type_mask //------------------------------------------------------------------ lldb::SBTypeList SBModule::GetTypes (uint32_t type_mask) //------------------------------------------------------------------ /// Get all types matching \a type_mask from debug info in this /// compile unit. /// /// @param[in] type_mask /// A bitfield that consists of one or more bits logically OR'ed /// together from the lldb::TypeClass enumeration. This allows /// you to request only structure types, or only class, struct /// and union types. Passing in lldb::eTypeClassAny will return /// all types found in the debug information for this compile /// unit. /// /// @return /// A list of types in this compile unit that match \a type_mask //------------------------------------------------------------------ lldb::SBTypeList SBCompileUnit::GetTypes (uint32_t type_mask = lldb::eTypeClassAny); This lets you request types by filling out a mask that contains one or more bits from the lldb::TypeClass enumerations, so you can only get the types you really want. llvm-svn: 184251
66 lines
1.4 KiB
C++
66 lines
1.4 KiB
C++
//===-- NameToDIE.h ---------------------------------------------*- C++ -*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef SymbolFileDWARF_NameToDIE_h_
|
|
#define SymbolFileDWARF_NameToDIE_h_
|
|
|
|
#include "lldb/Core/UniqueCStringMap.h"
|
|
|
|
#include <functional>
|
|
|
|
#include "lldb/lldb-defines.h"
|
|
|
|
class SymbolFileDWARF;
|
|
|
|
typedef std::vector<uint32_t> DIEArray;
|
|
|
|
class NameToDIE
|
|
{
|
|
public:
|
|
NameToDIE () :
|
|
m_map()
|
|
{
|
|
}
|
|
|
|
~NameToDIE ()
|
|
{
|
|
}
|
|
|
|
void
|
|
Dump (lldb_private::Stream *s);
|
|
|
|
void
|
|
Insert (const lldb_private::ConstString& name, uint32_t die_offset);
|
|
|
|
void
|
|
Finalize();
|
|
|
|
size_t
|
|
Find (const lldb_private::ConstString &name,
|
|
DIEArray &info_array) const;
|
|
|
|
size_t
|
|
Find (const lldb_private::RegularExpression& regex,
|
|
DIEArray &info_array) const;
|
|
|
|
size_t
|
|
FindAllEntriesForCompileUnit (uint32_t cu_offset,
|
|
uint32_t cu_end_offset,
|
|
DIEArray &info_array) const;
|
|
|
|
void
|
|
ForEach (std::function <bool(const char *name, uint32_t die_offset)> const &callback) const;
|
|
|
|
protected:
|
|
lldb_private::UniqueCStringMap<uint32_t> m_map;
|
|
|
|
};
|
|
|
|
#endif // SymbolFileDWARF_NameToDIE_h_
|