/****************************************************************************** * FILE: loop01.c * DESCRIPTION: * Demonstrates loop fusion ******************************************************************************/ #include #include #include #define ARRAY_SIZE 100000 #define SEED 1995 float a[ARRAY_SIZE], b[ARRAY_SIZE], c[ARRAY_SIZE]; float aa[ARRAY_SIZE], bb[ARRAY_SIZE], cc[ARRAY_SIZE]; float x, y, xx, yy; struct timeval start_time, end_time; main() { int i; initialize_data(); /*****************************************************************************/ /* Unfused Loop */ /*****************************************************************************/ gettimeofday(&start_time, (struct timeval*)0); for(i=0;i