1 //===-- UnwindAssembly.h --------------------------------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef utility_UnwindAssembly_h_
11 #define utility_UnwindAssembly_h_
13 #include "lldb/Core/PluginInterface.h"
14 #include "lldb/Utility/ArchSpec.h"
15 #include "lldb/lldb-private.h"
17 namespace lldb_private {
19 class UnwindAssembly : public std::enable_shared_from_this<UnwindAssembly>,
20 public PluginInterface {
22 static lldb::UnwindAssemblySP FindPlugin(const ArchSpec &arch);
24 ~UnwindAssembly() override;
27 GetNonCallSiteUnwindPlanFromAssembly(AddressRange &func, Thread &thread,
28 UnwindPlan &unwind_plan) = 0;
30 virtual bool AugmentUnwindPlanFromCallSite(AddressRange &func, Thread &thread,
31 UnwindPlan &unwind_plan) = 0;
33 virtual bool GetFastUnwindPlan(AddressRange &func, Thread &thread,
34 UnwindPlan &unwind_plan) = 0;
36 // thread may be NULL in which case we only use the Target (e.g. if this is
37 // called pre-process-launch).
39 FirstNonPrologueInsn(AddressRange &func,
40 const lldb_private::ExecutionContext &exe_ctx,
41 Address &first_non_prologue_insn) = 0;
44 UnwindAssembly(const ArchSpec &arch);
48 UnwindAssembly(); // Outlaw default constructor
49 DISALLOW_COPY_AND_ASSIGN(UnwindAssembly);
52 } // namespace lldb_private
54 #endif // utility_UnwindAssembly_h_