26 #ifndef THREAD_MESSAGE_H_
27 #define THREAD_MESSAGE_H_
80 unsigned int target_id,
struct thread_msg * init_send_thread_msg(unsigned int runtime_id, unsigned int target_id, size_t data_len, void *data)
Initializes a send_to_peer message (SEND_TO_PEER)
struct rt_controller_msg_hdr hdr
Kept unknown at 0 to catch mis-labeled messages.
ctrl_delete_msu_msg (ctrl_runtime_messages.h)
void destroy_thread_msg(struct thread_msg *msg)
Frees a thread message.
Socket-handling between runtimes.
thread_msg_type
All messages that can be received by output thread or workers.
For delivery to the output monitor thread, a message to be sent to a peer runtime.
Header for messages to runtime from another runtime.
int enqueue_thread_msg(struct thread_msg *msg, struct msg_queue *queue)
Enqueues a dedos_msg with a thread_msg as the payload to the appropriate queue.
Container for linked list message queue.
enum thread_msg_type type
Header for all messages from controller to runtime.
payload: send_to_ctrl_msg (below)
For delivery to output monitor thread, a message to be sent to the controller.
A message to be delivered to a dedos_thread.
struct inter_runtime_msg_hdr hdr
Definitions of the message types that can be passed between runtimes.
struct thread_msg * construct_thread_msg(enum thread_msg_type type, ssize_t data_size, void *data)
Allocates and initializes a thread message with the provided options.
ctrl_create_msu_msg (ctrl_runtime_messages.h)
Definitiions of structures for sending messages from runtimes to controller.
struct thread_msg * dequeue_thread_msg(struct msg_queue *queue)
Dequeues a thread_msg from the message queue.
ctrl_msu_route_msg (ctrl_runtime_messages.h)
int ack_id
for sending acknowledgements to controller.
static int runtime_id(int runtime_fd)
payload: send_to_runtime_msg (below)
payload: ctrl_add_runtime_msg (ctrl_runtime_messages.h)
unsigned int runtime_id
The runtime ID to which the message is delivered.