[Lldb-commits] [lldb] r250937 - Revert r250925 in source/Plugins/OperatingSystem/Go to fix MSVC builds failures.
Eugene Zelenko via lldb-commits
lldb-commits at lists.llvm.org
Wed Oct 21 13:03:58 PDT 2015
Author: eugenezelenko
Date: Wed Oct 21 15:03:58 2015
New Revision: 250937
URL: http://llvm.org/viewvc/llvm-project?rev=250937&view=rev
Log:
Revert r250925 in source/Plugins/OperatingSystem/Go to fix MSVC builds failures.
Modified:
lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.h
Modified: lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp?rev=250937&r1=250936&r2=250937&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp (original)
+++ lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.cpp Wed Oct 21 15:03:58 2015
@@ -1,4 +1,4 @@
-//===-- OperatingSystemGo.cpp -----------------------------------*- C++ -*-===//
+//===-- OperatingSystemGo.cpp --------------------------------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
@@ -6,15 +6,13 @@
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
+#include "OperatingSystemGo.h"
// C Includes
// C++ Includes
#include <unordered_map>
// Other libraries and framework includes
-// Project includes
-#include "OperatingSystemGo.h"
-
#include "lldb/Core/DataBufferHeap.h"
#include "lldb/Core/Debugger.h"
#include "lldb/Core/Module.h"
@@ -58,7 +56,13 @@ enum
class PluginProperties : public Properties
{
-public:
+ public:
+ static ConstString
+ GetSettingName()
+ {
+ return OperatingSystemGo::GetPluginNameStatic();
+ }
+
PluginProperties()
: Properties()
{
@@ -66,13 +70,7 @@ public:
m_collection_sp->Initialize(g_properties);
}
- ~PluginProperties() override = default;
-
- static ConstString
- GetSettingName()
- {
- return OperatingSystemGo::GetPluginNameStatic();
- }
+ virtual ~PluginProperties() {}
bool
GetEnableGoroutines()
@@ -102,7 +100,10 @@ GetGlobalPluginProperties()
class RegisterContextGo : public RegisterContextMemory
{
-public:
+ public:
+ //------------------------------------------------------------------
+ // Constructors and Destructors
+ //------------------------------------------------------------------
RegisterContextGo(lldb_private::Thread &thread, uint32_t concrete_frame_idx, DynamicRegisterInfo ®_info,
lldb::addr_t reg_data_addr)
: RegisterContextMemory(thread, concrete_frame_idx, reg_info, reg_data_addr)
@@ -117,11 +118,10 @@ public:
m_reg_data.SetData(reg_data_sp);
}
- ~RegisterContextGo() override = default;
+ virtual ~RegisterContextGo() {}
- bool
- ReadRegister(const lldb_private::RegisterInfo *reg_info,
- lldb_private::RegisterValue ®_value) override
+ virtual bool
+ ReadRegister(const lldb_private::RegisterInfo *reg_info, lldb_private::RegisterValue ®_value)
{
switch (reg_info->kinds[eRegisterKindGeneric])
{
@@ -134,9 +134,8 @@ public:
}
}
- bool
- WriteRegister(const lldb_private::RegisterInfo *reg_info,
- const lldb_private::RegisterValue ®_value) override
+ virtual bool
+ WriteRegister(const lldb_private::RegisterInfo *reg_info, const lldb_private::RegisterValue ®_value)
{
switch (reg_info->kinds[eRegisterKindGeneric])
{
@@ -148,11 +147,11 @@ public:
}
}
-private:
+ private:
DISALLOW_COPY_AND_ASSIGN(RegisterContextGo);
};
-} // anonymous namespace
+} // namespace
struct OperatingSystemGo::Goroutine
{
@@ -220,12 +219,6 @@ OperatingSystemGo::CreateInstance(Proces
return new OperatingSystemGo(process);
}
-OperatingSystemGo::OperatingSystemGo(lldb_private::Process *process)
- : OperatingSystem(process)
- , m_reginfo(new DynamicRegisterInfo)
-{
-}
-
ConstString
OperatingSystemGo::GetPluginNameStatic()
{
@@ -239,6 +232,16 @@ OperatingSystemGo::GetPluginDescriptionS
return "Operating system plug-in that reads runtime data-structures for goroutines.";
}
+OperatingSystemGo::OperatingSystemGo(lldb_private::Process *process)
+ : OperatingSystem(process)
+ , m_reginfo(new DynamicRegisterInfo)
+{
+}
+
+OperatingSystemGo::~OperatingSystemGo()
+{
+}
+
bool
OperatingSystemGo::Init(ThreadList &threads)
{
Modified: lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.h?rev=250937&r1=250936&r2=250937&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.h (original)
+++ lldb/trunk/source/Plugins/OperatingSystem/Go/OperatingSystemGo.h Wed Oct 21 15:03:58 2015
@@ -1,30 +1,24 @@
-//===-- OperatingSystemGo.h -------------------------------------*- C++ -*-===//
+//===-- OperatingSystemGo.h ----------------------------------*- C++ -*-===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
-//===----------------------------------------------------------------------===//
+//===-------------------------------------------------------------------===//
#ifndef _liblldb_OperatingSystemGo_h_
#define _liblldb_OperatingSystemGo_h_
-// C Includes
-// C++ Includes
-// Other libraries and framework includes
-// Project includes
+#include <iostream>
+
#include "lldb/Target/OperatingSystem.h"
class DynamicRegisterInfo;
class OperatingSystemGo : public lldb_private::OperatingSystem
{
-public:
- OperatingSystemGo(lldb_private::Process *process);
-
- ~OperatingSystemGo() override = default;
-
+ public:
//------------------------------------------------------------------
// Static Functions
//------------------------------------------------------------------
@@ -41,32 +35,38 @@ public:
static const char *GetPluginDescriptionStatic();
//------------------------------------------------------------------
+ // Class Methods
+ //------------------------------------------------------------------
+ OperatingSystemGo(lldb_private::Process *process);
+
+ virtual ~OperatingSystemGo();
+
+ //------------------------------------------------------------------
// lldb_private::PluginInterface Methods
//------------------------------------------------------------------
- lldb_private::ConstString GetPluginName() override;
+ virtual lldb_private::ConstString GetPluginName();
- uint32_t GetPluginVersion() override;
+ virtual uint32_t GetPluginVersion();
//------------------------------------------------------------------
// lldb_private::OperatingSystem Methods
//------------------------------------------------------------------
- bool UpdateThreadList(lldb_private::ThreadList &old_thread_list,
- lldb_private::ThreadList &real_thread_list,
- lldb_private::ThreadList &new_thread_list) override;
+ virtual bool UpdateThreadList(lldb_private::ThreadList &old_thread_list, lldb_private::ThreadList &real_thread_list,
+ lldb_private::ThreadList &new_thread_list);
- void ThreadWasSelected(lldb_private::Thread *thread) override;
+ virtual void ThreadWasSelected(lldb_private::Thread *thread);
- lldb::RegisterContextSP CreateRegisterContextForThread(lldb_private::Thread *thread,
- lldb::addr_t reg_data_addr) override;
+ virtual lldb::RegisterContextSP CreateRegisterContextForThread(lldb_private::Thread *thread,
+ lldb::addr_t reg_data_addr);
- lldb::StopInfoSP CreateThreadStopReason(lldb_private::Thread *thread) override;
+ virtual lldb::StopInfoSP CreateThreadStopReason(lldb_private::Thread *thread);
//------------------------------------------------------------------
// Method for lazy creation of threads on demand
//------------------------------------------------------------------
- lldb::ThreadSP CreateThread(lldb::tid_t tid, lldb::addr_t context) override;
+ virtual lldb::ThreadSP CreateThread(lldb::tid_t tid, lldb::addr_t context);
-private:
+ private:
struct Goroutine;
static lldb::ValueObjectSP FindGlobal(lldb::TargetSP target, const char *name);
@@ -82,4 +82,4 @@ private:
lldb::ValueObjectSP m_allglen_sp;
};
-#endif // liblldb_OperatingSystemGo_h_
+#endif // #ifndef liblldb_OperatingSystemGo_h_
More information about the lldb-commits
mailing list