aboutsummaryrefslogtreecommitdiff
path: root/include/lldb/Core/Debugger.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/lldb/Core/Debugger.h')
-rw-r--r--include/lldb/Core/Debugger.h64
1 files changed, 48 insertions, 16 deletions
diff --git a/include/lldb/Core/Debugger.h b/include/lldb/Core/Debugger.h
index ccc07b30f0c6..56201273fdd2 100644
--- a/include/lldb/Core/Debugger.h
+++ b/include/lldb/Core/Debugger.h
@@ -14,9 +14,7 @@
#include <stdint.h>
// C++ Includes
-#include <map>
#include <memory>
-#include <mutex>
#include <vector>
// Other libraries and framework includes
@@ -24,21 +22,55 @@
#include "lldb/Core/Broadcaster.h"
#include "lldb/Core/FormatEntity.h"
#include "lldb/Core/IOHandler.h"
-#include "lldb/Core/Listener.h"
#include "lldb/Core/SourceManager.h"
-#include "lldb/Core/UserID.h"
#include "lldb/Core/UserSettingsController.h"
#include "lldb/Host/HostThread.h"
#include "lldb/Host/Terminal.h"
+#include "lldb/Target/ExecutionContext.h" // for ExecutionContext
#include "lldb/Target/Platform.h"
#include "lldb/Target/TargetList.h"
-#include "lldb/lldb-public.h"
+#include "lldb/Utility/ConstString.h" // for ConstString
+#include "lldb/Utility/Error.h" // for Error
+#include "lldb/Utility/FileSpec.h" // for FileSpec
+#include "lldb/Utility/UserID.h"
+#include "lldb/lldb-defines.h" // for DISALLOW_COPY_AND_ASSIGN
+#include "lldb/lldb-enumerations.h" // for ScriptLanguage, Langua...
+#include "lldb/lldb-forward.h" // for StreamFileSP, DebuggerSP
+#include "lldb/lldb-private-enumerations.h" // for VarSetOperationType
+#include "lldb/lldb-private-types.h" // for LoadPluginCallbackType
+#include "lldb/lldb-types.h" // for LogOutputCallback, thr...
+
+#include "llvm/ADT/ArrayRef.h" // for ArrayRef
+#include "llvm/ADT/StringMap.h" // for StringMap
+#include "llvm/ADT/StringRef.h" // for StringRef
+#include "llvm/Support/DynamicLibrary.h" // for DynamicLibrary
+#include "llvm/Support/Threading.h"
+
+#include <assert.h> // for assert
+#include <stddef.h> // for size_t
+#include <stdio.h>
+namespace lldb_private {
+class Address;
+}
+namespace lldb_private {
+class CommandInterpreter;
+}
+namespace lldb_private {
+class Process;
+}
+namespace lldb_private {
+class Stream;
+}
+namespace lldb_private {
+class SymbolContext;
+}
+namespace lldb_private {
+class Target;
+}
namespace llvm {
-namespace sys {
-class DynamicLibrary;
-} // namespace sys
-} // namespace llvm
+class raw_ostream;
+}
namespace lldb_private {
@@ -190,9 +222,10 @@ public:
void SetCloseInputOnEOF(bool b);
- bool EnableLog(const char *channel, const char **categories,
- const char *log_file, uint32_t log_options,
- Stream &error_stream);
+ bool EnableLog(llvm::StringRef channel,
+ llvm::ArrayRef<const char *> categories,
+ llvm::StringRef log_file, uint32_t log_options,
+ llvm::raw_ostream &error_stream);
void SetLoggingCallback(lldb::LogOutputCallback log_callback, void *baton);
@@ -363,9 +396,8 @@ protected:
std::unique_ptr<CommandInterpreter> m_command_interpreter_ap;
IOHandlerStack m_input_reader_stack;
- typedef std::map<std::string, lldb::StreamWP> LogStreamMap;
- LogStreamMap m_log_streams;
- lldb::StreamSP m_log_callback_stream_sp;
+ llvm::StringMap<std::weak_ptr<llvm::raw_ostream>> m_log_streams;
+ std::shared_ptr<llvm::raw_ostream> m_log_callback_stream_sp;
ConstString m_instance_name;
static LoadPluginCallbackType g_load_plugin_callback;
typedef std::vector<llvm::sys::DynamicLibrary> LoadedPluginsList;
@@ -374,7 +406,7 @@ protected:
HostThread m_io_handler_thread;
Broadcaster m_sync_broadcaster;
lldb::ListenerSP m_forward_listener_sp;
- std::once_flag m_clear_once;
+ llvm::once_flag m_clear_once;
//----------------------------------------------------------------------
// Events for m_sync_broadcaster