How to run those benchmarks on the device?
1. Use $ adb shell to the target device, do the following commands
  # cd /data/local
  # mkdir bzip2
  # mkdir gobmk
  # mkdir hmmer
  # mkdir mcf
  # mkdir sjeng
if you do ls now, you will be able to see five directories under /data/local which are bzip2, gobmk, hmmer, 
mcf and sjeng that you just created.

2. Type # exit to go back to your host machine, do the following commands
  $ tar xvzf spec_benchmarks.tar.gz
  $ cd spec_benchmarks
  $ adb push bzip2/ /data/local/bzip2
  $ adb push gobmk/ /data/local/gobmk
  $ adb push hmmer/ /data/local/hmmer
  $ adb push mcf/ /data/local/mcf
  $ adb push sjeng/ /data/local/sjeng
after these commands succeed, you will be able to find binaries and input files in /data/local/benchmark_directory/, 
in which benchmark_directory can be bzip2, gobmk, hmmer, mcf, sjeng.

3. Go to your device again using adb shell, execute the following commands
  #cd /data/local
  #ls
  bzip2
  gobmk
  hmmer
  mcf
  sjeng
  #cd bzip2
  #chmod 755 bzip2_base.arm-gcc42-05
  #cd ../gobmk
  #chmod 755 gobmk_base.arm-gcc42-05
  #cd ../hmmer
  #chmod 755 hmmer_base.arm-gcc42-05
  #cd ../mcf
  #chmod 755 mcf_base.arm-gcc42-05
  #cd ../sjeng
  #chmod 755 sjeng_base.arm-gcc42-05
These commands will grant execution privilege to those binary files.

Below are the commands that could be used to run the benchmarks, note '.' (no quotes) means your current working 
directory, you should be in bzip2, mcf, gobmk, hmmer, sjeng to be able to run these commands, it is always a good 
habit to perform an 'ls' before you do anything in the current directory. Be sure you can find the binary file 
*.arm-gcc42-05 and the input files. Input files can be dryer.jpg, inp.in, dniwog.tst, bombesin.hmm, test.txt; > 
means you want to redirect your stdout to a file, 2>> means you want to redirect your stderr to a file.
./bzip2_base.arm-gcc42-05 dryer.jpg 2 > dryer.jpg.out 2>> dryer.jpg.err
./mcf_base.arm-gcc42-05 inp.in > inp.out 2>> inp.err
./gobmk_base.arm-gcc42-05 --quiet --mode gtp < dniwog.tst > dniwog.out 2>> dniwog.err
./hmmer_base.arm-gcc42-05 --fixed 0 --mean 325 --num 45000 --sd 200 --seed 0 bombesin.hmm > bombesin.out 2>> bombesin.err
./sjeng_base.arm-gcc42-05 test.txt > test.out 2>> test.err

Although you do not need to use script languages, using shell scripts or bash scripts can greatly improve your speed to 
complete your project. There are several references that you can use.
https://supportweb.cs.bham.ac.uk/documentation/tutorials/docsystem/build/tutorials/unixscripting/unixscripting.html

Please notice that in your target machine, bash is not existing so you can only use the regular shell script (/system/bin/sh), 
so in the first line of your script should be #!/system/bin/sh instead of #!/bin/sh. If you build your script on your host 
machine, however, there won't be less restriction, but you'll need to communicate with your phone through

adb shell <put your command here>

for example, push a binary on to the phone and execute it. The script should look like

$adb push yourBinary /data/local/benchmark_directory
here, benchmark_directory can be bzip2, gobmk, hmmer, mcf, sjeng

$adb shell \'/data/local/benchmark_directory/your_binary input output\'
here, \'\' is single quotes to enclose the entire command you want to execute on your device, the back slash is escaping character

Please use the method that is best for your experiment and describe how you make it in the project report.
