summaryrefslogtreecommitdiffstats
path: root/lldb/source/Plugins/Process
diff options
context:
space:
mode:
authorJustin Hibbits <jrh29@alumni.cwru.edu>2015-02-08 21:23:23 +0000
committerJustin Hibbits <jrh29@alumni.cwru.edu>2015-02-08 21:23:23 +0000
commit5c0b98e205b3c31e1a430d5ec4951cd23922e4c0 (patch)
tree2fd6ca7d86360321c43b1b6c189d41bab3efee4d /lldb/source/Plugins/Process
parentbaf0a2415cc24f10b9ee241367ade87cde758d2d (diff)
downloadbcm5719-llvm-5c0b98e205b3c31e1a430d5ec4951cd23922e4c0.tar.gz
bcm5719-llvm-5c0b98e205b3c31e1a430d5ec4951cd23922e4c0.zip
Fix off-by-one IsGPR().
f0 was being counted as a GPR, due to the check in IsGPR(). Correct it by looking at the precise GPR range. llvm-svn: 228547
Diffstat (limited to 'lldb/source/Plugins/Process')
-rw-r--r--lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp b/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp
index fdd0da52b64..828fb2571f7 100644
--- a/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp
+++ b/lldb/source/Plugins/Process/Utility/RegisterContextPOSIX_powerpc.cpp
@@ -161,7 +161,7 @@ g_reg_sets_powerpc[k_num_register_sets] =
bool RegisterContextPOSIX_powerpc::IsGPR(unsigned reg)
{
- return reg <= k_num_gpr_registers_powerpc; // GPR's come first.
+ return (reg >= k_first_gpr_powerpc) && (reg <= k_last_gpr_powerpc); // GPR's come first.
}
bool
OpenPOWER on IntegriCloud