Step 1: Build a Conventional Application Program DAn application program(dict. c) for the dictionary problem written in C )To produce an executable binary for the application, the programmer invokes the C compiler to produce an executable file named dict Dcc -o dict dict. c
8 Step 1: Build a Conventional Application Program An application program (dict.c) for the dictionary problem written in C To produce an executable binary for the application, the programmer invokes the C compiler to produce an executable file named dict: cc –o dict dict.c
Step 2: Divide the Program into Two Parts DFig 23.2 shows the procedure call graph for the original conventional programs that solves the dictionary problem DA call graph represents a program's procedural organizations D When considering which procedures can be moved to a remote machine the programmer must consider the facilities that each procedure needs
9 Step 2: Divide the Program into Two Parts Fig. 23.2 shows the procedure call graph for the original, conventional programs that solves the dictionary problem A call graph represents a program’s procedural organizations When considering which procedures can be moved to a remote machine, the programmer must consider the facilities that each procedure needs
Step 2: Divide the Program into Two Parts(cont) otherwise access file descriptors cannot be D Procedures that perform 1/0, e.g., nestin moved to a remote machine easil D Procedures should execute on the same machine as the data they access passing large data structures as arguments to remote procedures is inefficient THus, procedures initw, insert, delete and lookup belong on the same machine as the dictionary itself
11 Step 2: Divide the Program into Two Parts (cont.) Procedures that perform I/O, e.g., nextin, or otherwise access file descriptors cannot be moved to a remote machine easily Procedures should execute on the same machine as the data they access; passing large data structures as arguments to remote procedures is inefficient Thus, procedures initw, insertw, deletew, and lookup belong on the same machine as the dictionary itself