diff options
author | Rickard Green <[email protected]> | 2017-05-10 16:53:49 +0200 |
---|---|---|
committer | Rickard Green <[email protected]> | 2017-05-10 16:53:49 +0200 |
commit | 1c5832cbfb8a965c8de9ca072361f3661cdfaea2 (patch) | |
tree | f09b8d72062670183a47453a377e9d2808641549 /erts/preloaded/src/erlang.erl | |
parent | d646221c59fbf57d5beac913248b46f5dbebfbe7 (diff) | |
parent | 89098ea8beb9e60faa59c3f2ea9ffc918ef87ae8 (diff) | |
download | otp-1c5832cbfb8a965c8de9ca072361f3661cdfaea2.tar.gz otp-1c5832cbfb8a965c8de9ca072361f3661cdfaea2.tar.bz2 otp-1c5832cbfb8a965c8de9ca072361f3661cdfaea2.zip |
Merge branch 'rickard/rq-len/OTP-13201'
* rickard/rq-len/OTP-13201:
Fix testcase
Light weight statistics of run queue lengths
Diffstat (limited to 'erts/preloaded/src/erlang.erl')
-rw-r--r-- | erts/preloaded/src/erlang.erl | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/erts/preloaded/src/erlang.erl b/erts/preloaded/src/erlang.erl index 7280b43502..5fc6d14938 100644 --- a/erts/preloaded/src/erlang.erl +++ b/erts/preloaded/src/erlang.erl @@ -2205,7 +2205,9 @@ setelement(_Index, _Tuple1, _Value) -> spawn_opt(_Tuple) -> erlang:nif_error(undefined). --spec statistics(context_switches) -> {ContextSwitches,0} when +-spec statistics(active_tasks) -> [ActiveTasks] when + ActiveTasks :: non_neg_integer(); + (context_switches) -> {ContextSwitches,0} when ContextSwitches :: non_neg_integer(); (exact_reductions) -> {Total_Exact_Reductions, Exact_Reductions_Since_Last_Call} when @@ -2222,6 +2224,8 @@ spawn_opt(_Tuple) -> Total_Reductions :: non_neg_integer(), Reductions_Since_Last_Call :: non_neg_integer(); (run_queue) -> non_neg_integer(); + (run_queue_lengths) -> [RunQueueLenght] when + RunQueueLenght :: non_neg_integer(); (runtime) -> {Total_Run_Time, Time_Since_Last_Call} when Total_Run_Time :: non_neg_integer(), Time_Since_Last_Call :: non_neg_integer(); @@ -2229,6 +2233,10 @@ spawn_opt(_Tuple) -> SchedulerId :: pos_integer(), ActiveTime :: non_neg_integer(), TotalTime :: non_neg_integer(); + (total_active_tasks) -> ActiveTasks when + ActiveTasks :: non_neg_integer(); + (total_run_queue_lengths) -> TotalRunQueueLenghts when + TotalRunQueueLenghts :: non_neg_integer(); (wall_clock) -> {Total_Wallclock_Time, Wallclock_Time_Since_Last_Call} when Total_Wallclock_Time :: non_neg_integer(), |