-
Notifications
You must be signed in to change notification settings - Fork 406
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
New GC_get_avg_stopped_mark_time_ns API function
Add a public function to get the average time spent in all mark phases with the world stopped. Also, print the value at the end of gctest. * alloc.c [!NO_CLOCK] (world_stopped_total_time, world_stopped_total_divisor, MAX_TOTAL_TIME_DIVISOR): Move definition upper (to be near `GC_get_stopped_mark_total_time`). * alloc.c [!NO_CLOCK] (world_stopped_total_time): Refine comment; add TODO item. * alloc.c [!NO_CLOCK] (GC_get_avg_stopped_mark_time_ns): Implement. * alloc.c [!NO_CLOCK] (GC_stopped_mark): Update value of `world_stopped_total_time` and `world_stopped_total_divisor` also if `measure_performance`. * include/gc/gc.h (GC_start_performance_measurement): Update comment. * include/gc/gc.h (GC_get_avg_stopped_mark_time_ns): New API function declaration. * tests/gctest.c [!NO_CLOCK] (check_heap_stats): Print value of `GC_get_stopped_mark_total_time()` on a separate line; print value of `GC_get_avg_stopped_mark_time_ns()` (divided by 1000).
- Loading branch information
Showing
3 changed files
with
63 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters