From 92d2a03f045f833fa96d8d1ed909d2bce68cefea Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Wed, 16 Aug 2023 10:33:28 -0700 Subject: [PATCH] linux-user: Show heap address in /proc/pid/maps MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Tested-by: Helge Deller Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Ilya Leoshkevich Signed-off-by: Richard Henderson --- linux-user/syscall.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 0b91f996b7..0641d8f433 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -8125,6 +8125,8 @@ static void open_self_maps_4(const struct open_self_maps_data *d, if (test_stack(start, end, info->stack_limit)) { path = "[stack]"; + } else if (start == info->brk) { + path = "[heap]"; } /* Except null device (MAP_ANON), adjust offset for this fragment. */ -- 2.11.0