https://github.com/mchoo7 created https://github.com/llvm/llvm-project/pull/182878
There are two different ways to debug FreeBSD's kernel: core and remote debugging. Remote debugging is done through `gdb-remote` plugin while kernel dump and live core debugging is done through `FreeBSDKernel`. The name `FreeBSDKernel` is vague for this reason, and following `elf-core` and `mach-core`'s example, it would be clearer if this plugin is renamed to `FreeBSD-Kernel-Core`. On LLDB, this shows up as `freebsd-kernel-core`. >From 7553ed4476817b7307159316666ce6fefc251f7b Mon Sep 17 00:00:00 2001 From: Minsoo Choo <[email protected]> Date: Mon, 23 Feb 2026 10:19:54 -0500 Subject: [PATCH] [lldb][Process/FreeBSDKernelCore] Rename to FreeBSDKernelCore Signed-off-by: Minsoo Choo <[email protected]> --- lldb/source/Plugins/Process/CMakeLists.txt | 2 +- .../FreeBSD-Kernel-Core/CMakeLists.txt | 14 ++++ .../ProcessFreeBSDKernelCore.cpp} | 65 +++++++++--------- .../ProcessFreeBSDKernelCore.h} | 20 +++--- ...egisterContextFreeBSDKernelCore_arm64.cpp} | 20 +++--- .../RegisterContextFreeBSDKernelCore_arm64.h} | 13 ++-- ...RegisterContextFreeBSDKernelCore_i386.cpp} | 18 ++--- .../RegisterContextFreeBSDKernelCore_i386.h} | 12 ++-- ...gisterContextFreeBSDKernelCore_x86_64.cpp} | 23 ++++--- ...RegisterContextFreeBSDKernelCore_x86_64.h} | 13 ++-- .../ThreadFreeBSDKernelCore.cpp} | 45 ++++++------ .../ThreadFreeBSDKernelCore.h} | 16 ++--- .../Process/FreeBSDKernel/CMakeLists.txt | 14 ---- .../TestFreeBSDKernelLiveCore.py} | 2 +- .../TestFreeBSDKernelVMCore.py | 0 .../kernel-amd64.yaml | 0 .../kernel-arm64.yaml | 0 .../kernel-i386.yaml | 0 .../tools/README.rst | 0 .../tools/copy-sparse.py | 0 .../tools/libfbsdvmcore-hacks.patch | 0 .../tools/lldb-minimize-processes.patch | 0 .../tools/test.script | 0 .../vmcore-amd64-full.bz2 | Bin .../vmcore-amd64-minidump.bz2 | Bin .../vmcore-arm64-minidump.bz2 | Bin .../vmcore-i386-minidump.bz2 | Bin llvm/docs/ReleaseNotes.md | 2 + 28 files changed, 145 insertions(+), 134 deletions(-) create mode 100644 lldb/source/Plugins/Process/FreeBSD-Kernel-Core/CMakeLists.txt rename lldb/source/Plugins/Process/{FreeBSDKernel/ProcessFreeBSDKernel.cpp => FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.cpp} (86%) rename lldb/source/Plugins/Process/{FreeBSDKernel/ProcessFreeBSDKernel.h => FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.h} (80%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.cpp => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.cpp} (88%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.h => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.h} (81%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_i386.cpp => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.cpp} (76%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.h => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.h} (81%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.cpp => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.cpp} (72%) rename lldb/source/Plugins/Process/{FreeBSDKernel/RegisterContextFreeBSDKernel_i386.h => FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.h} (80%) rename lldb/source/Plugins/Process/{FreeBSDKernel/ThreadFreeBSDKernel.cpp => FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.cpp} (58%) rename lldb/source/Plugins/Process/{FreeBSDKernel/ThreadFreeBSDKernel.h => FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.h} (78%) delete mode 100644 lldb/source/Plugins/Process/FreeBSDKernel/CMakeLists.txt rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel/TestFreeBSDKernelLive.py => FreeBSD-Kernel-Core/TestFreeBSDKernelLiveCore.py} (96%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/TestFreeBSDKernelVMCore.py (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/kernel-amd64.yaml (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/kernel-arm64.yaml (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/kernel-i386.yaml (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/tools/README.rst (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/tools/copy-sparse.py (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/tools/libfbsdvmcore-hacks.patch (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/tools/lldb-minimize-processes.patch (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/tools/test.script (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/vmcore-amd64-full.bz2 (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/vmcore-amd64-minidump.bz2 (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/vmcore-arm64-minidump.bz2 (100%) rename lldb/test/API/functionalities/postmortem/{FreeBSDKernel => FreeBSD-Kernel-Core}/vmcore-i386-minidump.bz2 (100%) diff --git a/lldb/source/Plugins/Process/CMakeLists.txt b/lldb/source/Plugins/Process/CMakeLists.txt index 9a5f1cd433717..8f4f11fd440c7 100644 --- a/lldb/source/Plugins/Process/CMakeLists.txt +++ b/lldb/source/Plugins/Process/CMakeLists.txt @@ -8,7 +8,7 @@ if (CMAKE_SYSTEM_NAME MATCHES "Linux|Android") add_subdirectory(POSIX) elseif (CMAKE_SYSTEM_NAME MATCHES "FreeBSD") add_subdirectory(FreeBSD) - add_subdirectory(FreeBSDKernel) + add_subdirectory(FreeBSD-Kernel-Core) add_subdirectory(POSIX) elseif (CMAKE_SYSTEM_NAME MATCHES "NetBSD") add_subdirectory(NetBSD) diff --git a/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/CMakeLists.txt b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/CMakeLists.txt new file mode 100644 index 0000000000000..8aafee3e43314 --- /dev/null +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/CMakeLists.txt @@ -0,0 +1,14 @@ +add_lldb_library(lldbPluginProcessFreeBSDKernelCore PLUGIN + ProcessFreeBSDKernelCore.cpp + RegisterContextFreeBSDKernelCore_arm64.cpp + RegisterContextFreeBSDKernelCore_i386.cpp + RegisterContextFreeBSDKernelCore_x86_64.cpp + ThreadFreeBSDKernelCore.cpp + + LINK_COMPONENTS + Support + LINK_LIBS + lldbCore + lldbTarget + kvm + ) diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.cpp b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.cpp similarity index 86% rename from lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.cpp rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.cpp index 26a6089c10a9a..73902c500dad8 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.cpp +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.cpp @@ -1,4 +1,4 @@ -//===-- ProcessFreeBSDKernel.cpp ------------------------------------------===// +//===-- ProcessFreeBSDKernelCore.cpp --------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -17,41 +17,41 @@ #include "lldb/Utility/StreamString.h" #include "Plugins/DynamicLoader/FreeBSD-Kernel/DynamicLoaderFreeBSDKernel.h" -#include "ProcessFreeBSDKernel.h" -#include "ThreadFreeBSDKernel.h" +#include "ProcessFreeBSDKernelCore.h" +#include "ThreadFreeBSDKernelCore.h" using namespace lldb; using namespace lldb_private; -LLDB_PLUGIN_DEFINE(ProcessFreeBSDKernel) +LLDB_PLUGIN_DEFINE(ProcessFreeBSDKernelCore) -ProcessFreeBSDKernel::ProcessFreeBSDKernel(lldb::TargetSP target_sp, - ListenerSP listener_sp, kvm_t *kvm, - const FileSpec &core_file) +ProcessFreeBSDKernelCore::ProcessFreeBSDKernelCore(lldb::TargetSP target_sp, + ListenerSP listener_sp, + kvm_t *kvm, + const FileSpec &core_file) : PostMortemProcess(target_sp, listener_sp, core_file), m_kvm(kvm) {} -ProcessFreeBSDKernel::~ProcessFreeBSDKernel() { +ProcessFreeBSDKernelCore::~ProcessFreeBSDKernelCore() { if (m_kvm) kvm_close(m_kvm); } -lldb::ProcessSP ProcessFreeBSDKernel::CreateInstance(lldb::TargetSP target_sp, - ListenerSP listener_sp, - const FileSpec *crash_file, - bool can_connect) { +lldb::ProcessSP ProcessFreeBSDKernelCore::CreateInstance( + lldb::TargetSP target_sp, ListenerSP listener_sp, + const FileSpec *crash_file, bool can_connect) { ModuleSP executable = target_sp->GetExecutableModule(); if (crash_file && !can_connect && executable) { kvm_t *kvm = kvm_open2(executable->GetFileSpec().GetPath().c_str(), crash_file->GetPath().c_str(), O_RDONLY, nullptr, nullptr); if (kvm) - return std::make_shared<ProcessFreeBSDKernel>(target_sp, listener_sp, kvm, + return std::make_shared<ProcessFreeBSDKernelCore>(target_sp, listener_sp, kvm, *crash_file); } return nullptr; } -void ProcessFreeBSDKernel::Initialize() { +void ProcessFreeBSDKernelCore::Initialize() { static llvm::once_flag g_once_flag; llvm::call_once(g_once_flag, []() { @@ -60,38 +60,38 @@ void ProcessFreeBSDKernel::Initialize() { }); } -void ProcessFreeBSDKernel::Terminate() { - PluginManager::UnregisterPlugin(ProcessFreeBSDKernel::CreateInstance); +void ProcessFreeBSDKernelCore::Terminate() { + PluginManager::UnregisterPlugin(ProcessFreeBSDKernelCore::CreateInstance); } -bool ProcessFreeBSDKernel::CanDebug(lldb::TargetSP target_sp, - bool plugin_specified_by_name) { +bool ProcessFreeBSDKernelCore::CanDebug(lldb::TargetSP target_sp, + bool plugin_specified_by_name) { return true; } -Status ProcessFreeBSDKernel::DoLoadCore() { +Status ProcessFreeBSDKernelCore::DoLoadCore() { // The core is already loaded by CreateInstance(). return Status(); } -DynamicLoader *ProcessFreeBSDKernel::GetDynamicLoader() { +DynamicLoader *ProcessFreeBSDKernelCore::GetDynamicLoader() { if (m_dyld_up.get() == nullptr) m_dyld_up.reset(DynamicLoader::FindPlugin( this, DynamicLoaderFreeBSDKernel::GetPluginNameStatic())); return m_dyld_up.get(); } -Status ProcessFreeBSDKernel::DoDestroy() { return Status(); } +Status ProcessFreeBSDKernelCore::DoDestroy() { return Status(); } -void ProcessFreeBSDKernel::RefreshStateAfterStop() { +void ProcessFreeBSDKernelCore::RefreshStateAfterStop() { if (!m_printed_unread_message) { PrintUnreadMessage(); m_printed_unread_message = true; } } -bool ProcessFreeBSDKernel::DoUpdateThreadList(ThreadList &old_thread_list, - ThreadList &new_thread_list) { +bool ProcessFreeBSDKernelCore::DoUpdateThreadList(ThreadList &old_thread_list, + ThreadList &new_thread_list) { if (old_thread_list.GetSize(false) == 0) { // Make up the thread the first time this is called so we can set our one // and only core thread state up. @@ -223,7 +223,7 @@ bool ProcessFreeBSDKernel::DoUpdateThreadList(ThreadList &old_thread_list, } auto thread = - new ThreadFreeBSDKernel(*this, tid, pcb_addr, thread_desc); + new ThreadFreeBSDKernelCore(*this, tid, pcb_addr, thread_desc); if (tid == dumptid) thread->SetIsCrashedThread(true); @@ -239,8 +239,8 @@ bool ProcessFreeBSDKernel::DoUpdateThreadList(ThreadList &old_thread_list, return new_thread_list.GetSize(false) > 0; } -size_t ProcessFreeBSDKernel::DoReadMemory(lldb::addr_t addr, void *buf, - size_t size, Status &error) { +size_t ProcessFreeBSDKernelCore::DoReadMemory(lldb::addr_t addr, void *buf, + size_t size, Status &error) { ssize_t rd = 0; rd = kvm_read2(m_kvm, addr, buf, size); if (rd < 0 || static_cast<size_t>(rd) != size) { @@ -251,13 +251,13 @@ size_t ProcessFreeBSDKernel::DoReadMemory(lldb::addr_t addr, void *buf, return rd; } -lldb::addr_t ProcessFreeBSDKernel::FindSymbol(const char *name) { +lldb::addr_t ProcessFreeBSDKernelCore::FindSymbol(const char *name) { ModuleSP mod_sp = GetTarget().GetExecutableModule(); const Symbol *sym = mod_sp->FindFirstSymbolWithNameAndType(ConstString(name)); return sym ? sym->GetLoadAddress(&GetTarget()) : LLDB_INVALID_ADDRESS; } -void ProcessFreeBSDKernel::PrintUnreadMessage() { +void ProcessFreeBSDKernelCore::PrintUnreadMessage() { Target &target = GetTarget(); Debugger &debugger = target.GetDebugger(); @@ -316,8 +316,9 @@ void ProcessFreeBSDKernel::PrintUnreadMessage() { } if (field_found != 4) { - LLDB_LOGF(GetLog(LLDBLog::Object), - "FreeBSDKernel: Could not find all required fields for msgbuf"); + LLDB_LOGF( + GetLog(LLDBLog::Object), + "FreeBSD-Kernel-Core: Could not find all required fields for msgbuf"); return; } } else { @@ -404,4 +405,4 @@ void ProcessFreeBSDKernel::PrintUnreadMessage() { stream_sp->Flush(); } -const char *ProcessFreeBSDKernel::GetError() { return kvm_geterr(m_kvm); } +const char *ProcessFreeBSDKernelCore::GetError() { return kvm_geterr(m_kvm); } diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.h b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.h similarity index 80% rename from lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.h rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.h index 40cd6cd66fd9d..284c7f01e01eb 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/ProcessFreeBSDKernel.h +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ProcessFreeBSDKernelCore.h @@ -1,4 +1,4 @@ -//===-- ProcessFreeBSDKernel.h ----------------------------------*- C++ -*-===// +//===-- ProcessFreeBSDKernelCore.h ------------------------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,19 +6,19 @@ // //===----------------------------------------------------------------------===// -#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNEL_H -#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNEL_H +#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNELCORE_H +#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNELCORE_H #include "lldb/Target/PostMortemProcess.h" #include <kvm.h> -class ProcessFreeBSDKernel : public lldb_private::PostMortemProcess { +class ProcessFreeBSDKernelCore : public lldb_private::PostMortemProcess { public: - ProcessFreeBSDKernel(lldb::TargetSP target_sp, lldb::ListenerSP listener, - kvm_t *kvm, const lldb_private::FileSpec &core_file); + ProcessFreeBSDKernelCore(lldb::TargetSP target_sp, lldb::ListenerSP listener, + kvm_t *kvm, const lldb_private::FileSpec &core_file); - ~ProcessFreeBSDKernel(); + ~ProcessFreeBSDKernelCore(); static lldb::ProcessSP CreateInstance(lldb::TargetSP target_sp, lldb::ListenerSP listener, @@ -29,10 +29,10 @@ class ProcessFreeBSDKernel : public lldb_private::PostMortemProcess { static void Terminate(); - static llvm::StringRef GetPluginNameStatic() { return "freebsd-kernel"; } + static llvm::StringRef GetPluginNameStatic() { return "freebsd-kernel-core"; } static llvm::StringRef GetPluginDescriptionStatic() { - return "FreeBSD kernel vmcore debugging plug-in."; + return "FreeBSD kernel core debugging plug-in."; } llvm::StringRef GetPluginName() override { return GetPluginNameStatic(); } @@ -67,4 +67,4 @@ class ProcessFreeBSDKernel : public lldb_private::PostMortemProcess { kvm_t *m_kvm; }; -#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNEL_H +#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_PROCESSFREEBSDKERNELCORE_H diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.cpp b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.cpp similarity index 88% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.cpp rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.cpp index 752cf6c5c035a..ab647e6308435 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.cpp +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.cpp @@ -1,4 +1,4 @@ -//===-- RegisterContextFreeBSDKernel_arm64.cpp ----------------------------===// +//===-- RegisterContextFreeBSDKernelCore_arm64.cpp ------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,7 +6,7 @@ // //===----------------------------------------------------------------------===// -#include "RegisterContextFreeBSDKernel_arm64.h" +#include "RegisterContextFreeBSDKernelCore_arm64.h" #include "Plugins/Process/Utility/lldb-arm64-register-enums.h" #include "lldb/Symbol/Symbol.h" @@ -21,27 +21,27 @@ using namespace lldb; using namespace lldb_private; -RegisterContextFreeBSDKernel_arm64::RegisterContextFreeBSDKernel_arm64( +RegisterContextFreeBSDKernelCore_arm64::RegisterContextFreeBSDKernelCore_arm64( Thread &thread, std::unique_ptr<RegisterInfoPOSIX_arm64> register_info_up, lldb::addr_t pcb_addr) : RegisterContextPOSIX_arm64(thread, std::move(register_info_up)), m_pcb_addr(pcb_addr) {} -bool RegisterContextFreeBSDKernel_arm64::ReadGPR() { return true; } +bool RegisterContextFreeBSDKernelCore_arm64::ReadGPR() { return true; } -bool RegisterContextFreeBSDKernel_arm64::ReadFPR() { return true; } +bool RegisterContextFreeBSDKernelCore_arm64::ReadFPR() { return true; } -bool RegisterContextFreeBSDKernel_arm64::WriteGPR() { +bool RegisterContextFreeBSDKernelCore_arm64::WriteGPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_arm64::WriteFPR() { +bool RegisterContextFreeBSDKernelCore_arm64::WriteFPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_arm64::ReadRegister( +bool RegisterContextFreeBSDKernelCore_arm64::ReadRegister( const RegisterInfo *reg_info, RegisterValue &value) { if (m_pcb_addr == LLDB_INVALID_ADDRESS) return false; @@ -165,12 +165,12 @@ bool RegisterContextFreeBSDKernel_arm64::ReadRegister( return true; } -bool RegisterContextFreeBSDKernel_arm64::WriteRegister( +bool RegisterContextFreeBSDKernelCore_arm64::WriteRegister( const RegisterInfo *reg_info, const RegisterValue &value) { return false; } -std::optional<int> RegisterContextFreeBSDKernel_arm64::GetOsreldate() { +std::optional<int> RegisterContextFreeBSDKernelCore_arm64::GetOsreldate() { ProcessSP process_sp = m_thread.GetProcess(); if (!process_sp) return std::nullopt; diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.h b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.h similarity index 81% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.h rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.h index 8d2a9c33639e3..ad82fb041df03 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_arm64.h +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_arm64.h @@ -1,4 +1,4 @@ -//===-- RegisterContextFreeBSDKernel_arm64.h --------------------*- C++ -*-===// +//===-- RegisterContextFreeBSDKernelCore_arm64.h ----------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,17 +6,18 @@ // //===----------------------------------------------------------------------===// -#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_ARM64_H -#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_ARM64_H +#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_ARM64_H +#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_ARM64_H #include "Plugins/Process/Utility/RegisterContextPOSIX_arm64.h" #include "Plugins/Process/elf-core/RegisterUtilities.h" #include <optional> -class RegisterContextFreeBSDKernel_arm64 : public RegisterContextPOSIX_arm64 { +class RegisterContextFreeBSDKernelCore_arm64 + : public RegisterContextPOSIX_arm64 { public: - RegisterContextFreeBSDKernel_arm64( + RegisterContextFreeBSDKernelCore_arm64( lldb_private::Thread &thread, std::unique_ptr<RegisterInfoPOSIX_arm64> register_info_up, lldb::addr_t pcb_addr); @@ -42,4 +43,4 @@ class RegisterContextFreeBSDKernel_arm64 : public RegisterContextPOSIX_arm64 { std::optional<int> GetOsreldate(); }; -#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_ARM64_H +#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_ARM64_H diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.cpp b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.cpp similarity index 76% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.cpp rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.cpp index 6727a75bd0af0..8334f8a34763c 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.cpp +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.cpp @@ -1,4 +1,4 @@ -//===-- RegisterContextFreeBSDKernel_i386.cpp -----------------------------===// +//===-- RegisterContextFreeBSDKernelCore_i386.cpp -------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,7 +6,7 @@ // //===----------------------------------------------------------------------===// -#include "RegisterContextFreeBSDKernel_i386.h" +#include "RegisterContextFreeBSDKernelCore_i386.h" #include "lldb/Target/Process.h" #include "lldb/Target/Thread.h" @@ -16,26 +16,26 @@ using namespace lldb; using namespace lldb_private; -RegisterContextFreeBSDKernel_i386::RegisterContextFreeBSDKernel_i386( +RegisterContextFreeBSDKernelCore_i386::RegisterContextFreeBSDKernelCore_i386( Thread &thread, RegisterInfoInterface *register_info, lldb::addr_t pcb_addr) : RegisterContextPOSIX_x86(thread, 0, register_info), m_pcb_addr(pcb_addr) { } -bool RegisterContextFreeBSDKernel_i386::ReadGPR() { return true; } +bool RegisterContextFreeBSDKernelCore_i386::ReadGPR() { return true; } -bool RegisterContextFreeBSDKernel_i386::ReadFPR() { return true; } +bool RegisterContextFreeBSDKernelCore_i386::ReadFPR() { return true; } -bool RegisterContextFreeBSDKernel_i386::WriteGPR() { +bool RegisterContextFreeBSDKernelCore_i386::WriteGPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_i386::WriteFPR() { +bool RegisterContextFreeBSDKernelCore_i386::WriteFPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_i386::ReadRegister( +bool RegisterContextFreeBSDKernelCore_i386::ReadRegister( const RegisterInfo *reg_info, RegisterValue &value) { if (m_pcb_addr == LLDB_INVALID_ADDRESS) return false; @@ -78,7 +78,7 @@ bool RegisterContextFreeBSDKernel_i386::ReadRegister( return true; } -bool RegisterContextFreeBSDKernel_i386::WriteRegister( +bool RegisterContextFreeBSDKernelCore_i386::WriteRegister( const RegisterInfo *reg_info, const RegisterValue &value) { return false; } diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.h b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.h similarity index 81% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.h rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.h index 9a2ac638dfea8..a4b0385e9a6db 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.h +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_i386.h @@ -1,4 +1,4 @@ -//===-- RegisterContextFreeBSDKernel_x86_64.h -------------------*- C++ -*-===// +//===-- RegisterContextFreeBSDKernelCore_i386.h -----------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,15 +6,15 @@ // //===----------------------------------------------------------------------===// -#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_X86_64_H -#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_X86_64_H +#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_I386_H +#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_I386_H #include "Plugins/Process/Utility/RegisterContextPOSIX_x86.h" #include "Plugins/Process/elf-core/RegisterUtilities.h" -class RegisterContextFreeBSDKernel_x86_64 : public RegisterContextPOSIX_x86 { +class RegisterContextFreeBSDKernelCore_i386 : public RegisterContextPOSIX_x86 { public: - RegisterContextFreeBSDKernel_x86_64( + RegisterContextFreeBSDKernelCore_i386( lldb_private::Thread &thread, lldb_private::RegisterInfoInterface *register_info, lldb::addr_t pcb_addr); @@ -38,4 +38,4 @@ class RegisterContextFreeBSDKernel_x86_64 : public RegisterContextPOSIX_x86 { lldb::addr_t m_pcb_addr; }; -#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_X86_64_H +#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_I386_H diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.cpp b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.cpp similarity index 72% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.cpp rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.cpp index bf5d9db7a0995..62884954aa8cf 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_x86_64.cpp +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.cpp @@ -1,4 +1,5 @@ -//===-- RegisterContextFreeBSDKernel_x86_64.cpp ---------------------------===// +//===-- RegisterContextFreeBSDKernelCore_x86_64.cpp +//---------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,7 +7,7 @@ // //===----------------------------------------------------------------------===// -#include "RegisterContextFreeBSDKernel_x86_64.h" +#include "RegisterContextFreeBSDKernelCore_x86_64.h" #include "lldb/Target/Process.h" #include "lldb/Target/Thread.h" @@ -16,26 +17,28 @@ using namespace lldb; using namespace lldb_private; -RegisterContextFreeBSDKernel_x86_64::RegisterContextFreeBSDKernel_x86_64( - Thread &thread, RegisterInfoInterface *register_info, lldb::addr_t pcb_addr) +RegisterContextFreeBSDKernelCore_x86_64:: + RegisterContextFreeBSDKernelCore_x86_64( + Thread &thread, RegisterInfoInterface *register_info, + lldb::addr_t pcb_addr) : RegisterContextPOSIX_x86(thread, 0, register_info), m_pcb_addr(pcb_addr) { } -bool RegisterContextFreeBSDKernel_x86_64::ReadGPR() { return true; } +bool RegisterContextFreeBSDKernelCore_x86_64::ReadGPR() { return true; } -bool RegisterContextFreeBSDKernel_x86_64::ReadFPR() { return true; } +bool RegisterContextFreeBSDKernelCore_x86_64::ReadFPR() { return true; } -bool RegisterContextFreeBSDKernel_x86_64::WriteGPR() { +bool RegisterContextFreeBSDKernelCore_x86_64::WriteGPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_x86_64::WriteFPR() { +bool RegisterContextFreeBSDKernelCore_x86_64::WriteFPR() { assert(0); return false; } -bool RegisterContextFreeBSDKernel_x86_64::ReadRegister( +bool RegisterContextFreeBSDKernelCore_x86_64::ReadRegister( const RegisterInfo *reg_info, RegisterValue &value) { if (m_pcb_addr == LLDB_INVALID_ADDRESS) return false; @@ -83,7 +86,7 @@ bool RegisterContextFreeBSDKernel_x86_64::ReadRegister( return true; } -bool RegisterContextFreeBSDKernel_x86_64::WriteRegister( +bool RegisterContextFreeBSDKernelCore_x86_64::WriteRegister( const RegisterInfo *reg_info, const RegisterValue &value) { return false; } diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.h b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.h similarity index 80% rename from lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.h rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.h index 218e3374f8df4..adae1ac91c2d3 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/RegisterContextFreeBSDKernel_i386.h +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/RegisterContextFreeBSDKernelCore_x86_64.h @@ -1,4 +1,4 @@ -//===-- RegisterContextFreeBSDKernel_i386.h ---------------------*- C++ -*-===// +//===-- RegisterContextFreeBSDKernelCore_x86_64.h ---------------*- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,15 +6,16 @@ // //===----------------------------------------------------------------------===// -#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_I386_H -#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_I386_H +#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_X86_64_H +#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_X86_64_H #include "Plugins/Process/Utility/RegisterContextPOSIX_x86.h" #include "Plugins/Process/elf-core/RegisterUtilities.h" -class RegisterContextFreeBSDKernel_i386 : public RegisterContextPOSIX_x86 { +class RegisterContextFreeBSDKernelCore_x86_64 + : public RegisterContextPOSIX_x86 { public: - RegisterContextFreeBSDKernel_i386( + RegisterContextFreeBSDKernelCore_x86_64( lldb_private::Thread &thread, lldb_private::RegisterInfoInterface *register_info, lldb::addr_t pcb_addr); @@ -38,4 +39,4 @@ class RegisterContextFreeBSDKernel_i386 : public RegisterContextPOSIX_x86 { lldb::addr_t m_pcb_addr; }; -#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNEL_I386_H +#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_REGISTERCONTEXTFREEBSDKERNELCORE_X86_64_H diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.cpp b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.cpp similarity index 58% rename from lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.cpp rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.cpp index dd1ed52719749..9737adeebfec6 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.cpp +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.cpp @@ -1,4 +1,4 @@ -//===-- ThreadFreeBSDKernel.cpp -------------------------------------------===// +//===-- ThreadFreeBSDKernelCore.cpp ---------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,7 +6,7 @@ // //===----------------------------------------------------------------------===// -#include "ThreadFreeBSDKernel.h" +#include "ThreadFreeBSDKernelCore.h" #include "lldb/Target/StopInfo.h" #include "lldb/Target/Unwind.h" @@ -15,32 +15,33 @@ #include "Plugins/Process/Utility/RegisterContextFreeBSD_i386.h" #include "Plugins/Process/Utility/RegisterContextFreeBSD_x86_64.h" #include "Plugins/Process/Utility/RegisterInfoPOSIX_arm64.h" -#include "ProcessFreeBSDKernel.h" -#include "RegisterContextFreeBSDKernel_arm64.h" -#include "RegisterContextFreeBSDKernel_i386.h" -#include "RegisterContextFreeBSDKernel_x86_64.h" +#include "ProcessFreeBSDKernelCore.h" +#include "RegisterContextFreeBSDKernelCore_arm64.h" +#include "RegisterContextFreeBSDKernelCore_i386.h" +#include "RegisterContextFreeBSDKernelCore_x86_64.h" using namespace lldb; using namespace lldb_private; -ThreadFreeBSDKernel::ThreadFreeBSDKernel(Process &process, lldb::tid_t tid, - lldb::addr_t pcb_addr, - std::string thread_name) +ThreadFreeBSDKernelCore::ThreadFreeBSDKernelCore(Process &process, + lldb::tid_t tid, + lldb::addr_t pcb_addr, + std::string thread_name) : Thread(process, tid), m_thread_name(std::move(thread_name)), m_pcb_addr(pcb_addr) {} -ThreadFreeBSDKernel::~ThreadFreeBSDKernel() {} +ThreadFreeBSDKernelCore::~ThreadFreeBSDKernelCore() {} -void ThreadFreeBSDKernel::RefreshStateAfterStop() {} +void ThreadFreeBSDKernelCore::RefreshStateAfterStop() {} -lldb::RegisterContextSP ThreadFreeBSDKernel::GetRegisterContext() { +lldb::RegisterContextSP ThreadFreeBSDKernelCore::GetRegisterContext() { if (!m_reg_context_sp) m_reg_context_sp = CreateRegisterContextForFrame(nullptr); return m_reg_context_sp; } lldb::RegisterContextSP -ThreadFreeBSDKernel::CreateRegisterContextForFrame(StackFrame *frame) { +ThreadFreeBSDKernelCore::CreateRegisterContextForFrame(StackFrame *frame) { RegisterContextSP reg_ctx_sp; uint32_t concrete_frame_idx = 0; @@ -51,28 +52,30 @@ ThreadFreeBSDKernel::CreateRegisterContextForFrame(StackFrame *frame) { if (m_thread_reg_ctx_sp) return m_thread_reg_ctx_sp; - ProcessFreeBSDKernel *process = - static_cast<ProcessFreeBSDKernel *>(GetProcess().get()); + ProcessFreeBSDKernelCore *process = + static_cast<ProcessFreeBSDKernelCore *>(GetProcess().get()); ArchSpec arch = process->GetTarget().GetArchitecture(); switch (arch.GetMachine()) { case llvm::Triple::aarch64: m_thread_reg_ctx_sp = - std::make_shared<RegisterContextFreeBSDKernel_arm64>( + std::make_shared<RegisterContextFreeBSDKernelCore_arm64>( *this, std::make_unique<RegisterInfoPOSIX_arm64>(arch, 0), m_pcb_addr); break; case llvm::Triple::x86: - m_thread_reg_ctx_sp = std::make_shared<RegisterContextFreeBSDKernel_i386>( - *this, new RegisterContextFreeBSD_i386(arch), m_pcb_addr); + m_thread_reg_ctx_sp = + std::make_shared<RegisterContextFreeBSDKernelCore_i386>( + *this, new RegisterContextFreeBSD_i386(arch), m_pcb_addr); break; case llvm::Triple::x86_64: m_thread_reg_ctx_sp = - std::make_shared<RegisterContextFreeBSDKernel_x86_64>( + std::make_shared<RegisterContextFreeBSDKernelCore_x86_64>( *this, new RegisterContextFreeBSD_x86_64(arch), m_pcb_addr); break; default: - assert(false && "Unsupported architecture passed to ThreadFreeBSDKernel"); + assert(false && + "Unsupported architecture passed to ThreadFreeBSDKernelCore"); break; } @@ -83,7 +86,7 @@ ThreadFreeBSDKernel::CreateRegisterContextForFrame(StackFrame *frame) { return reg_ctx_sp; } -bool ThreadFreeBSDKernel::CalculateStopInfo() { +bool ThreadFreeBSDKernelCore::CalculateStopInfo() { if (m_is_crashed) { // Set a stop reason for crashing threads only so that they get selected // preferentially. diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.h b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.h similarity index 78% rename from lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.h rename to lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.h index 42f5b93bb74c5..f2a33b2e0d84d 100644 --- a/lldb/source/Plugins/Process/FreeBSDKernel/ThreadFreeBSDKernel.h +++ b/lldb/source/Plugins/Process/FreeBSD-Kernel-Core/ThreadFreeBSDKernelCore.h @@ -1,4 +1,4 @@ -//===-- ThreadFreeBSDKernel.h ------------------------------------- C++ -*-===// +//===-- ThreadFreeBSDKernelCore.h --------------------------------- C++ -*-===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -6,17 +6,17 @@ // //===----------------------------------------------------------------------===// -#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNEL_H -#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNEL_H +#ifndef LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNELCORE_H +#define LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNELCORE_H #include "lldb/Target/Thread.h" -class ThreadFreeBSDKernel : public lldb_private::Thread { +class ThreadFreeBSDKernelCore : public lldb_private::Thread { public: - ThreadFreeBSDKernel(lldb_private::Process &process, lldb::tid_t tid, - lldb::addr_t pcb_addr, std::string thread_name); + ThreadFreeBSDKernelCore(lldb_private::Process &process, lldb::tid_t tid, + lldb::addr_t pcb_addr, std::string thread_name); - ~ThreadFreeBSDKernel() override; + ~ThreadFreeBSDKernelCore() override; void RefreshStateAfterStop() override; @@ -49,4 +49,4 @@ class ThreadFreeBSDKernel : public lldb_private::Thread { bool m_is_crashed = false; }; -#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNEL_H +#endif // LLDB_SOURCE_PLUGINS_PROCESS_FREEBSDKERNEL_THREADFREEBSDKERNELCORE_H diff --git a/lldb/source/Plugins/Process/FreeBSDKernel/CMakeLists.txt b/lldb/source/Plugins/Process/FreeBSDKernel/CMakeLists.txt deleted file mode 100644 index 2d90d0c333026..0000000000000 --- a/lldb/source/Plugins/Process/FreeBSDKernel/CMakeLists.txt +++ /dev/null @@ -1,14 +0,0 @@ -add_lldb_library(lldbPluginProcessFreeBSDKernel PLUGIN - ProcessFreeBSDKernel.cpp - RegisterContextFreeBSDKernel_arm64.cpp - RegisterContextFreeBSDKernel_i386.cpp - RegisterContextFreeBSDKernel_x86_64.cpp - ThreadFreeBSDKernel.cpp - - LINK_COMPONENTS - Support - LINK_LIBS - lldbCore - lldbTarget - kvm - ) diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/TestFreeBSDKernelLive.py b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/TestFreeBSDKernelLiveCore.py similarity index 96% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/TestFreeBSDKernelLive.py rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/TestFreeBSDKernelLiveCore.py index 689f76959150f..2fd8c3e2200d0 100644 --- a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/TestFreeBSDKernelLive.py +++ b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/TestFreeBSDKernelLiveCore.py @@ -8,7 +8,7 @@ from lldbsuite.test import lldbutil -class FreeBSDKernelVMCoreTestCase(TestBase): +class FreeBSDKernelLiveCoreTestCase(TestBase): NO_DEBUG_INFO_TESTCASE = True def test_mem(self): diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/TestFreeBSDKernelVMCore.py b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/TestFreeBSDKernelVMCore.py similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/TestFreeBSDKernelVMCore.py rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/TestFreeBSDKernelVMCore.py diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-amd64.yaml b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-amd64.yaml similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-amd64.yaml rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-amd64.yaml diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-arm64.yaml b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-arm64.yaml similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-arm64.yaml rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-arm64.yaml diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-i386.yaml b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-i386.yaml similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/kernel-i386.yaml rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/kernel-i386.yaml diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/README.rst b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/README.rst similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/README.rst rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/README.rst diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/copy-sparse.py b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/copy-sparse.py similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/copy-sparse.py rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/copy-sparse.py diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/libfbsdvmcore-hacks.patch b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/libfbsdvmcore-hacks.patch similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/libfbsdvmcore-hacks.patch rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/libfbsdvmcore-hacks.patch diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/lldb-minimize-processes.patch b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/lldb-minimize-processes.patch similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/lldb-minimize-processes.patch rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/lldb-minimize-processes.patch diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/test.script b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/test.script similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/tools/test.script rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/tools/test.script diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-amd64-full.bz2 b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-amd64-full.bz2 similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-amd64-full.bz2 rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-amd64-full.bz2 diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-amd64-minidump.bz2 b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-amd64-minidump.bz2 similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-amd64-minidump.bz2 rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-amd64-minidump.bz2 diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-arm64-minidump.bz2 b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-arm64-minidump.bz2 similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-arm64-minidump.bz2 rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-arm64-minidump.bz2 diff --git a/lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-i386-minidump.bz2 b/lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-i386-minidump.bz2 similarity index 100% rename from lldb/test/API/functionalities/postmortem/FreeBSDKernel/vmcore-i386-minidump.bz2 rename to lldb/test/API/functionalities/postmortem/FreeBSD-Kernel-Core/vmcore-i386-minidump.bz2 diff --git a/llvm/docs/ReleaseNotes.md b/llvm/docs/ReleaseNotes.md index 77990611f6085..417740af13fd0 100644 --- a/llvm/docs/ReleaseNotes.md +++ b/llvm/docs/ReleaseNotes.md @@ -211,6 +211,8 @@ Changes to LLDB #### Kernel Debugging +* The plugin that analyzes FreeBSD kernel core dump and live core has been renamed from `FreeBSDKernel` to + `FreeBSD-Kernel-Core`. Remote kernel debugging is still handled by the `gdb-remote` plugin. * Support for libfbsdvmcore has been removed. As a result, FreeBSD kernel dump debugging is now only available on FreeBSD hosts. Live kernel debugging through the GDB remote protocol is still available from any platform. _______________________________________________ lldb-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
