[ruby-cvs:67963] ko1:r60782 (trunk): cleanup hook cleanup code.

ko1 at ruby-lang.org ko1 at ruby-lang.org
Thu Nov 16 11:47:58 JST 2017

ko1	2017-11-16 11:47:58 +0900 (Thu, 16 Nov 2017)

  New Revision: 60782


    cleanup hook cleanup code.
    * vm_trace.c: before this patch, deleted hooks are remvoed at
      *the beggining* of hooks (exec_hooks_precheck).
      This patch cleanup deleted hooks at
      (1) just after hook is deleted (TracePoint#disable and so on)
      (2) just after executing hooks (exec_hooks_postcheck)
      Most of time (1) is enough, but if some threads running hooks,
      we need to wait cleaning up deleted hooks until threads finish
      running the hooks. This is why (2) is introduced (and this is
      why current impl cleanup deleted hooks at the beggining of hooks).
    * test/lib/tracepointchecker.rb: check also the number of delete
      waiting hooks.
    * cont.c (cont_restore_thread): fix VM->trace_running count.

  Modified files:

More information about the ruby-cvs mailing list