This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Benchmark suite...
- To: crosby at qwes dot math dot cmu dot edu
- Subject: Re: Benchmark suite...
- From: Joern Rennecke <amylaar at cygnus dot co dot uk>
- Date: Thu, 5 Nov 1998 07:31:22 +0000 (GMT)
- Cc: hubicka at atrey dot karlin dot mff dot cuni dot cz, egcs at cygnus dot com
> Another micro-benchmark to measure how well the compiler performs register
> assignment:
>
> // Test register assignment, passing reg_assignXX an array of XX values.
> reg_assign1_8(int *a, int *b)
> b[0] = 1*a[1] + 2*a[2] + 3*a[3] + 4*a[4] .... 7*a[7];
> b[1] = 0*a[0] + 1*a[2] + 2*a[3] .... 6*a[7];
> ..
> ..
> b[7] = 0*a[0] + ... + 1*a[7];
> }
>
> Here, the constants in the right hand sides were chosen so that a simple
> CSE would not work well on them, so this would test how well the compiler
> performs register assignment.. (It could also test a much more advanced
> CSE that could simplify this.) Again, a list of functons reg_assign1_16(),
> reg_assign1_32(), are created...
This does not work. a and b can be aliased.