From cTuning.org

Jump to: navigation, search
Navigation: cTuning.org > CTools > CBench

Each directory has 6 Makefiles for GCC, GCC4CLI, LLVM, Intel compilers, Open64 and PathScale compilers:

  • Makefile.gcc
  • Makefile.open64
  • Makefile.intel
  • Makefile.pathscale
  • Makefile.llvm
  • Makefile.gcc4cli

There are 2 scripts to compile and run program:

  • use __compile batch script with compiler name as the first parameter to compile the benchmark with a specific compiler, i.e. gcc, open64, pathscale or intel. In the second parameter you can specify optimization flags.
  • use __run batch script to execute a benchmark. The first parameter is the dataset number and the second optional parameter is the upper bound of the loop wrapper around the main procedure. If second parameter is omitted, the loop wrapper upper bound is taken from the file _ccc_info_datasets for a given dataset number. CCC_RE environment variable specifies the name of the runtime environment, i.e. VM for GCC4CLI or LLVM or architecture simulator ...

Each directory also has several scripts to automate iterative compilation using Continuous Collective Compilation Framework:

  • _ccc_prep batch script if you need to prepare directory before compiling/running benchmark, i.e. copy some large files once, prepare libraries, etc...
  • _ccc_check_output.clean - removes all output files that will be generated by the benchmark.
  • _ccc_check_output.copy - save original output (when you run program for the first time with the reference compilation.
  • _ccc_check_output.diff - compare all produced output files with the saved ones. Return NULL if files are the same.
  • _ccc_info_datasets - contains info about datasets:
  <first line> - Max number of available datasets
  ===== - separator
  <dataset number>
  <command line>
  <loop wrapper>
  =====
  ...
  • _ccc_program_id - contains unique ID and a benchmark name to be able to share optimization results with the community in the Collective Optimization Database.

Several batch files in the root directory are included as examples to automate iterative optimizations:

  • all__create_work_dirs - creates temporal work directories for each benchmark.
  • all__delete_work_dirs - delete all temporal work directories.
  • all_compile - compile all benchmarks in the temporal work directories.
  • all_run__1_dataset - run all benchmarks with 1 dataset in the temporal work directories.
  • all_run__20_datasets - run all benchmarks with all datasets in the temporal work directories.
Locations of visitors to this page