diff options
| author | Mohit K. Bhakkad <mohit.bhakkad@gmail.com> | 2015-03-17 11:43:56 +0000 |
|---|---|---|
| committer | Mohit K. Bhakkad <mohit.bhakkad@gmail.com> | 2015-03-17 11:43:56 +0000 |
| commit | 3df471c32de4bba7395662f01e2036ff45e40e18 (patch) | |
| tree | 128d6aac13eff0431e714598dc0d7ad588f893d6 /lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp | |
| parent | 08288606942ddbcf68280cebac29d1182ac9855f (diff) | |
| download | bcm5719-llvm-3df471c32de4bba7395662f01e2036ff45e40e18.tar.gz bcm5719-llvm-3df471c32de4bba7395662f01e2036ff45e40e18.zip | |
[MIPS] - Register Context for MIPS64
Patch by Jaydeep Patil
Summery:
1. Add MIPS variants by parsing e_flags of the ELF
2. Create RegisterInfoInterface and RegisterContext for MIPS64 and MIPS64EL
Reviewers: clayborg
Subscribers: tberghammer, bhushan, mohit.bhakkad, sagar
Differential Revision: http://reviews.llvm.org/D8166
llvm-svn: 232467
Diffstat (limited to 'lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp')
| -rw-r--r-- | lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp b/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp index 8f1a2e2d443..de7c8fc2620 100644 --- a/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp +++ b/lldb/source/Plugins/Process/Linux/NativeThreadLinux.cpp @@ -15,6 +15,7 @@ #include "NativeProcessLinux.h" #include "NativeRegisterContextLinux_arm64.h" #include "NativeRegisterContextLinux_x86_64.h" +#include "NativeRegisterContextLinux_mips64.h" #include "lldb/Core/Log.h" #include "lldb/Core/State.h" @@ -31,6 +32,7 @@ #include "Plugins/Process/Utility/RegisterContextLinux_arm64.h" #include "Plugins/Process/Utility/RegisterContextLinux_i386.h" #include "Plugins/Process/Utility/RegisterContextLinux_x86_64.h" +#include "Plugins/Process/Utility/RegisterContextLinux_mips64.h" #include "Plugins/Process/Utility/RegisterInfoInterface.h" using namespace lldb; @@ -175,6 +177,12 @@ NativeThreadLinux::GetRegisterContext () reg_interface = static_cast<RegisterInfoInterface*> (new RegisterContextLinux_x86_64 (target_arch)); } break; + case llvm::Triple::mips64: + case llvm::Triple::mips64el: + assert((HostInfo::GetArchitecture ().GetAddressByteSize() == 8) + && "Register setting path assumes this is a 64-bit host"); + reg_interface = static_cast<RegisterInfoInterface*>(new RegisterContextLinux_mips64 (target_arch)); + break; default: break; } @@ -199,6 +207,13 @@ NativeThreadLinux::GetRegisterContext () break; } #endif + case llvm::Triple::mips64: + case llvm::Triple::mips64el: + { + const uint32_t concrete_frame_idx = 0; + m_reg_context_sp.reset (new NativeRegisterContextLinux_mips64 (*this, concrete_frame_idx, reg_interface)); + break; + } case llvm::Triple::aarch64: { const uint32_t concrete_frame_idx = 0; |

