#! /bin/bash ./trex-cfg $@ RESULT=$? if [ $RESULT -ne 0 ]; then exit $RESULT fi cd $(dirname $0) export LD_LIBRARY_PATH=$PWD saveterm="$(stty -g)" # if we have a new core run optimized trex if cat /proc/cpuinfo | grep -q avx ; then ./_$(basename $0) $@ if [ $? -eq 132 ]; then echo " WARNING this program is optimized for the new Intel processors. " echo " try the ./t-rex-64-o application that should work for any Intel processor but might be slower. " echo " try to run t-rex-64-o .. " ./_t-rex-64-o $@ fi else ./_t-rex-64-o $@ fi stty $saveterm