[Lldb-commits] [lldb] [debugserver] Implement MultiMemRead packet (PR #162670)
David Spickett via lldb-commits
lldb-commits at lists.llvm.org
Fri Oct 10 09:08:25 PDT 2025
================
@@ -0,0 +1,10 @@
+#include <stdlib.h>
+#include <string.h>
+
+int main(int argc, char **argv) {
+ char *memory = malloc(1024);
+ memset(memory, '-', 1024);
+ for (int i = 0; i < 50; i++)
+ memory[i] = 'a' + i;
+ return 0; // break here
----------------
DavidSpickett wrote:
The idea here is the a-z gives you a pattern to look for, and if we ever see the dashes, we know it didn't read correctly?
(and you didn't calloc it because all 0s could be the result of us forgetting to actually read anything)
In which case would it be a bit more rigorous to offset the a-z a bit from the start of the region? Now if you have an overread, we see dashes, but if we underread, then we get random bytes. The test would still fail but it would be random what wrong bytes we saw.
https://github.com/llvm/llvm-project/pull/162670
More information about the lldb-commits
mailing list