1 //===-- MICmdCmdStack.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 //===----------------------------------------------------------------------===//
11 // File: MICmdCmdStack.h
13 // Overview: CMICmdCmdStackInfoDepth interface.
14 // CMICmdCmdStackListFrames interface.
15 // CMICmdCmdStackListArguments interface.
16 // CMICmdCmdStackListLocals interface.
18 // To implement new MI commands derive a new command class from the command base
19 // class. To enable the new command for interpretation add the new command class
20 // to the command factory. The files of relevance are:
24 // For an introduction to adding a new command see CMICmdCmdSupportInfoMiCmdQuery
25 // command class as an example.
27 // Environment: Compilers: Visual C++ 12.
28 // gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1
29 // Libraries: See MIReadmetxt.
37 #include "MICmdBase.h"
38 #include "MICmnMIValueList.h"
40 //++ ============================================================================
41 // Details: MI command class. MI commands derived from the command base class.
42 // *this class implements MI command "stack-info-depth".
44 // Authors: Illya Rudkin 21/03/2014.
47 class CMICmdCmdStackInfoDepth : public CMICmdBase
51 // Required by the CMICmdFactory when registering *this command
52 static CMICmdBase *CreateSelf(void);
56 /* ctor */ CMICmdCmdStackInfoDepth(void);
60 // From CMICmdInvoker::ICmd
61 virtual bool Execute(void);
62 virtual bool Acknowledge(void);
63 virtual bool ParseArgs(void);
65 /* dtor */ virtual ~CMICmdCmdStackInfoDepth(void);
69 MIuint m_nThreadFrames;
70 const CMIUtilString m_constStrArgThread; // Not specified in MI spec but Eclipse gives this option
71 const CMIUtilString m_constStrArgMaxDepth; // Not handled by *this command
74 //++ ============================================================================
75 // Details: MI command class. MI commands derived from the command base class.
76 // *this class implements MI command "stack-list-frames".
78 // Authors: Illya Rudkin 21/03/2014.
81 class CMICmdCmdStackListFrames : public CMICmdBase
85 // Required by the CMICmdFactory when registering *this command
86 static CMICmdBase *CreateSelf(void);
90 /* ctor */ CMICmdCmdStackListFrames(void);
94 // From CMICmdInvoker::ICmd
95 virtual bool Execute(void);
96 virtual bool Acknowledge(void);
97 virtual bool ParseArgs(void);
99 /* dtor */ virtual ~CMICmdCmdStackListFrames(void);
103 typedef std::vector<CMICmnMIValueResult> VecMIValueResult_t;
107 MIuint m_nThreadFrames;
108 VecMIValueResult_t m_vecMIValueResult;
109 const CMIUtilString m_constStrArgThread; // Not specified in MI spec but Eclipse gives this option
110 const CMIUtilString m_constStrArgFrameLow;
111 const CMIUtilString m_constStrArgFrameHigh;
114 //++ ============================================================================
115 // Details: MI command class. MI commands derived from the command base class.
116 // *this class implements MI command "stack-list-arguments".
118 // Authors: Illya Rudkin 24/03/2014.
121 class CMICmdCmdStackListArguments : public CMICmdBase
125 // Required by the CMICmdFactory when registering *this command
126 static CMICmdBase *CreateSelf(void);
130 /* ctor */ CMICmdCmdStackListArguments(void);
134 // From CMICmdInvoker::ICmd
135 virtual bool Execute(void);
136 virtual bool Acknowledge(void);
137 virtual bool ParseArgs(void);
139 /* dtor */ virtual ~CMICmdCmdStackListArguments(void);
143 bool m_bThreadInvalid; // True = yes invalid thread, false = thread object valid
144 CMICmnMIValueList m_miValueList;
145 const CMIUtilString m_constStrArgThread; // Not specified in MI spec but Eclipse gives this option
146 const CMIUtilString m_constStrArgPrintValues; // Not handled by *this command
149 //++ ============================================================================
150 // Details: MI command class. MI commands derived from the command base class.
151 // *this class implements MI command "stack-list-locals".
153 // Authors: Illya Rudkin 24/03/2014.
156 class CMICmdCmdStackListLocals : public CMICmdBase
160 // Required by the CMICmdFactory when registering *this command
161 static CMICmdBase *CreateSelf(void);
165 /* ctor */ CMICmdCmdStackListLocals(void);
169 // From CMICmdInvoker::ICmd
170 virtual bool Execute(void);
171 virtual bool Acknowledge(void);
172 virtual bool ParseArgs(void);
174 /* dtor */ virtual ~CMICmdCmdStackListLocals(void);
178 bool m_bThreadInvalid; // True = yes invalid thread, false = thread object valid
179 CMICmnMIValueList m_miValueList;
180 const CMIUtilString m_constStrArgThread; // Not specified in MI spec but Eclipse gives this option
181 const CMIUtilString m_constStrArgFrame; // Not specified in MI spec but Eclipse gives this option
182 const CMIUtilString m_constStrArgPrintValues; // Not handled by *this command