public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH, ARM] Fix stack red zone bug (PR38644)
@ 2011-11-02  3:23 Jiangning Liu
  2011-11-16  9:59 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6 Sebastian Huber
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Jiangning Liu @ 2011-11-02  3:23 UTC (permalink / raw)
  To: gcc-patches

Hi,

This patch is to fix PR38644 in ARM back-end. OK for trunk?

For every detail, please refer to
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

ChangeLog:

2011-11-2  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
        for epilogue having stack adjustment.

ChangeLog of testsuite:

2011-11-2  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * gcc.target/arm/stack-red-zone.c: New.

Thanks,
-Jiangning

Patch:

diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index f1ada6f..1f6fc26
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -22215,6 +22215,8 @@ thumb1_expand_epilogue (void)
   gcc_assert (amount >= 0);
   if (amount)
     {
+      emit_insn (gen_blockage ());
+
       if (amount < 512)
 	emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx,
 			       GEN_INT (amount)));
diff --git a/gcc/testsuite/gcc.target/arm/stack-red-zone.c
b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
new file mode 100644
index 0000000..b9f0f99
--- /dev/null
+++ b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
@@ -0,0 +1,12 @@
+/* No stack red zone.  PR38644.  */
+/* { dg-options "-mthumb -O2" } */
+/* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } }
*/
+
+extern int doStreamReadBlock (int *, char *, int size, int);
+
+char readStream (int *s)
+{
+       char c = 0;
+       doStreamReadBlock (s, &c, 1, *s);
+       return c;
+}





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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2011-11-02  3:23 [PATCH, ARM] Fix stack red zone bug (PR38644) Jiangning Liu
@ 2011-11-16  9:59 ` Sebastian Huber
  2011-11-16 11:44   ` Ramana Radhakrishnan
  2011-11-16 10:04 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5 Sebastian Huber
  2011-11-16 10:10 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.4 Sebastian Huber
  2 siblings, 1 reply; 14+ messages in thread
From: Sebastian Huber @ 2011-11-16  9:59 UTC (permalink / raw)
  To: gcc-patches

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

Hi,

this is Jiangning Liu's patch to fix PR38644 in ARM back-end

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

intended for the GCC 4.6 branch.  Test results:

http://gcc.gnu.org/ml/gcc-testresults/2011-11/msg01619.html

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

[-- Attachment #2: pr38644-4.6.patch --]
[-- Type: text/x-patch, Size: 1342 bytes --]

ChangeLog:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
        for epilogue having stack adjustment.

ChangeLog of testsuite:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * gcc.target/arm/stack-red-zone.c: New.
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 75174a3..acdfbd5 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -20864,6 +20864,8 @@ thumb1_expand_epilogue (void)
   gcc_assert (amount >= 0);
   if (amount)
     {
+      emit_insn (gen_blockage ());
+
       if (amount < 512)
 	emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx,
 			       GEN_INT (amount)));
diff --git a/gcc/testsuite/gcc.target/arm/stack-red-zone.c b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
new file mode 100644
index 0000000..b9f0f99
--- /dev/null
+++ b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
@@ -0,0 +1,12 @@
+/* No stack red zone.  PR38644.  */
+/* { dg-options "-mthumb -O2" } */
+/* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } } */
+
+extern int doStreamReadBlock (int *, char *, int size, int);
+
+char readStream (int *s)
+{
+       char c = 0;
+       doStreamReadBlock (s, &c, 1, *s);
+       return c;
+}

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5
  2011-11-02  3:23 [PATCH, ARM] Fix stack red zone bug (PR38644) Jiangning Liu
  2011-11-16  9:59 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6 Sebastian Huber
@ 2011-11-16 10:04 ` Sebastian Huber
  2011-11-16 15:15   ` Ramana Radhakrishnan
  2011-11-16 10:10 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.4 Sebastian Huber
  2 siblings, 1 reply; 14+ messages in thread
From: Sebastian Huber @ 2011-11-16 10:04 UTC (permalink / raw)
  To: gcc-patches

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

Hi,

this is Jiangning Liu's patch to fix PR38644 in ARM back-end

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

intended for the GCC 4.5 branch.  I didn't run the test suite.  I only compiled 
the arm-eabi-gcc and checked that this patch fixes the test case.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.


[-- Attachment #2: pr38644-4.5.patch --]
[-- Type: text/x-patch, Size: 1342 bytes --]

ChangeLog:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
        for epilogue having stack adjustment.

ChangeLog of testsuite:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * gcc.target/arm/stack-red-zone.c: New.
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index 08208b7..16325bb 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -19408,6 +19408,8 @@ thumb1_expand_epilogue (void)
   gcc_assert (amount >= 0);
   if (amount)
     {
+      emit_insn (gen_blockage ());
+
       if (amount < 512)
 	emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx,
 			       GEN_INT (amount)));
diff --git a/gcc/testsuite/gcc.target/arm/stack-red-zone.c b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
new file mode 100644
index 0000000..b9f0f99
--- /dev/null
+++ b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
@@ -0,0 +1,12 @@
+/* No stack red zone.  PR38644.  */
+/* { dg-options "-mthumb -O2" } */
+/* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } } */
+
+extern int doStreamReadBlock (int *, char *, int size, int);
+
+char readStream (int *s)
+{
+       char c = 0;
+       doStreamReadBlock (s, &c, 1, *s);
+       return c;
+}

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.4
  2011-11-02  3:23 [PATCH, ARM] Fix stack red zone bug (PR38644) Jiangning Liu
  2011-11-16  9:59 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6 Sebastian Huber
  2011-11-16 10:04 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5 Sebastian Huber
@ 2011-11-16 10:10 ` Sebastian Huber
  2 siblings, 0 replies; 14+ messages in thread
From: Sebastian Huber @ 2011-11-16 10:10 UTC (permalink / raw)
  To: gcc-patches

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

Hi,

this is Jiangning Liu's patch to fix PR38644 in ARM back-end

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

intended for the GCC 4.4 branch.  I didn't run the test suite.  I only compiled 
the arm-eabi-gcc and checked that this patch fixes the test case.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.



[-- Attachment #2: pr38644-4.4.patch --]
[-- Type: text/x-patch, Size: 1342 bytes --]

ChangeLog:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
        for epilogue having stack adjustment.

ChangeLog of testsuite:

2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * gcc.target/arm/stack-red-zone.c: New.
diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
index eed5cfd..69641ef 100644
--- a/gcc/config/arm/arm.c
+++ b/gcc/config/arm/arm.c
@@ -17682,6 +17682,8 @@ thumb1_expand_epilogue (void)
   gcc_assert (amount >= 0);
   if (amount)
     {
+      emit_insn (gen_blockage ());
+
       if (amount < 512)
 	emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx,
 			       GEN_INT (amount)));
diff --git a/gcc/testsuite/gcc.target/arm/stack-red-zone.c b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
new file mode 100644
index 0000000..b9f0f99
--- /dev/null
+++ b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
@@ -0,0 +1,12 @@
+/* No stack red zone.  PR38644.  */
+/* { dg-options "-mthumb -O2" } */
+/* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } } */
+
+extern int doStreamReadBlock (int *, char *, int size, int);
+
+char readStream (int *s)
+{
+       char c = 0;
+       doStreamReadBlock (s, &c, 1, *s);
+       return c;
+}

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2011-11-16  9:59 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6 Sebastian Huber
@ 2011-11-16 11:44   ` Ramana Radhakrishnan
  2011-12-21  8:44     ` Sebastian Huber
  0 siblings, 1 reply; 14+ messages in thread
From: Ramana Radhakrishnan @ 2011-11-16 11:44 UTC (permalink / raw)
  To: Sebastian Huber; +Cc: gcc-patches, Jiangning Liu

On 16 November 2011 08:23, Sebastian Huber
<sebastian.huber@embedded-brains.de> wrote:
> Hi,
>
> this is Jiangning Liu's patch to fix PR38644 in ARM back-end
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

OK to backports in all release branches.

Before committing the backport please modify the changelog entry to
indicate that this was a backport in the changelog entry.

Something like ..

2011-11-16  Sebastian Huber  <...>

        Backport from mainline.
        2011-11-04  Jiangning Liu  <jiangning.liu@arm.com>

        PR rtl-optimization/38644
        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
        for epilogue having stack adjustment.

cheers
Ramana





>
> intended for the GCC 4.6 branch.  Test results:
>
> http://gcc.gnu.org/ml/gcc-testresults/2011-11/msg01619.html
>
> --
> Sebastian Huber, embedded brains GmbH
>
> Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
> Phone   : +49 89 18 90 80 79-6
> Fax     : +49 89 18 90 80 79-9
> E-Mail  : sebastian.huber@embedded-brains.de
> PGP     : Public key available on request.
>
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
>

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5
  2011-11-16 10:04 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5 Sebastian Huber
@ 2011-11-16 15:15   ` Ramana Radhakrishnan
  0 siblings, 0 replies; 14+ messages in thread
From: Ramana Radhakrishnan @ 2011-11-16 15:15 UTC (permalink / raw)
  To: Sebastian Huber; +Cc: gcc-patches

On 16 November 2011 08:25, Sebastian Huber
<sebastian.huber@embedded-brains.de> wrote:
> Hi,
>
> this is Jiangning Liu's patch to fix PR38644 in ARM back-end
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.
>
> intended for the GCC 4.5 branch.  I didn't run the test suite.  I only
> compiled the arm-eabi-gcc and checked that this patch fixes the test case.
>

Please make sure you run the testsuite for both 4.5 and 4.4 in case
you want them backported there.

Ramana

> --
> Sebastian Huber, embedded brains GmbH
>
> Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
> Phone   : +49 89 18 90 80 79-6
> Fax     : +49 89 18 90 80 79-9
> E-Mail  : sebastian.huber@embedded-brains.de
> PGP     : Public key available on request.
>
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.
>
>

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2011-11-16 11:44   ` Ramana Radhakrishnan
@ 2011-12-21  8:44     ` Sebastian Huber
  2012-01-09  8:50       ` Sebastian Huber
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian Huber @ 2011-12-21  8:44 UTC (permalink / raw)
  To: Ramana Radhakrishnan; +Cc: gcc-patches, Jiangning Liu

Would someone mind committing this to the 4.6 branch.  Thanks.

The test suite results are only missing for the 4.4 and 4.5 branch.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2011-12-21  8:44     ` Sebastian Huber
@ 2012-01-09  8:50       ` Sebastian Huber
  2012-01-09 16:59         ` Ramana Radhakrishnan
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian Huber @ 2012-01-09  8:50 UTC (permalink / raw)
  To: Ramana Radhakrishnan; +Cc: gcc-patches, Jiangning Liu

What is missing to get this ported back to the GCC 4.6 branch? Btw. what is 
this ARM/embedded-4_6-branch for a branch?  It seems to be more actively 
maintained.

On 12/21/2011 09:10 AM, Sebastian Huber wrote:
> Would someone mind committing this to the 4.6 branch. Thanks.
>
> The test suite results are only missing for the 4.4 and 4.5 branch.
>
-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2012-01-09  8:50       ` Sebastian Huber
@ 2012-01-09 16:59         ` Ramana Radhakrishnan
  2012-01-10  8:09           ` Sebastian Huber
  0 siblings, 1 reply; 14+ messages in thread
From: Ramana Radhakrishnan @ 2012-01-09 16:59 UTC (permalink / raw)
  To: Sebastian Huber; +Cc: gcc-patches, Jiangning Liu

On 9 January 2012 08:49, Sebastian Huber
<sebastian.huber@embedded-brains.de> wrote:
> What is missing to get this ported back to the GCC 4.6 branch?

I ran a sanity check again today and backported them to the 4.6
branch. Sorry about the delay. I prefer to do the same for the 4.4 and
4.5 branches. If you are happy to test them then I'm ok with doing the
backports.

Thanks
Ramana


>
>
> On 12/21/2011 09:10 AM, Sebastian Huber wrote:
>>
>> Would someone mind committing this to the 4.6 branch. Thanks.
>>
>> The test suite results are only missing for the 4.4 and 4.5 branch.
>>
> --
> Sebastian Huber, embedded brains GmbH
>
> Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
> Phone   : +49 89 18 90 80 79-6
> Fax     : +49 89 18 90 80 79-9
> E-Mail  : sebastian.huber@embedded-brains.de
> PGP     : Public key available on request.
>
> Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6
  2012-01-09 16:59         ` Ramana Radhakrishnan
@ 2012-01-10  8:09           ` Sebastian Huber
  0 siblings, 0 replies; 14+ messages in thread
From: Sebastian Huber @ 2012-01-10  8:09 UTC (permalink / raw)
  To: Ramana Radhakrishnan; +Cc: gcc-patches, Jiangning Liu

On 01/09/2012 05:58 PM, Ramana Radhakrishnan wrote:
> On 9 January 2012 08:49, Sebastian Huber
> <sebastian.huber@embedded-brains.de>  wrote:
>> What is missing to get this ported back to the GCC 4.6 branch?
>
> I ran a sanity check again today and backported them to the 4.6
> branch. Sorry about the delay.

Thanks.

> I prefer to do the same for the 4.4 and
> 4.5 branches. If you are happy to test them then I'm ok with doing the
> backports.

The problem with the 4.4 and 4.5 branches is that I have no RTEMS EABI 
configuration for these branches (it was added in 4.6) and thus I cannot run 
the tests on a simulator.  How do you run the test suite?

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644)
  2011-11-08 11:36     ` Richard Guenther
@ 2011-11-08 12:17       ` Sebastian Huber
  0 siblings, 0 replies; 14+ messages in thread
From: Sebastian Huber @ 2011-11-08 12:17 UTC (permalink / raw)
  To: Richard Guenther; +Cc: Jiangning Liu, gcc-patches

On 11/08/2011 12:15 PM, Richard Guenther wrote:
> On Tue, Nov 8, 2011 at 9:06 AM, Sebastian Huber
> <sebastian.huber@embedded-brains.de>  wrote:
>> On 11/02/2011 11:05 AM, Richard Guenther wrote:
>>>
>>> On Wed, Nov 2, 2011 at 3:27 AM, Jiangning Liu<jiangning.liu@arm.com>
>>>   wrote:
>>>>
>>>>>   Hi,
>>>>>
>>>>>   This patch is to fix PR38644 in ARM back-end. OK for trunk?
>>>>>
>>>>>   For every detail, please refer to
>>>>>   http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.
>>>
>>> Ok in absence of any target maintainer objection within 24h.
>>
>> Ping.
>
> Was checked in 4 days ago.

Sorry, but there was no update in the PR and it is also not included in the 4.6 
branch.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644)
  2011-11-08  8:43   ` Sebastian Huber
@ 2011-11-08 11:36     ` Richard Guenther
  2011-11-08 12:17       ` Sebastian Huber
  0 siblings, 1 reply; 14+ messages in thread
From: Richard Guenther @ 2011-11-08 11:36 UTC (permalink / raw)
  To: Sebastian Huber; +Cc: Jiangning Liu, gcc-patches

On Tue, Nov 8, 2011 at 9:06 AM, Sebastian Huber
<sebastian.huber@embedded-brains.de> wrote:
> On 11/02/2011 11:05 AM, Richard Guenther wrote:
>>
>> On Wed, Nov 2, 2011 at 3:27 AM, Jiangning Liu<jiangning.liu@arm.com>
>>  wrote:
>>>
>>> >  Hi,
>>> >
>>> >  This patch is to fix PR38644 in ARM back-end. OK for trunk?
>>> >
>>> >  For every detail, please refer to
>>> >  http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.
>>
>> Ok in absence of any target maintainer objection within 24h.
>
> Ping.

Was checked in 4 days ago.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644)
  2011-11-02 10:16 ` [PATCH, ARM] Fix stack red zone bug (PR38644) Richard Guenther
@ 2011-11-08  8:43   ` Sebastian Huber
  2011-11-08 11:36     ` Richard Guenther
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian Huber @ 2011-11-08  8:43 UTC (permalink / raw)
  To: Richard Guenther; +Cc: Jiangning Liu, gcc-patches

On 11/02/2011 11:05 AM, Richard Guenther wrote:
> On Wed, Nov 2, 2011 at 3:27 AM, Jiangning Liu<jiangning.liu@arm.com>  wrote:
>> >  Hi,
>> >
>> >  This patch is to fix PR38644 in ARM back-end. OK for trunk?
>> >
>> >  For every detail, please refer to
>> >  http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.
> Ok in absence of any target maintainer objection within 24h.

Ping.

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

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

* Re: [PATCH, ARM] Fix stack red zone bug (PR38644)
       [not found] <4eb0aabe.101c970a.42b1.ffffb249SMTPIN_ADDED@mx.google.com>
@ 2011-11-02 10:16 ` Richard Guenther
  2011-11-08  8:43   ` Sebastian Huber
  0 siblings, 1 reply; 14+ messages in thread
From: Richard Guenther @ 2011-11-02 10:16 UTC (permalink / raw)
  To: Jiangning Liu; +Cc: gcc-patches

On Wed, Nov 2, 2011 at 3:27 AM, Jiangning Liu <jiangning.liu@arm.com> wrote:
> Hi,
>
> This patch is to fix PR38644 in ARM back-end. OK for trunk?
>
> For every detail, please refer to
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=38644.

Ok in absence of any target maintainer objection within 24h.

Thanks,
Richard.

> ChangeLog:
>
> 2011-11-2  Jiangning Liu  <jiangning.liu@arm.com>
>
>        PR rtl-optimization/38644
>        * config/arm/arm.c (thumb1_expand_epilogue): Add memory barrier
>        for epilogue having stack adjustment.
>
> ChangeLog of testsuite:
>
> 2011-11-2  Jiangning Liu  <jiangning.liu@arm.com>
>
>        PR rtl-optimization/38644
>        * gcc.target/arm/stack-red-zone.c: New.
>
> Thanks,
> -Jiangning
>
> Patch:
>
> diff --git a/gcc/config/arm/arm.c b/gcc/config/arm/arm.c
> index f1ada6f..1f6fc26
> --- a/gcc/config/arm/arm.c
> +++ b/gcc/config/arm/arm.c
> @@ -22215,6 +22215,8 @@ thumb1_expand_epilogue (void)
>   gcc_assert (amount >= 0);
>   if (amount)
>     {
> +      emit_insn (gen_blockage ());
> +
>       if (amount < 512)
>        emit_insn (gen_addsi3 (stack_pointer_rtx, stack_pointer_rtx,
>                               GEN_INT (amount)));
> diff --git a/gcc/testsuite/gcc.target/arm/stack-red-zone.c
> b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
> new file mode 100644
> index 0000000..b9f0f99
> --- /dev/null
> +++ b/gcc/testsuite/gcc.target/arm/stack-red-zone.c
> @@ -0,0 +1,12 @@
> +/* No stack red zone.  PR38644.  */
> +/* { dg-options "-mthumb -O2" } */
> +/* { dg-final { scan-assembler "ldrb\[^\n\]*\\n\[\t \]*add\[\t \]*sp" } }
> */
> +
> +extern int doStreamReadBlock (int *, char *, int size, int);
> +
> +char readStream (int *s)
> +{
> +       char c = 0;
> +       doStreamReadBlock (s, &c, 1, *s);
> +       return c;
> +}
>
>
>
>
>
>

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

end of thread, other threads:[~2012-01-10  8:09 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-02  3:23 [PATCH, ARM] Fix stack red zone bug (PR38644) Jiangning Liu
2011-11-16  9:59 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6 Sebastian Huber
2011-11-16 11:44   ` Ramana Radhakrishnan
2011-12-21  8:44     ` Sebastian Huber
2012-01-09  8:50       ` Sebastian Huber
2012-01-09 16:59         ` Ramana Radhakrishnan
2012-01-10  8:09           ` Sebastian Huber
2011-11-16 10:04 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.5 Sebastian Huber
2011-11-16 15:15   ` Ramana Radhakrishnan
2011-11-16 10:10 ` [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.4 Sebastian Huber
     [not found] <4eb0aabe.101c970a.42b1.ffffb249SMTPIN_ADDED@mx.google.com>
2011-11-02 10:16 ` [PATCH, ARM] Fix stack red zone bug (PR38644) Richard Guenther
2011-11-08  8:43   ` Sebastian Huber
2011-11-08 11:36     ` Richard Guenther
2011-11-08 12:17       ` Sebastian Huber

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