Nature Language: setupBenchmarkList:Subroutine to setup the benchmarkList array with the list of all possible benchmarks.
  
CPP: int setupBenchmarkList(){\n\t/* Pingpong benchmarks */\n\tstrcpy (benchmarkList[0], "masteronlypingpong");\n\tstrcpy (benchmarkList[1], "funnelledpingpong");\n\tstrcpy (benchmarkList[2], "multiplepingpong");\n\t/* Pingping benchmarks */\n\tstrcpy (benchmarkList[3], "masteronlypingping");\n\tstrcpy (benchmarkList[4], "funnelledpingping");\n\tstrcpy (benchmarkList[5], "multiplepingping");\n\t/* Haloexchange benchmarks */\n\tstrcpy (benchmarkList[6], "masteronlyhaloexchange");\n\tstrcpy (benchmarkList[7], "funnelledhaloexchange");\n\tstrcpy (benchmarkList[8], "multiplehaloexchange");\n\t/* Multi-pingpong benchmarks */\n\tstrcpy (benchmarkList[9], "masteronlymultipingpong");\n\tstrcpy (benchmarkList[10], "funnelledmultipingpong");\n\tstrcpy (benchmarkList[11], "multiplemultipingpong");\n\t/* Multi-pingpong benchmarks */\n\tstrcpy (benchmarkList[12], "masteronlymultipingping");\n\tstrcpy (benchmarkList[13], "funnelledmultipingping");\n\tstrcpy (benchmarkList[14], "multiplemultipingping");\n\t/* Collective benchmarks */\n\tstrcpy (benchmarkList[15], "barrier");\n\tstrcpy (benchmarkList[16], "reduce");\n\tstrcpy (benchmarkList[17], "allreduce");\n\tstrcpy (benchmarkList[18], "broadcast");\n\tstrcpy (benchmarkList[19], "scatter");\n\tstrcpy (benchmarkList[20], "gather");\n\tstrcpy (benchmarkList[21], "alltoall");\n\treturn 0;\n }
  
Fortran: SUBROUTINE readBenchmarkParams()\n\n\t!Rank 0 reads parameters from input file\n\tIF (myMPIRank == 0) THEN\n\t write (,) 'Reading parameters from input file....'\n\t !read minimum data size from input file\n\t read(10,) minDataSize \n\t !read maximum data size from input file\n\t read(10,) maxDataSize\n\t !read target time from input file\n\t read(10,) targetTime\n\n\t !set other benchmark parameters\n\t warmUpIters = 2\n\t defaultReps = 1000\n \n\t !Report benchmark parameters\n\t write(,fmt='(A)') '------------------------------------------'\n\t write(,fmt='(A)') ' Benchmark parameters '\n\t write(,fmt='(A)') '------------------------------------------'\n\t write(,fmt='(A,t25,i10)') 'Minimum data size', minDataSize\n\t write(,fmt='(A,t25,i10)') 'Maximum data size', maxDataSize\n\t write(,fmt='(A,t25,f10.2)') 'Target time (sec)', targetTime\n\t write(,fmt='(A,t25,i10)') 'Default Repetitions', defaultReps\n\t write(*,fmt='(A,t25,i10)') 'No. Warmup iterations', warmUpIters\n\n\tEND IF\n\t!Initialise benchmarkNumber to 0 so that the\n\t!DO WHILE loop in the driver is entered the first time\n\tbenchmarkNumber = 0\n\n\t!Broadcast benchmark parameters from master to all \n\t!other MPI processes.\n\tCALL MPI_Bcast(minDataSize, 1, MPI_INTEGER, 0, comm, ierr)\n\tCALL MPI_Bcast(maxDataSize, 1, MPI_INTEGER, 0, comm, ierr)\n\tCALL MPI_Bcast(targetTime, 1, MPI_DOUBLE_PRECISION, 0, comm, ierr)\n\tCALL MPI_Bcast(defaultReps, 1, MPI_INTEGER, 0, comm, ierr)\n\tCALL MPI_Bcast(warmUpIters, 1, MPI_INTEGER, 0, comm, ierr)\n\nEND SUBROUTINE readBenchmarkParams
  