anchor.diff:    %% XXX:  - transfer ets ownership and send message or delete table
     %% XXX:  - send link signals
     %% XXX:  - send monitor messages
  +  ?debug_flag(?loop, {going_to_exit, Reason}),
     Info = process_loop(InfoIn),
  -  ?debug_flag(?exit, {going_to_exit, Reason}),
     Self = self(),
     {MaybeName, Info} =
       run_built_in(erlang, process_info, 2, [Self, registered_name], Info),
  
positive.code:   end.
  
  process_loop(#concuerror_info{notify_when_ready = {Pid, true}} = Info) ->
    ?debug_flag(?wait, notifying_parent),
    Pid ! ready,
    process_loop(Info#concuerror_info{notify_when_ready = {Pid, false}});
  process_loop(Info) ->
    ?debug_flag(?wait, waiting),
    receive
      #event{event_info = EventInfo} = Event ->
        Status = Info#concuerror_info.status,
        case Status =:= exited of
          true ->
            process_loop(notify(exited, Info));
          false ->
            NewInfo = Info#concuerror_info{next_event = Event},
            case EventInfo of
              undefined ->
                ?debug_flag(?wait, {waiting, exploring}),
                NewInfo;
              _OtherReplay ->
                ?debug_flag(?wait, {waiting, replaying}),
                NewInfo
            end
        end;
      {exit_signal, #message{data = {'EXIT', _From, Reason}} = Message, Notify} ->
        Trapping = Info#concuerror_info.flags#process_flags.trap_exit,
        case is_active(Info) of
          true ->
            case Reason =:= kill of
              true ->
                ?debug_flag(?wait, {waiting, kill_signal}),
                catch Notify ! {trapping, Trapping},
                exiting(killed, [], Info#concuerror_info{caught_signal = true});
              false ->
                case Trapping of
                  true ->
                    ?debug_flag(?trap, {waiting, signal_trapped}),
                    self() ! {message, Message, Notify},
                    process_loop(Info);
                  false ->
                    catch Notify ! {trapping, Trapping},
                    case Reason =:= normal of
                      true ->
                        ?debug_flag(?wait, {waiting, normal_signal_ignored}),
                        process_loop(Info);
                      false ->
                        ?debug_flag(?wait, {waiting, exiting_signal}),
                        exiting(Reason, [], Info#concuerror_info{caught_signal = true})
                    end
                end
            end;
          false ->
            catch Notify ! {trapping, Trapping},
            process_loop(Info)
        end;
      {message, Message, Notify} ->
        ?debug_flag(?wait, {waiting, got_message}),
        Trapping = Info#concuerror_info.flags#process_flags.trap_exit,
        catch Notify ! {trapping, Trapping},
        case is_active(Info) of
          true ->
            ?debug_flag(?receive_, {message_enqueued, Message}),
            Old = Info#concuerror_info.messages_new,
            NewInfo =
              Info#concuerror_info{
                messages_new = queue:in(Message, Old)
               },
            case NewInfo#concuerror_info.status =:= waiting of
              true -> NewInfo#concuerror_info{status = running};
              false -> process_loop(NewInfo)
            end;
          false ->
            ?debug_flag(?receive_, {message_ignored, Info#concuerror_info.status}),
            process_loop(Info)
        end;
      reset ->
        ?debug_flag(?wait, {waiting, reset}),
        NewInfo =
          #concuerror_info{
             ets_tables = EtsTables,
  
negative.code: %%------------------------------------------------------------------------------
  
  notify(Notification, #concuerror_info{scheduler = Scheduler} = Info) ->
    ?debug_flag(?notify, {notify, Notification}),
    Scheduler ! Notification,
    Info.
  
  -spec process_top_loop(concuerror_info()) -> no_return().
  
  process_top_loop(Info) ->
    ?debug_flag(?loop, top_waiting),
    receive
      reset -> process_top_loop(Info);
      {start, Module, Name, Args} ->
        ?debug_flag(?loop, {start, Module, Name, Args}),
        put(concuerror_info, Info),
        try
          concuerror_inspect:instrumented(call, [Module,Name,Args], start),
  