aboutsummaryrefslogtreecommitdiffstats
path: root/erts/etc
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2018-04-12 14:00:58 +0200
committerLukas Larsson <[email protected]>2018-04-12 14:00:58 +0200
commit7d6a44f848565bba425303faea5cb4e30f286a42 (patch)
treea5c176c252f5166559eb2ae6435b815d55aabb64 /erts/etc
parent0f4e092e58929a9a517eb17653f4ec217f2a9132 (diff)
parentbc53f111f172dd98f82a10706f146cb824ebb9f6 (diff)
downloadotp-7d6a44f848565bba425303faea5cb4e30f286a42.tar.gz
otp-7d6a44f848565bba425303faea5cb4e30f286a42.tar.bz2
otp-7d6a44f848565bba425303faea5cb4e30f286a42.zip
Merge branch 'lukas/erts/fix_openbsd_eof_poll/OTP-14346'
* lukas/erts/fix_openbsd_eof_poll/OTP-14346: erts: Break etp-processes/ports when all found erts: Don't use EV_DISPATCH on openbsd
Diffstat (limited to 'erts/etc')
-rw-r--r--erts/etc/unix/etp-commands.in10
1 files changed, 7 insertions, 3 deletions
diff --git a/erts/etc/unix/etp-commands.in b/erts/etc/unix/etp-commands.in
index bac90cb472..e5ef819444 100644
--- a/erts/etc/unix/etp-commands.in
+++ b/erts/etc/unix/etp-commands.in
@@ -1997,7 +1997,7 @@ define etp-process-info
printf " Msgq len: %d\n", $etp_proc->sig_qs.len
end
printf " Parent: "
- etp-1 $etp_proc->parent
+ etp-1 ((Eterm)($etp_proc->parent))
printf "\n Pointer: (Process *) %p\n", $etp_proc
end
end
@@ -2017,15 +2017,17 @@ define etp-processes
set $proc_ix = 0
set $proc_max_ix = erts_proc.r.o.max
set $proc_tab = erts_proc.r.o.tab
+ set $proc_cnt = erts_proc.vola.tile.count.counter
set $invalid_proc = &erts_invalid_process
set $proc_decentile = $proc_max_ix / 10
set $proc_printile = $proc_decentile
- while $proc_ix < $proc_max_ix
+ while $proc_ix < $proc_max_ix && $proc_cnt > 0
set $proc = (Process *) *((UWord *) ($proc_tab + $proc_ix))
if ($proc != ((Process *) 0) && $proc != $invalid_proc)
printf "---\n"
printf " Pix: %d\n", $proc_ix
etp-process-info $proc
+ set $proc_cnt--
end
if $proc_ix == $proc_printile
printf "--- %d%% (%d / %d) searched\n", $proc_printile / $proc_decentile * 10, $proc_ix, $proc_max_ix
@@ -2363,10 +2365,11 @@ define etp-ports
set $port_ix = 0
set $port_max_ix = erts_port.r.o.max
set $port_tab = erts_port.r.o.tab
+ set $port_cnt = erts_proc.vola.tile.count.counter
set $invalid_port = &erts_invalid_port
set $port_decentile = $port_max_ix / 10
set $port_printile = $port_decentile
- while $port_ix < $port_max_ix
+ while $port_ix < $port_max_ix && $port_cnt > 0
set $port = (Port *) *((UWord *) ($port_tab + $port_ix))
if ($port != ((Port *) 0) && $port != $invalid_port)
if (*(((Uint32 *) &(((Port *) $port)->state))) & 0x100) == 0
@@ -2374,6 +2377,7 @@ define etp-ports
printf "---\n"
printf " Pix: %d\n", $port_ix
etp-port-info $port
+ set $port_cnt--
end
end
if $port_ix == $port_printile