summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
diff options
context:
space:
mode:
authorJason Molenda <jmolenda@apple.com>2017-06-29 02:57:03 +0000
committerJason Molenda <jmolenda@apple.com>2017-06-29 02:57:03 +0000
commit43294c9f48760eae68aa8976bf0ac5e9eaa448d8 (patch)
tree4585cb01cd88fd39a900aa062686601930eb9e34 /lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
parent8e07cadde0ba53385afd4762af3a12412609483b (diff)
downloadbcm5719-llvm-43294c9f48760eae68aa8976bf0ac5e9eaa448d8.tar.gz
bcm5719-llvm-43294c9f48760eae68aa8976bf0ac5e9eaa448d8.zip
Change the ABI class to have a weak pointer to its Process;
some methods in the ABI need a Process to do their work. Instead of passing it in as a one-off argument to those methods, this patch puts it in the base class and the methods can retrieve if it needed. Note that ABI's are sometimes built without a Process (e.g. SBTarget::GetStackRedZoneSize) so it's entirely possible that the process weak pointer will not be able to reconsistitue into a strong pointer. <rdar://problem/32526754> llvm-svn: 306633
Diffstat (limited to 'lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp')
-rw-r--r--lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
index aeb7c742b4f..ac64b689f4c 100644
--- a/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
+++ b/lldb/source/Plugins/Process/gdb-remote/ProcessGDBRemote.cpp
@@ -599,7 +599,7 @@ void ProcessGDBRemote::BuildDynamicRegisterInfo(bool force) {
// gets called in DidAttach, when the target architecture (and
// consequently the ABI we'll get from
// the process) may be wrong.
- ABISP abi_to_use = ABI::FindPlugin(arch_to_use);
+ ABISP abi_to_use = ABI::FindPlugin(shared_from_this(), arch_to_use);
AugmentRegisterInfoViaABI(reg_info, reg_name, abi_to_use);
@@ -4419,7 +4419,7 @@ bool ProcessGDBRemote::GetGDBServerRegisterInfo(ArchSpec &arch_to_use) {
// that context we haven't
// set the Target's architecture yet, so the ABI is also potentially
// incorrect.
- ABISP abi_to_use_sp = ABI::FindPlugin(arch_to_use);
+ ABISP abi_to_use_sp = ABI::FindPlugin(shared_from_this(), arch_to_use);
if (feature_node) {
ParseRegisters(feature_node, target_info, this->m_register_info,
abi_to_use_sp, cur_reg_num, reg_offset);
OpenPOWER on IntegriCloud