# Gnuplot script # plot relative timing for 80-bit calculation for different CPUs reset set macros set term png enhanced font arial 10 size 300,400 #set term png enhanced size 700,500 set xlabel "log_{10}N" set key right Left reverse #set xrange [2**20 : 2**35] set xrange [5.6 : 10.8] set yrange [0.:4] #set logscale x # set logscale y set grid #### different processors vs. cluster #set ylabel "Performance relative to cluster" #hosts= "cluster51 cluster42 rut chromebook" hosts= "cluster51 cluster42 rut nuke chromebook" colors="blue green red dark-violet yellow" #hosts= "cluster35 cluster42 nuke rut chromebook corei7" #hosts= "cluster15 cluster23 cluster35 cluster42 nuke rut chromebook" #nproc= "4 8 8 24 2 4 2" #colors="red dark-blue blue green dark-violet grey40 yellow" ##colors="yellow4 brown4 brown dark-violet blue dark-blue green" # reset index of default line styles set for [i=1:words(colors)] linetype i lw 2 lc rgb word(colors, i) # File extentions reflect the options of gfortran used in compilation: # o2: -O2 # o2native: -O2 -march=native dir="./data2/" #ext=".o2" #ext=".o2native" tests="SUM E PI" caps="S E PI" flags=".o2 .o2native" x1=6. do for [k=1:words(flags)] { ext=word(flags, k) do for [j=1:words(tests)] { c=word(caps, j) s="_".word(tests, j).ext do for [h in hosts] { f=h.s system( sprintf("cd %s; paste 80_cluster%s 80_%s > %s.tmp",dir,s,f,f) ) } set output sprintf('cpu_bench%s.png',s) # set title sprintf("Performance relative to cluster in the test %s (single processor)",c) # set title sprintf("Benchmark vs. cluster, Test %s",c) set label 1 sprintf("{/Bold*1.2 Test %s}",c) at x1,3.7 left if(k==1) {set label 2 sprintf("Optimization: -O2") at x1,0.25 left} if(k==2) {set label 2 sprintf("Optimization: -O2 -march=native") at x1,0.25 left} plot for [i=1:words(hosts)] dir.word(hosts,i).s.'.tmp' using (log10($2)):($5/$15) title word(hosts,i) with lp } }