Commit 81522a8 1 parent 8ed7c61 commit 81522a8 Copy full SHA for 81522a8
File tree 2 files changed +5
-5
lines changed
2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -425,8 +425,8 @@ include("weakkeydict.jl")
425
425
include (" scopedvalues.jl" )
426
426
427
427
# used by task.jl
428
- const task_times_per_thread = ScopedValues. ScopedValue {Vector{UInt }} ()
429
- const sleep_times_per_thread = ScopedValues. ScopedValue {Vector{UInt }} ()
428
+ const task_times_per_thread = ScopedValues. ScopedValue {Vector{UInt64 }} () # time_ns always returns UInt64
429
+ const sleep_times_per_thread = ScopedValues. ScopedValue {Vector{UInt64 }} ()
430
430
431
431
# metaprogramming
432
432
include (" meta.jl" )
Original file line number Diff line number Diff line change @@ -633,12 +633,12 @@ macro timed(ex)
633
633
Threads. lock_profiling (false ))
634
634
)
635
635
local diff = GC_Diff (gc_num (), stats)
636
- local sched_times = Int []
637
- for i in 1 : Threads . maxthreadid ( )
636
+ local sched_times = Int64 []
637
+ for i in 1 : length (task_times_per_thread[] )
638
638
# filter out zeros in task timers which can only happen if nothing was scheduled
639
639
if task_times_per_thread[][i] != 0
640
640
# subtract task and sleep times from global elapsed time to get scheduling time per thread
641
- push! (sched_times, Int (elapsedtime) - Int (task_times_per_thread[][i]) - Int (sleep_times_per_thread[][i]))
641
+ push! (sched_times, Int64 (elapsedtime) - Int64 (task_times_per_thread[][i]) - Int64 (sleep_times_per_thread[][i]))
642
642
end
643
643
end
644
644
local sched_time_avg = isempty (sched_times) ? 0 : sum (sched_times) / length (sched_times)
You can’t perform that action at this time.
0 commit comments