Patent ID: 7839848

Claim:
A message transmission device, comprising: a memory unit; a main control module in a processor, configured to dispatch and control modules in the message transmission device, and to manage the memory unit; a message routing module in the processor, configured to perform routing in accordance with a destination address of a message received and a preconfigured routing table, wherein the destination address comprises an address of a communication node where a destination process resides and a specified port for the destination process; a message receiving and sending module, configured to provide a process with a specified port, receive the message from the specified port or from a network, and send the message in accordance with a routing provided by the message routing module, wherein the message is received through a local queue if the message is from the specified port, and is received through a network queue if the message is from the network; and a flow control module in the processor, configured to be invoked by the main control module to perform a flow control for the message receiving and sending module; wherein the main control module is further configured to allocate the memory unit with an idle event and a variable of the size of required free space for the process; modify the value of the variable of the size of required free space to a message packet when a free space of the memory unit allocated for the process is not enough to accommodate a message; judge whether the sum of available free space plus the size of the message that is taken away is greater than the value of the variable of the size of required free space when the message in the memory unit is taken away: if it is greater, determine that there is an idle event, and a sending of the pending message continues; otherwise continue to wait for occurrence of an idle event.