mohit.bhakkad created this revision.
mohit.bhakkad added reviewers: bhushan, jaydeep.
mohit.bhakkad added subscribers: lldb-commits, sagar, nitesh.jain.
mohit.bhakkad set the repository for this revision to rL LLVM.
Index for H/W watchpoint regsisters starts from 0, so considering 0 as failure
is wrong.
Repository:
rL LLVM
http://reviews.llvm.org/D14860
Files:
source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
Index: source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
===================================================================
--- source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
+++ source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
@@ -1092,7 +1092,7 @@
}
}
}
- return 0;
+ return LLDB_INVALID_INDEX32;
}
bool
@@ -1221,7 +1221,7 @@
int index = GetVacantWatchIndex (®s, addr, size, watch_flags,
NumSupportedHardwareWatchpoints());
// New watchpoint doesn't fit
- if (!index)
+ if (index == LLDB_INVALID_INDEX32)
return LLDB_INVALID_INDEX32;
Index: source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
===================================================================
--- source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
+++ source/Plugins/Process/Linux/NativeRegisterContextLinux_mips64.cpp
@@ -1092,7 +1092,7 @@
}
}
}
- return 0;
+ return LLDB_INVALID_INDEX32;
}
bool
@@ -1221,7 +1221,7 @@
int index = GetVacantWatchIndex (®s, addr, size, watch_flags, NumSupportedHardwareWatchpoints());
// New watchpoint doesn't fit
- if (!index)
+ if (index == LLDB_INVALID_INDEX32)
return LLDB_INVALID_INDEX32;
_______________________________________________
lldb-commits mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits