BEGIN           {
		    nplanes = "?";
		    width = "?";
		    height = "?";
		    vendor = "?";
		    vsn = "?";
		    server = "?";
		    client = "?";
		    com = "?";
		    s = "?";
		    note = "";

		    value["line10"] = "?";
		    value["line100"] = "?";
		    value["line400"] = "?";
		    value["dline10"] = "?";
		    value["dline100"] = "?";
		    value["dline400"] = "?";
		    value["wline10"] = "?";
		    value["wline100"] = "?";
		    value["wline400"] = "?";
		    value["rects10"] = "?";
		    value["rects100"] = "?";
		    value["rects400"] = "?";
		    value["fillrects10"] = "?";
		    value["fillrects100"] = "?";
		    value["fillrects400"] = "?";
		    value["tiledrects10"] = "?";
		    value["tiledrects100"] = "?";
		    value["tiledrects400"] = "?";
		    value["stippledrects10"] = "?";
		    value["stippledrects100"] = "?";
		    value["stippledrects400"] = "?";
		    value["arcs10"] = "?";
		    value["arcs100"] = "?";
		    value["arcs400"] = "?";
		    value["filledarcs10"] = "?";
		    value["filledarcs100"] = "?";
		    value["filledarcs400"] = "?";
		    value["filledpoly100"] = "?";
		    value["invrects10"] = "?";
		    value["invrects100"] = "?";
		    value["invrects400"] = "?";
		    value["screencopy10"] = "?";
		    value["screencopy100"] = "?";
		    value["screencopy400"] = "?";
		    value["scroll"] = "?";
		    value["bitmapcopy10"] = "?";
		    value["bitmapcopy100"] = "?";
		    value["bitmapcopy400"] = "?";
		    value["string"] = "?";
		    value["complex1"] = "?";
		}

/server:/       {
		    server = $2
		    if ( $3 != "") {
		      server = server " " $3
		    }
		    if ( $4 != "") {
		      server = server " " $4
		    }
		    if ( $5 != "") {
		      server = server " " $5
		    }
		    if ( $6 != "") {
		      server = server " " $6
		    }
		    if ( $7 != "") {
		      server = server " " $7
		    }
		    if ( $8 != "") {
		      server = server " " $8
		    }
		    if ( $9 != "") {
		      server = server " " $9
		    }
		}

/client:/       {
		    client = $2
		    if ( $3 != "") {
		      client = client " " $3
		    }
		    if ( $4 != "") {
		      client = client " " $4
		    }
		    if ( $5 != "") {
		      client = client " " $5
		    }
		    if ( $6 != "") {
		      client = client " " $6
		    }
		    if ( $7 != "") {
		      client = client " " $7
		    }
		    if ( $8 != "") {
		      client = client " " $8
		    }
		    if ( $9 != "") {
		      client = client " " $9
		    }
		}

/communication:/{
		    com = $2
		    if ( $3 != "") {
		      com = com " " $3
		    }
		    if ( $4 != "") {
		      com = com " " $4
		    }
		    if ( $5 != "") {
		      com = com " " $5
		    }
		    if ( $6 != "") {
		      com = com " " $6
		    }
		    if ( $7 != "") {
		      com = com " " $7
		    }
		    if ( $8 != "") {
		      com = com " " $8
		    }
		    if ( $9 != "") {
		      com = com " " $9
		    }
		}

/notes:/        {
		    note = $2
		    if ( $3 != "") {
		      note = note " " $3
		    }
		    if ( $4 != "") {
		      note = note " " $4
		    }
		    if ( $5 != "") {
		      note = note " " $5
		    }
		    if ( $6 != "") {
		      note = note " " $6
		    }
		    if ( $7 != "") {
		      note = note " " $7
		    }
		    if ( $8 != "") {
		      note = note " " $8
		    }
		    if ( $9 != "") {
		      note = note " " $9
		    }
		}

/Servervendor / {
		    vendor = $3;
		    if ( $4 != "") {
		      vendor = vendor " " $4
		    }
		    if ( $5 != "") {
		      vendor = vendor " " $5
		    }
		    if ( $6 != "") {
		      vendor = vendor " " $6
		    }
		    if ( $7 != "") {
		      vendor = vendor " " $7
		    }
		    if ( $8 != "") {
		      vendor = vendor " " $8
		    }
		    if ( $9 != "") {
		      vendor = vendor " " $9
		    }
		}
/version /      {
		    vsn = $4;
		    if ( $5 != "") {
		      vsn = vsn " " $5
		    }
		    if ( $6 != "") {
		      vsn = vsn " " $6
		    }
		    if ( $7 != "") {
		      vsn = vsn " " $7
		    }
		}
/Defaultdepth / { nplanes = $4 }
/DisplayWidth /  { width = $3 }
/DisplayHeight / { height = $3 }

/ line10 /           { x = "line10";             }
/ line100 /          { x = "line100";            }
/ line400 /          { x = "line400";            }
/ dline10 /          { x = "dline10";            }
/ dline100 /         { x = "dline100";           }
/ dline400 /         { x = "dline400";           }
/ wline10 /          { x = "wline10";            }
/ wline100 /         { x = "wline100";           }
/ wline400 /         { x = "wline400";           }
/ rects10 /          { x = "rects10";            }
/ rects100 /         { x = "rects100";           }
/ rects400 /         { x = "rects400";           }
/ fillrects10 /      { x = "fillrects10";        }
/ fillrects100 /     { x = "fillrects100";        }
/ fillrects400 /     { x = "fillrects400";        }
/ tiledrects10 /     { x = "tiledrects10";        }
/ tiledrects100 /    { x = "tiledrects100";       }
/ tiledrects400 /    { x = "tiledrects400";       }
/ stippledrects10 /  { x = "stippledrects10";     }
/ stippledrects100 / { x = "stippledrects100";    }
/ stippledrects400 / { x = "stippledrects400";    }
/ arcs10 /           { x = "arcs10";             }
/ arcs100 /          { x = "arcs100";            }
/ arcs400 /          { x = "arcs400";            }
/ filledarcs10 /     { x = "filledarcs10";       }
/ filledarcs100 /    { x = "filledarcs100";      }
/ filledarcs400 /    { x = "filledarcs400";      }
/ filledpoly100 /    { x = "filledpoly100";      }
/ invrects10 /       { x = "invrects10";         }
/ invrects100 /      { x = "invrects100";        }
/ invrects400 /      { x = "invrects400";        }
/ screencopy10 /     { x = "screencopy10";       }
/ screencopy100 /    { x = "screencopy100";      }
/ screencopy400 /    { x = "screencopy400";      }
/ scroll /           { x = "scroll";             }
/ bitmapcopy10 /     { x = "bitmapcopy10";       }
/ bitmapcopy100 /    { x = "bitmapcopy100";      }
/ bitmapcopy400 /    { x = "bitmapcopy400";      }
/ imagestring/       { x = "string";             }
/ complex1 /         { x = "complex1";           }

/rate =/             {
		       value[x] = $3;
		       x = "dummy"; w = 1
		     }

/NOT RUN/            {
		       x = "dummy"; w = 1
		     }

END                  {
		       print ".bp"
		       print ".NH"
		       print server
		       print ".LP"
		       print ".nf"
		       print "Vendor:  " vendor                           ;
		       print "Release: " vsn                              ;
		       print "Display: " width " x " height " x " nplanes ;
		       print " "                             ;
		       print "Notes  : " note            ;
		       print " "                             ;
		       print "Connection for test: " com ;
		       print "Machine on the other side: " client;
		       print " "   ;
		       print ".fi" ;
		       print ".sp" ;
		       print ".TS" ;
		       print ".box, tab(!);"    ;
		       print "l | c | c | c | c | r"
		       print "l | r | r | r | r | r."
		       print "test!10!100!400!!"
		       print "="
		       print "lines!" value["line10"] "!" value["line100"] "!" value["line400"] "!!lines/sec"
		       print "_"
		       print "dashed lines!" value["dline10"] "!" value["dline100"] "!" value["dline400"] "!!lines/sec"
		       print "_"
		       print "wide lines!" value["wline10"] "!" value["wline100"] "!" value["wline400"] "!!lines/sec"
		       print "_"
		       print "rectangles !" value["rects10"] "!" value["rects100"] "!" value["rects400"] "!!rectangles/sec"
		       print "="
		       print "filled rectangles !" value["fillrects10"] "!" value["fillrects100"] "!" value["fillrects400"] "!!rectangles/sec"
		       print "_"
		       print "tiled rectangles !" value["tiledrects10"] "!" value["tiledrects100"] "!" value["tiledrects400"] "!!rectangles/sec"
		       print "_"
		       print "stippled rectangles !" value["stippledrects10"] "!" value["stippledrects100"] "!" value["stippledrects400"] "!!rectangles/sec"
		       print "="
		       print "arcs!" value["arcs10"] "!" value["arcs100"] "!" value["arcs400"] "!!arcs/sec"
		       print "_"
		       print "filled arcs!" value["filledarcs10"] "!" value["filledarcs100"] "!" value["filledarcs400"] "!!arcs/sec"
		       print "="
		       print "filled polygon!" " " "!" value["filledpoly100"] "!" " " "!!fills/sec"
		       print "="
		       print "screen copy!" value["screencopy10"] "!" value["screencopy100"] "!" value["screencopy400"] "!!copies/sec"
		       print "_"
		       print "scrolls!" " ! ! !" value["scroll"] "!scrolls/sec"
		       print "_"
		       print "bitmap copy!" value["bitmapcopy10"] "!" value["bitmapcopy100"] "!" value["bitmapcopy400"] "!!copies/sec"
		       print "_"
		       print "invert rectangles !" value["invrects10"] "!" value["invrects100"] "!" value["invrects400"] "!!rectangles/sec"
		       print "="
		       print "text !" " ! ! !" value["string"] "!chars/sec"
		       print "="
		       print "complex!" " ! ! !" value["complex1"] "!runs/sec"
		       print "="
		       print ".TE"
		       print ".LP"
		     }
