diff options
author | Felipe de Azevedo Piovezan <fpiovezan@apple.com> | 2024-09-04 07:02:55 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-09-04 07:02:55 -0700 |
commit | 1b0a80249399dadfe0c3f682fff77bf9eb666535 (patch) | |
tree | c2e623f22b1bd0697ec5abb4971f443c566f36c6 /lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp | |
parent | 7732d8e51819416b9d28b1815bdf81d0e0642b04 (diff) | |
download | llvm-1b0a80249399dadfe0c3f682fff77bf9eb666535.zip llvm-1b0a80249399dadfe0c3f682fff77bf9eb666535.tar.gz llvm-1b0a80249399dadfe0c3f682fff77bf9eb666535.tar.bz2 |
[GDBRemote] Handle 'heap' memory region info type (#105883)
This should cause the memory region info "is stack" field to be set to
"no".
Diffstat (limited to 'lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp')
-rw-r--r-- | lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp b/lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp index 18020c8e..ce5ab2c 100644 --- a/lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp +++ b/lldb/unittests/Process/gdb-remote/GDBRemoteCommunicationClientTest.cpp @@ -364,6 +364,15 @@ TEST_F(GDBRemoteCommunicationClientTest, GetMemoryRegionInfo) { EXPECT_TRUE(result.get().Success()); EXPECT_EQ(MemoryRegionInfo::eYes, region_info.GetMemoryTagged()); EXPECT_EQ(MemoryRegionInfo::eYes, region_info.IsStackMemory()); + + result = std::async(std::launch::async, [&] { + return client.GetMemoryRegionInfo(addr, region_info); + }); + + HandlePacket(server, "qMemoryRegionInfo:a000", + "start:a000;size:2000;type:heap;"); + EXPECT_TRUE(result.get().Success()); + EXPECT_EQ(MemoryRegionInfo::eNo, region_info.IsStackMemory()); } TEST_F(GDBRemoteCommunicationClientTest, GetMemoryRegionInfoInvalidResponse) { |