1*d409305fSDimitry Andric //===-- NativeRegisterContextFreeBSD.h --------------------------*- C++ -*-===// 2*d409305fSDimitry Andric // 3*d409305fSDimitry Andric // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4*d409305fSDimitry Andric // See https://llvm.org/LICENSE.txt for license information. 5*d409305fSDimitry Andric // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6*d409305fSDimitry Andric // 7*d409305fSDimitry Andric //===----------------------------------------------------------------------===// 8*d409305fSDimitry Andric 9*d409305fSDimitry Andric #ifndef lldb_NativeRegisterContextFreeBSD_h 10*d409305fSDimitry Andric #define lldb_NativeRegisterContextFreeBSD_h 11*d409305fSDimitry Andric 12*d409305fSDimitry Andric #include "lldb/Host/common/NativeThreadProtocol.h" 13*d409305fSDimitry Andric 14*d409305fSDimitry Andric #include "Plugins/Process/Utility/NativeRegisterContextRegisterInfo.h" 15*d409305fSDimitry Andric 16*d409305fSDimitry Andric namespace lldb_private { 17*d409305fSDimitry Andric namespace process_freebsd { 18*d409305fSDimitry Andric 19*d409305fSDimitry Andric class NativeProcessFreeBSD; 20*d409305fSDimitry Andric 21*d409305fSDimitry Andric class NativeRegisterContextFreeBSD 22*d409305fSDimitry Andric : public virtual NativeRegisterContextRegisterInfo { 23*d409305fSDimitry Andric public: 24*d409305fSDimitry Andric // This function is implemented in the NativeRegisterContextFreeBSD_* 25*d409305fSDimitry Andric // subclasses to create a new instance of the host specific 26*d409305fSDimitry Andric // NativeRegisterContextFreeBSD. The implementations can't collide as only one 27*d409305fSDimitry Andric // NativeRegisterContextFreeBSD_* variant should be compiled into the final 28*d409305fSDimitry Andric // executable. 29*d409305fSDimitry Andric static NativeRegisterContextFreeBSD * 30*d409305fSDimitry Andric CreateHostNativeRegisterContextFreeBSD(const ArchSpec &target_arch, 31*d409305fSDimitry Andric NativeThreadProtocol &native_thread); 32*d409305fSDimitry Andric virtual llvm::Error 33*d409305fSDimitry Andric CopyHardwareWatchpointsFrom(NativeRegisterContextFreeBSD &source) = 0; 34*d409305fSDimitry Andric 35*d409305fSDimitry Andric protected: 36*d409305fSDimitry Andric virtual NativeProcessFreeBSD &GetProcess(); 37*d409305fSDimitry Andric virtual ::pid_t GetProcessPid(); 38*d409305fSDimitry Andric }; 39*d409305fSDimitry Andric 40*d409305fSDimitry Andric } // namespace process_freebsd 41*d409305fSDimitry Andric } // namespace lldb_private 42*d409305fSDimitry Andric 43*d409305fSDimitry Andric #endif // #ifndef lldb_NativeRegisterContextFreeBSD_h 44