aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_process_dump.c
diff options
context:
space:
mode:
authorRickard Green <[email protected]>2017-01-11 16:53:27 +0100
committerRickard Green <[email protected]>2017-01-11 16:53:27 +0100
commit16da88810cc3dccb0d67b7d1bd97874cadf1bc7b (patch)
tree15a2c98120a7079e91654ef81a747ea9e220e86f /erts/emulator/beam/erl_process_dump.c
parent2d46cd4302119a46b290520b2b679a8a591adb43 (diff)
parent9d029dd04ad1a6a9e9725952b83d7cbdddfca088 (diff)
downloadotp-16da88810cc3dccb0d67b7d1bd97874cadf1bc7b.tar.gz
otp-16da88810cc3dccb0d67b7d1bd97874cadf1bc7b.tar.bz2
otp-16da88810cc3dccb0d67b7d1bd97874cadf1bc7b.zip
Merge branch 'maint'
* maint: Fix issues with abandoned heap Conflicts: erts/emulator/beam/beam_bif_load.c
Diffstat (limited to 'erts/emulator/beam/erl_process_dump.c')
-rw-r--r--erts/emulator/beam/erl_process_dump.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_process_dump.c b/erts/emulator/beam/erl_process_dump.c
index e534c33637..7c23b5c76a 100644
--- a/erts/emulator/beam/erl_process_dump.c
+++ b/erts/emulator/beam/erl_process_dump.c
@@ -90,9 +90,12 @@ Uint erts_process_memory(Process *p, int incl_msg_inq) {
erts_doforall_links(ERTS_P_LINKS(p), &erts_one_link_size, &size);
erts_doforall_monitors(ERTS_P_MONITORS(p), &erts_one_mon_size, &size);
size += (p->heap_sz + p->mbuf_sz) * sizeof(Eterm);
+ if (p->abandoned_heap)
+ size += (p->hend - p->heap) * sizeof(Eterm);
if (p->old_hend && p->old_heap)
size += (p->old_hend - p->old_heap) * sizeof(Eterm);
+
size += p->msg.len * sizeof(ErtsMessage);
for (mp = p->msg.first; mp; mp = mp->next)