#!/bin/bash for opt in '-O0' '-O1' '-O2' '-O3' '-O9' '-O1 -march=i686' '-O1 -march=i686 -mcpu=pentium4' \ '-O2 -march=i686' '-O2 -march=i686 -mcpu=pentium4'; do gcc $opt -o test strcpy.c echo "optimizations: $opt" ./test done