blob: d1dbb7ad407bfa29ee5524d53225097a4f141707 [file] [log] [blame]
Jim Ingham22777012010-09-23 02:01:19 +00001//===-- ItaniumABILanguageRuntime.h ----------------------------------------*- C++ -*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef liblldb_ItaniumABILanguageRuntime_h_
11#define liblldb_ItaniumABILanguageRuntime_h_
12
13// C Includes
14// C++ Includes
15// Other libraries and framework includes
16// Project includes
17#include "lldb/lldb-private.h"
Jim Ingham133e0fb2012-03-03 02:05:11 +000018#include "lldb/Breakpoint/BreakpointResolver.h"
Jim Ingham22777012010-09-23 02:01:19 +000019#include "lldb/Target/LanguageRuntime.h"
20#include "lldb/Target/CPPLanguageRuntime.h"
21#include "lldb/Core/Value.h"
22
Siva Chandra0f404e02015-04-09 18:48:34 +000023#include <map>
24#include <vector>
25
Jim Ingham22777012010-09-23 02:01:19 +000026namespace lldb_private {
27
28 class ItaniumABILanguageRuntime :
29 public lldb_private::CPPLanguageRuntime
30 {
31 public:
32 ~ItaniumABILanguageRuntime() { }
33
34 virtual bool
35 IsVTableName (const char *name);
36
Jim Ingham78a685a2011-04-16 00:01:13 +000037 virtual bool
Jim Ingham2837b762011-05-04 03:43:18 +000038 GetDynamicTypeAndAddress (ValueObject &in_value,
39 lldb::DynamicValueType use_dynamic,
40 TypeAndOrName &class_type_or_name,
41 Address &address);
Jim Ingham78a685a2011-04-16 00:01:13 +000042
43 virtual bool
44 CouldHaveDynamicValue (ValueObject &in_value);
45
Jim Ingham22777012010-09-23 02:01:19 +000046 //------------------------------------------------------------------
47 // Static Functions
48 //------------------------------------------------------------------
49 static void
50 Initialize();
51
52 static void
53 Terminate();
54
55 static lldb_private::LanguageRuntime *
56 CreateInstance (Process *process, lldb::LanguageType language);
57
Greg Clayton57abc5d2013-05-10 21:47:16 +000058 static lldb_private::ConstString
59 GetPluginNameStatic();
60
Jim Ingham22777012010-09-23 02:01:19 +000061 //------------------------------------------------------------------
62 // PluginInterface protocol
63 //------------------------------------------------------------------
Greg Clayton57abc5d2013-05-10 21:47:16 +000064 virtual lldb_private::ConstString
Jim Ingham22777012010-09-23 02:01:19 +000065 GetPluginName();
66
Jim Ingham22777012010-09-23 02:01:19 +000067 virtual uint32_t
68 GetPluginVersion();
69
70 virtual void
Sean Callananf2115102010-11-03 22:19:38 +000071 SetExceptionBreakpoints ();
72
73 virtual void
74 ClearExceptionBreakpoints ();
75
76 virtual bool
Jim Ingham6fbc48b2013-11-07 00:11:47 +000077 ExceptionBreakpointsAreSet ();
78
79 virtual bool
Sean Callananf2115102010-11-03 22:19:38 +000080 ExceptionBreakpointsExplainStop (lldb::StopInfoSP stop_reason);
Greg Claytona4f42232013-03-11 20:02:03 +000081
Jim Ingham219ba192012-03-05 04:47:34 +000082 virtual lldb::BreakpointResolverSP
83 CreateExceptionResolver (Breakpoint *bkpt, bool catch_bp, bool throw_bp);
Greg Claytona4f42232013-03-11 20:02:03 +000084
Greg Claytonbff78252013-03-11 18:42:51 +000085 virtual lldb::SearchFilterSP
86 CreateExceptionSearchFilter ();
87
Siva Chandra0f404e02015-04-09 18:48:34 +000088 virtual size_t
89 GetAlternateManglings(const ConstString &mangled, std::vector<ConstString> &alternates);
90
Greg Claytona4f42232013-03-11 20:02:03 +000091 protected:
92
Greg Claytonbff78252013-03-11 18:42:51 +000093 lldb::BreakpointResolverSP
Jim Inghamf0fd55e2012-03-06 18:10:38 +000094 CreateExceptionResolver (Breakpoint *bkpt, bool catch_bp, bool throw_bp, bool for_expressions);
95
Greg Claytonbff78252013-03-11 18:42:51 +000096 lldb::BreakpointSP
97 CreateExceptionBreakpoint(bool catch_bp,
98 bool throw_bp,
99 bool for_expressions,
100 bool is_internal);
101
Jim Ingham22777012010-09-23 02:01:19 +0000102 private:
103 ItaniumABILanguageRuntime(Process *process) : lldb_private::CPPLanguageRuntime(process) { } // Call CreateInstance instead.
Sean Callananf2115102010-11-03 22:19:38 +0000104
105 lldb::BreakpointSP m_cxx_exception_bp_sp;
Siva Chandra0f404e02015-04-09 18:48:34 +0000106
107 static std::map<ConstString, std::vector<ConstString> > s_alternate_mangling_prefixes;
Jim Ingham22777012010-09-23 02:01:19 +0000108 };
109
110} // namespace lldb_private
111
112#endif // liblldb_ItaniumABILanguageRuntime_h_