Skip to content

Commit b7c9fc1

Browse files
committed
[lldb][Darwin] Add MTE test for memory region command
1 parent 5a87f39 commit b7c9fc1

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

lldb/test/API/macosx/mte/TestDarwinMTE.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,23 @@ def test_tag_fault(self):
3232
],
3333
)
3434

35+
@skipUnlessFeature(cpu_feature.AArch64.MTE)
36+
def test_memory_region(self):
37+
self.build()
38+
lldbutil.run_to_source_breakpoint(
39+
self, "// before free", lldb.SBFileSpec("main.c"), exe_name=exe_name
40+
)
41+
42+
# (lldb) memory region ptr
43+
# [0x00000001005ec000-0x00000001009ec000) rw-
44+
# memory tagging: enabled
45+
# Modified memory (dirty) page list provided, 2 entries.
46+
# Dirty pages: 0x1005ec000, 0x1005fc000.
47+
self.expect(
48+
"memory region ptr",
49+
substrs=[") rw-", "memory tagging: enabled"]
50+
)
51+
3552
@skipUnlessFeature(cpu_feature.AArch64.MTE)
3653
def test_memory_read_with_tags(self):
3754
self.build()

0 commit comments

Comments
 (0)