source: trunk/Jgraph/complex-examples/cll.jgr@ 666

Last change on this file since 666 was 419, checked in by Nicholas Riley, 17 years ago

Jgraph: Debian changes by pzn@…

File size: 2.2 KB
RevLine 
[419]1(* This is a picture of the Concurrent, low-latency checkpointing algorithm. *)
2
3newgraph
4xaxis min 0 max 3 size 2.5 nodraw
5yaxis min 0 max 2.0 size 2.0 nodraw
6
7(* Draw the address space *)
8newstring fontsize 9 hjc vjt x 0.25 y -0.07 : Address\
9Space
10
11newcurve marktype ellipse marksize 0.1 .14 fill 1 pts
12shell : echo "" | awk '{ for (i = 0.67; i < 1.37; i += 0.14) printf("0.5 %f\n", i, i);}'
13
14newcurve marktype box fill 1 marksize 0.5 0.6 pts 0.25 0.3
15newcurve marktype box fill 0.5 marksize 0.5 0.14 pts
16
17
18shell : echo "" | awk '{ for (i = 0.67; i < 1.37; i += 0.14) printf("0.25 %f\n", i);}'
19copycurve fill 1 pts
20shell : echo "" | awk '{ for (i = 1.37; i < 2.00; i += 0.14) printf("0.25 %f\n", i);}'
21
22(* Draw the registers *)
23newline pts 0.0 0.6 0.5 0.6
24shell : echo "0.7 0" | awk -f regs.awk
25newstring hjc vjc fontsize 7 x 1.3 y 0.3 : . . .
26newstring fontsize 9 hjc vjt x 1.05 y -0.07 : CPU\
27States
28
29(* Draw the pool of page buffers *)
30
31newcurve marktype ellipse fill 1 marksize 0.1 0.14 pts
32shell : echo "" | awk '{ for (i = 0.67; i < 1.09; i += 0.14) printf("2.2 %f\n", i);}'
33newcurve marktype box marksize 0.5 0.14 fill 1 pts
34shell : echo "" | awk '{ for (i = 0.67; i < 1.09; i += 0.14) printf("1.95 %f\n", i);}'
35shell : echo "" | awk '{ for (i = 1.51; i < 1.79; i += 0.14) printf("1.95 %f\n", i);}'
36copycurve fill .5 pts
37shell : echo "" | awk '{ for (i = 1.09; i < 1.51; i += 0.14) printf("1.95 %f\n", i);}'
38newstring fontsize 9 hjc vjt x 1.95 y 0.53 : Page\
39Pool
40
41
42(* Draw arrows *)
43newcurve marktype text hjl vjc x 0 y 0 rotate 90 fontsize 7 : . . .
44 pts 0.9 1.35 2.5 1.05
45shell : echo "" | awk '{ for (i = 0.67; i < 1.37; i += 0.14) printf("newline linetype dotted rarrow asize .07 .04 pts 0.55 %f 1.6 %f\n", i, i+.14);}'
46
47newline pts 1.3 0.635 1.22 0.4
48newline pts 1.3 0.635 1.3 0.4
49newline pts 1.3 0.635 1.38 0.4
50newline rarrow asize .07 .04 pts 1.0 0.6 1.3 0.635 1.6 0.67
51
52(* Draw the bezier to disk *)
53
54newline linetype dotted
55shell : echo "" | awk '{ for (i = 0.67; i < 1.09; i += 0.14) printf("copycurve bezier pts 2.25 %f 2.6 %f 2.7 %f 2.7 %f\n", i, i+.1, i, i-.1);}'
56copycurve nobezier rarrow asize .07 .04 pts 2.7 0.85 2.7 0.45
57
58(* Draw the disk *)
59shell : echo "2.5 0.0" | awk -f disk.awk
Note: See TracBrowser for help on using the repository browser.