blob: b04707ce9745f54a1b3ebaaefe82ae37e498daca [file] [log] [blame]
/* Slightly modified copy of gcc.target/arm/pr40956.c. */
/* { dg-options "-Os" } */
/* Make sure the constant "6" is loaded into register only once. */
/* { dg-final { scan-assembler-times "\tli.*6" 1 } } */
int foo(int p, int* q)
{
if (p!=9)
*q = 6;
else
*(q+1) = 6;
return 3;
}