The judge machine is apparently a Pentium 3; why not pass -march=pentium3 to gcc's command line? Or at least -mmmx -msse?
What is the added benefit of using these flags?