objects for the backlink to the lldb_private::Process. The issues we were running into before was someone was holding onto a shared pointer to a lldb_private::Thread for too long, and the lldb_private::Process parent object would get destroyed and the lldb_private::Thread had a "Process &m_process" member which would just treat whatever memory that used to be a Process as a valid Process. This was mostly happening for lldb_private::StackFrame objects that had a member like "Thread &m_thread". So this completes the internal strong/weak changes. Documented the ExecutionContext and ExecutionContextRef classes so that our LLDB developers can understand when and where to use ExecutionContext and ExecutionContextRef objects. llvm-svn: 151009
59 lines
1.6 KiB
C++
59 lines
1.6 KiB
C++
//===-- UnwindAssembly.h --------------------------------*- C++ -*-===//
|
|
//
|
|
// The LLVM Compiler Infrastructure
|
|
//
|
|
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
//
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
#ifndef utility_UnwindAssembly_h_
|
|
#define utility_UnwindAssembly_h_
|
|
|
|
#include "lldb/lldb-private.h"
|
|
#include "lldb/Core/ArchSpec.h"
|
|
#include "lldb/Core/PluginInterface.h"
|
|
|
|
namespace lldb_private {
|
|
|
|
class UnwindAssembly :
|
|
public PluginInterface
|
|
{
|
|
public:
|
|
static UnwindAssembly*
|
|
FindPlugin (const ArchSpec &arch);
|
|
|
|
virtual
|
|
~UnwindAssembly();
|
|
|
|
virtual bool
|
|
GetNonCallSiteUnwindPlanFromAssembly (AddressRange& func,
|
|
Thread& thread,
|
|
UnwindPlan& unwind_plan) = 0;
|
|
|
|
virtual bool
|
|
GetFastUnwindPlan (AddressRange& func,
|
|
Thread& thread,
|
|
UnwindPlan &unwind_plan) = 0;
|
|
|
|
// thread may be NULL in which case we only use the Target (e.g. if this is called pre-process-launch).
|
|
virtual bool
|
|
FirstNonPrologueInsn (AddressRange& func,
|
|
const lldb_private::ExecutionContext &exe_ctx,
|
|
Address& first_non_prologue_insn) = 0;
|
|
|
|
protected:
|
|
UnwindAssembly (const ArchSpec &arch);
|
|
ArchSpec m_arch;
|
|
|
|
private:
|
|
UnwindAssembly(); // Outlaw default constructor
|
|
DISALLOW_COPY_AND_ASSIGN (UnwindAssembly);
|
|
};
|
|
|
|
} // namespace lldb_private
|
|
|
|
#endif //utility_UnwindAssembly_h_
|
|
|
|
|