public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* Backport fix for PR 65210 to gcc-5-branch
@ 2016-09-22 12:55 Senthil Kumar Selvaraj
  2016-09-26 12:45 ` [Patch, avr] " Senthil Kumar Selvaraj
  0 siblings, 1 reply; 3+ messages in thread
From: Senthil Kumar Selvaraj @ 2016-09-22 12:55 UTC (permalink / raw)
  To: gcc-patches; +Cc: Denis Chertykov

Hi,

  Is it ok to backport PR 65210 to gcc-5-branch? The patch is already in
  6.x and trunk.

Regards
Senthil

gcc/ChangeLog

2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

	Backport from trunk r227496

	PR target/65210
	* config/avr/avr.c (avr_eval_addr_attrib): Look for io_low
	attribute as well.

gcc/testsuite/ChangeLog

2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>

	Backport from trunk r227496

	PR target/65210
	* gcc.target/avr/pr65210.c: New test.

Index: gcc/config/avr/avr.c
===================================================================
--- gcc/config/avr/avr.c	(revision 240340)
+++ gcc/config/avr/avr.c	(working copy)
@@ -9122,6 +9122,8 @@
       if (SYMBOL_REF_FLAGS (x) & SYMBOL_FLAG_IO)
 	{
 	  attr = lookup_attribute ("io", DECL_ATTRIBUTES (decl));
+	  if (!attr || !TREE_VALUE (attr))
+	    attr = lookup_attribute ("io_low", DECL_ATTRIBUTES (decl));
 	  gcc_assert (attr);
 	}
       if (!attr || !TREE_VALUE (attr))
       Index: gcc/testsuite/gcc.target/avr/pr65210.c
===================================================================
--- gcc/testsuite/gcc.target/avr/pr65210.c	(nonexistent)
+++ gcc/testsuite/gcc.target/avr/pr65210.c	(working copy)
@@ -0,0 +1,7 @@
+/* { dg-do compile } */
+
+/* This testcase exposes PR65210. Usage of the io_low attribute
+   causes assertion failure because code only looks for the io
+   attribute if SYMBOL_FLAG_IO is set. */
+
+volatile char q __attribute__((io_low,address(0x81)));

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

* Re: [Patch, avr] Backport fix for PR 65210 to gcc-5-branch
  2016-09-22 12:55 Backport fix for PR 65210 to gcc-5-branch Senthil Kumar Selvaraj
@ 2016-09-26 12:45 ` Senthil Kumar Selvaraj
  2016-09-26 20:17   ` Denis Chertykov
  0 siblings, 1 reply; 3+ messages in thread
From: Senthil Kumar Selvaraj @ 2016-09-26 12:45 UTC (permalink / raw)
  To: gcc-patches, Denis Chertykov

Ping!

Regards
Senthil
Senthil Kumar Selvaraj writes:

> Hi,
>
>   Is it ok to backport PR 65210 to gcc-5-branch? The patch is already in
>   6.x and trunk.
>
> Regards
> Senthil
>
> gcc/ChangeLog
>
> 2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
>
> 	Backport from trunk r227496
>
> 	PR target/65210
> 	* config/avr/avr.c (avr_eval_addr_attrib): Look for io_low
> 	attribute as well.
>
> gcc/testsuite/ChangeLog
>
> 2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
>
> 	Backport from trunk r227496
>
> 	PR target/65210
> 	* gcc.target/avr/pr65210.c: New test.
>
> Index: gcc/config/avr/avr.c
> ===================================================================
> --- gcc/config/avr/avr.c	(revision 240340)
> +++ gcc/config/avr/avr.c	(working copy)
> @@ -9122,6 +9122,8 @@
>        if (SYMBOL_REF_FLAGS (x) & SYMBOL_FLAG_IO)
>  	{
>  	  attr = lookup_attribute ("io", DECL_ATTRIBUTES (decl));
> +	  if (!attr || !TREE_VALUE (attr))
> +	    attr = lookup_attribute ("io_low", DECL_ATTRIBUTES (decl));
>  	  gcc_assert (attr);
>  	}
>        if (!attr || !TREE_VALUE (attr))
>        Index: gcc/testsuite/gcc.target/avr/pr65210.c
> ===================================================================
> --- gcc/testsuite/gcc.target/avr/pr65210.c	(nonexistent)
> +++ gcc/testsuite/gcc.target/avr/pr65210.c	(working copy)
> @@ -0,0 +1,7 @@
> +/* { dg-do compile } */
> +
> +/* This testcase exposes PR65210. Usage of the io_low attribute
> +   causes assertion failure because code only looks for the io
> +   attribute if SYMBOL_FLAG_IO is set. */
> +
> +volatile char q __attribute__((io_low,address(0x81)));

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

* Re: [Patch, avr] Backport fix for PR 65210 to gcc-5-branch
  2016-09-26 12:45 ` [Patch, avr] " Senthil Kumar Selvaraj
@ 2016-09-26 20:17   ` Denis Chertykov
  0 siblings, 0 replies; 3+ messages in thread
From: Denis Chertykov @ 2016-09-26 20:17 UTC (permalink / raw)
  To: Senthil Kumar Selvaraj; +Cc: gcc-patches

Approved.
Please commit.

2016-09-26 15:30 GMT+03:00 Senthil Kumar Selvaraj
<senthil_kumar.selvaraj@atmel.com>:
> Ping!
>
> Regards
> Senthil
> Senthil Kumar Selvaraj writes:
>
>> Hi,
>>
>>   Is it ok to backport PR 65210 to gcc-5-branch? The patch is already in
>>   6.x and trunk.
>>
>> Regards
>> Senthil
>>
>> gcc/ChangeLog
>>
>> 2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
>>
>>       Backport from trunk r227496
>>
>>       PR target/65210
>>       * config/avr/avr.c (avr_eval_addr_attrib): Look for io_low
>>       attribute as well.
>>
>> gcc/testsuite/ChangeLog
>>
>> 2016-09-22  Senthil Kumar Selvaraj  <senthil_kumar.selvaraj@atmel.com>
>>
>>       Backport from trunk r227496
>>
>>       PR target/65210
>>       * gcc.target/avr/pr65210.c: New test.
>>
>> Index: gcc/config/avr/avr.c
>> ===================================================================
>> --- gcc/config/avr/avr.c      (revision 240340)
>> +++ gcc/config/avr/avr.c      (working copy)
>> @@ -9122,6 +9122,8 @@
>>        if (SYMBOL_REF_FLAGS (x) & SYMBOL_FLAG_IO)
>>       {
>>         attr = lookup_attribute ("io", DECL_ATTRIBUTES (decl));
>> +       if (!attr || !TREE_VALUE (attr))
>> +         attr = lookup_attribute ("io_low", DECL_ATTRIBUTES (decl));
>>         gcc_assert (attr);
>>       }
>>        if (!attr || !TREE_VALUE (attr))
>>        Index: gcc/testsuite/gcc.target/avr/pr65210.c
>> ===================================================================
>> --- gcc/testsuite/gcc.target/avr/pr65210.c    (nonexistent)
>> +++ gcc/testsuite/gcc.target/avr/pr65210.c    (working copy)
>> @@ -0,0 +1,7 @@
>> +/* { dg-do compile } */
>> +
>> +/* This testcase exposes PR65210. Usage of the io_low attribute
>> +   causes assertion failure because code only looks for the io
>> +   attribute if SYMBOL_FLAG_IO is set. */
>> +
>> +volatile char q __attribute__((io_low,address(0x81)));
>

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

end of thread, other threads:[~2016-09-26 20:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-22 12:55 Backport fix for PR 65210 to gcc-5-branch Senthil Kumar Selvaraj
2016-09-26 12:45 ` [Patch, avr] " Senthil Kumar Selvaraj
2016-09-26 20:17   ` Denis Chertykov

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).