Guardian Programmer's Guide

Table Of Contents
Communicating With Processes
Guardian Programmer’s Guide 421922-014
6 - 4
Sending Messages to Other Processes
For details about each of the above procedures, refer to the Guardian Procedure Calls
Reference Manual.
Sending Messages to Other Processes
A requester process initiates communication with a server process by sending a
message (a request) to the server. To do so, the requester process typically executes
the following sequence:
1. Open the server process.
2. Create the request in a buffer in the requester’s user data stack or extended data
segment.
3. Send the message to the server, optionally waiting for a reply.
The following paragraphs explain how to do this.
Opening a Process
You open a process by passing the process file name as the file-name parameter to
the FILE_OPEN_ procedure. The process descriptor can be named or unnamed, as
described in Section 2, Using the File System.
Refer to Section 2, Using the File System, for information on how to create a process.
For a thorough discussion of processes, refer to Section
16, Creating and Managing
Processes.
WRITE[X] Sends a message to another process and waits for a
reply (assuming waited I/O). WRITE[X] ignores the
reply data and is often used to send a server request
for which the server does not send any reply data.
The WRITE procedure sends data from a buffer in the
user data segment of the sending process. The
WRITEX procedure sends data from either the user
data segment or an extended data segment of the
sending process.
WRITEREAD[X] Sends a message to another process and waits for a
reply from that process. The WRITEREAD procedure
sends data from a buffer in the user data segment of
the sending process. The WRITEREADX procedure
sends data from either a buffer in the user data
segment or a buffer in an extended data segment of
the sending process.