Re: [PATCH][ARM] Updating testcase unsigned-extend-2.c

2016-12-21 Thread Kyrill Tkachov

Hi Andre,

On 21/06/16 15:16, Andre Vieira (lists) wrote:

Hello,

After some changes to GCC this test no longer tests the desired code
generation behavior. The generated assembly is better than it used to
be, but it has become too smart. I add an extra parameter to make sure
GCC can't optimize away the loop.

Tested for arm-none-eabi-gcc with a Cortex-M3 target.

Is this OK?


Ok if this passes on an A-profile target as well (-march=armv7-a or some such).
Sorry for missing this.
Thanks,
Kyrill


Cheers,
Andre

gcc/ChangeLog
2016-06-21  Andre Vieira  

 * gcc.target/arm/unsigned-extend-2.c: Update testcase.




[Ping 2][PATCH][ARM] Updating testcase unsigned-extend-2.c

2016-12-21 Thread Andre Vieira (lists)
On 12/12/16 14:20, Andre Vieira (lists) wrote:
> On 21/06/16 15:16, Andre Vieira (lists) wrote:
>> Hello,
>>
>> After some changes to GCC this test no longer tests the desired code
>> generation behavior. The generated assembly is better than it used to
>> be, but it has become too smart. I add an extra parameter to make sure
>> GCC can't optimize away the loop.
>>
>> Tested for arm-none-eabi-gcc with a Cortex-M3 target.
>>
>> Is this OK?
>>
>> Cheers,
>> Andre
>>
>> gcc/ChangeLog
>> 2016-06-21  Andre Vieira  
>>
>> * gcc.target/arm/unsigned-extend-2.c: Update testcase.
>>
> 
> Ping.
> 
Ping.


[Ping][PATCH][ARM] Updating testcase unsigned-extend-2.c

2016-12-12 Thread Andre Vieira (lists)
On 21/06/16 15:16, Andre Vieira (lists) wrote:
> Hello,
> 
> After some changes to GCC this test no longer tests the desired code
> generation behavior. The generated assembly is better than it used to
> be, but it has become too smart. I add an extra parameter to make sure
> GCC can't optimize away the loop.
> 
> Tested for arm-none-eabi-gcc with a Cortex-M3 target.
> 
> Is this OK?
> 
> Cheers,
> Andre
> 
> gcc/ChangeLog
> 2016-06-21  Andre Vieira  
> 
> * gcc.target/arm/unsigned-extend-2.c: Update testcase.
> 

Ping.


[PATCH][ARM] Updating testcase unsigned-extend-2.c

2016-06-21 Thread Andre Vieira (lists)
Hello,

After some changes to GCC this test no longer tests the desired code
generation behavior. The generated assembly is better than it used to
be, but it has become too smart. I add an extra parameter to make sure
GCC can't optimize away the loop.

Tested for arm-none-eabi-gcc with a Cortex-M3 target.

Is this OK?

Cheers,
Andre

gcc/ChangeLog
2016-06-21  Andre Vieira  

* gcc.target/arm/unsigned-extend-2.c: Update testcase.
>From 12da0a48045b37efb2e459116ec81cc7117a0981 Mon Sep 17 00:00:00 2001
From: Andre Simoes Dias Vieira 
Date: Mon, 20 Jun 2016 14:27:06 +0100
Subject: [PATCH] fix testcase

---
 gcc/testsuite/gcc.target/arm/unsigned-extend-2.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/testsuite/gcc.target/arm/unsigned-extend-2.c b/gcc/testsuite/gcc.target/arm/unsigned-extend-2.c
index b610b73617dc6e6a5428c966380516007a02acba..013240749ecaabf0d2e8ad802d27c7edc69d8828 100644
--- a/gcc/testsuite/gcc.target/arm/unsigned-extend-2.c
+++ b/gcc/testsuite/gcc.target/arm/unsigned-extend-2.c
@@ -2,13 +2,13 @@
 /* { dg-require-effective-target arm_thumb2_ok } */
 /* { dg-options "-O" } */
 
-unsigned short foo (unsigned short x)
+unsigned short foo (unsigned short x, unsigned short c)
 {
   unsigned char i = 0;
   for (i = 0; i < 8; i++)
 {
   x >>= 1;
-  x &= 0x7fff;
+  x &= c;
 }
   return x;
 }
-- 
1.9.1