public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH][ARM] Updating testcase unsigned-extend-2.c
@ 2016-06-21 14:16 Andre Vieira (lists)
  2016-12-12 14:20 ` [Ping][PATCH][ARM] " Andre Vieira (lists)
  2016-12-21 12:09 ` [PATCH][ARM] " Kyrill Tkachov
  0 siblings, 2 replies; 4+ messages in thread
From: Andre Vieira (lists) @ 2016-06-21 14:16 UTC (permalink / raw)
  To: GCC Patches

[-- Attachment #1: Type: text/plain, Size: 473 bytes --]

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  <andre.simoesdiasvieira@arm.com>

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

[-- Attachment #2: 0001-fix-testcase.patch --]
[-- Type: text/x-patch, Size: 964 bytes --]

From 12da0a48045b37efb2e459116ec81cc7117a0981 Mon Sep 17 00:00:00 2001
From: Andre Simoes Dias Vieira <andsim01@arm.com>
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


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Ping][PATCH][ARM] Updating testcase unsigned-extend-2.c
  2016-06-21 14:16 [PATCH][ARM] Updating testcase unsigned-extend-2.c Andre Vieira (lists)
@ 2016-12-12 14:20 ` Andre Vieira (lists)
  2016-12-21 12:08   ` [Ping 2][PATCH][ARM] " Andre Vieira (lists)
  2016-12-21 12:09 ` [PATCH][ARM] " Kyrill Tkachov
  1 sibling, 1 reply; 4+ messages in thread
From: Andre Vieira (lists) @ 2016-12-12 14:20 UTC (permalink / raw)
  To: gcc-patches

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  <andre.simoesdiasvieira@arm.com>
> 
>         * gcc.target/arm/unsigned-extend-2.c: Update testcase.
> 

Ping.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Ping 2][PATCH][ARM] Updating testcase unsigned-extend-2.c
  2016-12-12 14:20 ` [Ping][PATCH][ARM] " Andre Vieira (lists)
@ 2016-12-21 12:08   ` Andre Vieira (lists)
  0 siblings, 0 replies; 4+ messages in thread
From: Andre Vieira (lists) @ 2016-12-21 12:08 UTC (permalink / raw)
  To: gcc-patches; +Cc: Ramana Radhakrishnan, Kyrill Tkachov

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  <andre.simoesdiasvieira@arm.com>
>>
>>         * gcc.target/arm/unsigned-extend-2.c: Update testcase.
>>
> 
> Ping.
> 
Ping.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH][ARM] Updating testcase unsigned-extend-2.c
  2016-06-21 14:16 [PATCH][ARM] Updating testcase unsigned-extend-2.c Andre Vieira (lists)
  2016-12-12 14:20 ` [Ping][PATCH][ARM] " Andre Vieira (lists)
@ 2016-12-21 12:09 ` Kyrill Tkachov
  1 sibling, 0 replies; 4+ messages in thread
From: Kyrill Tkachov @ 2016-12-21 12:09 UTC (permalink / raw)
  To: Andre Vieira (lists), GCC Patches

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  <andre.simoesdiasvieira@arm.com>
>
>          * gcc.target/arm/unsigned-extend-2.c: Update testcase.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2016-12-21 12:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-21 14:16 [PATCH][ARM] Updating testcase unsigned-extend-2.c Andre Vieira (lists)
2016-12-12 14:20 ` [Ping][PATCH][ARM] " Andre Vieira (lists)
2016-12-21 12:08   ` [Ping 2][PATCH][ARM] " Andre Vieira (lists)
2016-12-21 12:09 ` [PATCH][ARM] " Kyrill Tkachov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).