Sint erts_queue_messages(Process* receiver, ErtsProcLocks *receiver_locks, ErtsMessage* first, ErtsMessage** last, Uint len) { return queue_messages(NULL, receiver, NULL, receiver_locks, first, last, len); }
void erts_queue_proc_messages(Process* sender, Process* receiver, ErtsProcLocks receiver_locks, ErtsMessage* first, ErtsMessage** last, Uint len) { queue_messages(receiver, receiver_locks, prepend_pending_sig_maybe(sender, receiver, first), last, len); }
static Sint queue_message(Process* receiver, erts_aint32_t *receiver_state, ErtsProcLocks receiver_locks, ErtsMessage* mp, Eterm msg, Eterm from) { ERL_MESSAGE_TERM(mp) = msg; return queue_messages(receiver, receiver_state, receiver_locks, mp, &mp->next, 1, from); }
/** * * @brief Send one message from *NOT* a local process. * * seq_trace does not work with this type of messages * to it is set to am_undefined which means that the * receiving process will not remove the seq_trace token * when it gets this message. * */ void erts_queue_message(Process* receiver, ErtsProcLocks receiver_locks, ErtsMessage* mp, Eterm msg, Eterm from) { ASSERT(is_not_internal_pid(from)); ERL_MESSAGE_TERM(mp) = msg; ERL_MESSAGE_FROM(mp) = from; ERL_MESSAGE_TOKEN(mp) = am_undefined; queue_messages(receiver, receiver_locks, mp, &mp->next, 1); }
/** * @brief Send one message from a local process. * * It is up to the caller of this function to set the * correct seq_trace. The general rule of thumb is that * it should be set to am_undefined if the message * cannot be traced using seq_trace, if it can be * traced it should be set to the trace token. It should * very rarely be explicitly set to NIL! */ void erts_queue_proc_message(Process* sender, Process* receiver, ErtsProcLocks receiver_locks, ErtsMessage* mp, Eterm msg) { ERL_MESSAGE_TERM(mp) = msg; ERL_MESSAGE_FROM(mp) = sender->common.id; queue_messages(receiver, receiver_locks, prepend_pending_sig_maybe(sender, receiver, mp), &mp->next, 1); }