mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
Add debug counter for MJIT stale_units
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67546 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
f7035dd3ff
commit
18b5148215
3 changed files with 4 additions and 0 deletions
|
@ -51,6 +51,7 @@ rb_debug_counter_reset(void)
|
|||
case RB_DEBUG_COUNTER_mjit_length_unit_queue:
|
||||
case RB_DEBUG_COUNTER_mjit_length_active_units:
|
||||
case RB_DEBUG_COUNTER_mjit_length_compact_units:
|
||||
case RB_DEBUG_COUNTER_mjit_length_stale_units:
|
||||
// These counters may be decreased and should not be reset.
|
||||
break;
|
||||
default:
|
||||
|
|
|
@ -280,6 +280,7 @@ RB_DEBUG_COUNTER(mjit_cancel_trace)
|
|||
RB_DEBUG_COUNTER(mjit_length_unit_queue)
|
||||
RB_DEBUG_COUNTER(mjit_length_active_units)
|
||||
RB_DEBUG_COUNTER(mjit_length_compact_units)
|
||||
RB_DEBUG_COUNTER(mjit_length_stale_units)
|
||||
|
||||
/* Other MJIT counters */
|
||||
RB_DEBUG_COUNTER(mjit_compile_failures)
|
||||
|
|
|
@ -334,6 +334,7 @@ add_to_list(struct rb_mjit_unit *unit, struct rb_mjit_unit_list *list)
|
|||
(void)RB_DEBUG_COUNTER_INC_IF(mjit_length_unit_queue, list == &unit_queue);
|
||||
(void)RB_DEBUG_COUNTER_INC_IF(mjit_length_active_units, list == &active_units);
|
||||
(void)RB_DEBUG_COUNTER_INC_IF(mjit_length_compact_units, list == &compact_units);
|
||||
(void)RB_DEBUG_COUNTER_INC_IF(mjit_length_stale_units, list == &stale_units);
|
||||
|
||||
list_add_tail(&list->head, &unit->unode);
|
||||
list->length++;
|
||||
|
@ -346,6 +347,7 @@ remove_from_list(struct rb_mjit_unit *unit, struct rb_mjit_unit_list *list)
|
|||
rb_debug_counter_add(RB_DEBUG_COUNTER_mjit_length_unit_queue, -1, list == &unit_queue);
|
||||
rb_debug_counter_add(RB_DEBUG_COUNTER_mjit_length_active_units, -1, list == &active_units);
|
||||
rb_debug_counter_add(RB_DEBUG_COUNTER_mjit_length_compact_units, -1, list == &compact_units);
|
||||
rb_debug_counter_add(RB_DEBUG_COUNTER_mjit_length_stale_units, -1, list == &stale_units);
|
||||
#endif
|
||||
|
||||
list_del(&unit->unode);
|
||||
|
|
Loading…
Reference in a new issue