On Mon, May 11, 2015 at 10:43 AM, Thomas Preud'homme
wrote:
> Hi,
>
> Testcase made for PR64616 was only passing when using a litteral pool. Rather
> than having an alternative for systems where this is not true, this patch
> changes the test to check that a global copy propagation occurs in cprop2.
> This should work accross all ARM targets (it works when targetting Cortex-M0,
> Cortex-M3 and whatever default core for ARMv7-a with vfpv3-d16 FPU).
>
> ChangeLog entry is as follows:
>
> *** gcc/testsuite/ChangeLog ***
>
> 2015-05-04 Thomas Preud'homme
>
> * gcc.target/arm/pr64616.c: Test dump rather than assembly to work
> accross ARM targets.
>
> diff --git a/gcc/testsuite/gcc.target/arm/pr64616.c
> b/gcc/testsuite/gcc.target/arm/pr64616.c
> index c686ffa..2280f21 100644
> --- a/gcc/testsuite/gcc.target/arm/pr64616.c
> +++ b/gcc/testsuite/gcc.target/arm/pr64616.c
> @@ -1,5 +1,5 @@
> /* { dg-do compile } */
> -/* { dg-options "-O2" } */
> +/* { dg-options "-O2 -fdump-rtl-cprop2" } */
>
> int f (int);
> unsigned int glob;
> @@ -11,4 +11,5 @@ g ()
>glob = 5;
> }
>
> -/* { dg-final { scan-assembler-times "ldr" 2 } } */
> +/* { dg-final { scan-rtl-dump "GLOBAL COPY-PROP" "cprop2" } } */
> +/* { dg-final { cleanup-rtl-dump "cprop2" } } */
>
>
> Patch was tested by verifying that the pattern appears when targeting
> Cortex-M0, Cortex-M3 and
> the default core for ARMv7-a with vfpv3-d16 FPU.
>
> Best regards,
>
> Thomas
>
>
OK - thanks.
Ramana