#! /bin/bash

micexe="magma_mic_server"
#libfile="/mnt/scratch/sw/intel/composerxe_mic.0.022/compiler/lib/mic/libiomp5.so"
libfile="/mnt/scratch/sw/intel/composer_xe_2013.0.027/compiler/lib/mic/libiomp5.so"
miclib="/lib64/libiomp5.so"

if [ ! -e "$micexe" ]
then
        echo "Need \"magma_mic_server\""
        exit
fi

micput 192.168.1.100 $micexe .
micput 192.168.1.100  $libfile $miclib

miccmd 192.168.1.100 export KMP_AFFINITY=compact
#miccmd 192.168.1.100 echo 500 > /proc/sys/vm/nr_hugepages
miccmd 192.168.1.100 ./$micexe 

