| #takes a test and a program from a dp and produces a gnuplot script |
| #use like perl plotNLT.pl password Programs/MultiSource/Benchmarks/ASCI_Purple/SMG2000/smg2000 llc |
| $connectionInfo="dbi:mysql:$db;$host"; |
| # make connection to database |
| $dbh = DBI->connect($connectionInfo,$userid,$passwd) or die DBI->errstr; |
| print "set xdata time\n"; |
| print 'set timefmt "%Y-%m-%d"'; |
| for ($iter = 0; $iter < $count; $iter++) { |
| print " '-' using 1:2 with lines"; |
| for ($iter = 0; $iter < $count; $iter++) { |
| $query = "Select RUN, VALUE from Tests where TEST = '$test' AND NAME = '$prog' ORDER BY RUN"; |
| my $sth = $dbh->prepare( $query) || die "Can't prepare statement: $DBI::errstr";; |
| my $rc = $sth->execute or die DBI->errstr; |
| while(($da,$v) = $sth->fetchrow_array) |
| # disconnect from database |