/* Test program: measures te cost of AA operations */ /****************************************************************************/ /* (C) Copyright 1993 Universidade Estadual de Campinas (UNICAMP) */ /* Campinas, SP, Brazil */ /* */ /* This file can be freely distributed, modified, and used for any */ /* non-commercial purpose, provided that this copyright and authorship */ /* notice be included in any copy or derived version of this file. */ /* */ /* DISCLAIMER: This software is offered ``as is'', without any guarantee */ /* as to fitness for any particular purpose. Neither the copyright */ /* holder nor the authors or their employers can be held responsible for */ /* any damages that may result from its use. */ /****************************************************************************/ #include #include #include #include #include #include #include int ieee_flags(char *a, char *b, char *c, char **out); int main (void); int do_empty(int ntimes); int do_aa_add(int ntimes); int do_aa_mul(int ntimes); #define NTIMES 10000 #define NEPS 10 int main (void) { aa_init(); time_func("empty loop", do_empty, NTIMES); time_func("aa_add", do_aa_add, NTIMES); time_func("aa_mul", do_aa_mul, NTIMES); return(0); } int do_empty(int ntimes) { int i; for (i=0; i