=================================================================== RCS file: /home/cvs/OpenXM/doc/ascm2001p/openxm-stackmachines.tex,v retrieving revision 1.1 retrieving revision 1.4 diff -u -p -r1.1 -r1.4 --- OpenXM/doc/ascm2001p/openxm-stackmachines.tex 2001/06/19 07:32:58 1.1 +++ OpenXM/doc/ascm2001p/openxm-stackmachines.tex 2001/06/21 03:09:46 1.4 @@ -1,8 +1,8 @@ -% $OpenXM$ +% $OpenXM: OpenXM/doc/ascm2001p/openxm-stackmachines.tex,v 1.3 2001/06/21 00:15:34 takayama Exp $ \section{OpenXM Stack machines}\label{sec:ox-stackmachines} -In OpenXM specification, all servers are stack machines. +In the OpenXM specification, all servers are stack machines. %These are called OpenXM stack machines. When a server ox\_xyz gets an OX data message, it translates the data into a local object of ox\_xyz @@ -19,13 +19,13 @@ Here, {\tt OX\_DATA} stands for {\tt OX\_DATA} header and {\tt (CMO\_ZZ,1)} is a body standing for $1$ expressed by the CMO. -The server translates {\tt (CMO\_ZZ, 1)} to its internal object of +The server translates {\tt (CMO\_ZZ,1)} to its internal object for the integer $1$ and pushes the object onto the stack. If the server gets an {\it OX command} message, then the server executes the command. -Any OX command message starts with the int32 tag OX\_COMMAND. +Any OX command message starts with the int32 tag {\tt OX\_COMMAND}. The body is a stack machine operation code expressed by int32. %The codes are listed below \cite{ox-rfc-100}. %\begin{verbatim} @@ -64,7 +64,7 @@ is pushed as a string. Finally, the stack machine command {\tt SM\_executeFunction} evaluates the operator and pushes the result onto the stack -after poping the operator name, the number of arguments +after popping the operator name, the number of arguments, and arguments. %For example, the following code factorizes $x^{100}-1$ by calling %{\tt ox\_asir} from Asir. @@ -87,8 +87,9 @@ instead of a result of the computation. %error([8,fctr : invalid argument]) %\end{verbatim} -OpenXM server won't send error messages to the client -except when it receives a {\tt SM\_pop*} command. +OpenXM server does not send error messages to the client +except when it receives a {\tt SM\_pop*} command, +which is a request to pop data from the stack and to write it to the client. OX stack machines work in the asynchronous mode which is similar to X servers. %For servers of graphic and sound applications,