public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Andreas Krebbel <krebbel@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r12-4926] IBM Z: Define STACK_CHECK_MOVING_SP
Date: Thu,  4 Nov 2021 18:40:44 +0000 (GMT)	[thread overview]
Message-ID: <20211104184044.7E7243858439@sourceware.org> (raw)

https://gcc.gnu.org/g:79fe28d2c4b78562de095c1843d8d3b1a1e7d2d7

commit r12-4926-g79fe28d2c4b78562de095c1843d8d3b1a1e7d2d7
Author: Andreas Krebbel <krebbel@linux.ibm.com>
Date:   Thu Nov 4 19:37:19 2021 +0100

    IBM Z: Define STACK_CHECK_MOVING_SP
    
    With -fstack-check the stack probes emitted access memory below the
    stack pointer.
    
    gcc/ChangeLog:
    
            * config/s390/s390.h (STACK_CHECK_MOVING_SP): New macro
            definition.

Diff:
---
 gcc/config/s390/s390.h | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/gcc/config/s390/s390.h b/gcc/config/s390/s390.h
index fb16a455a03..186c5c6200b 100644
--- a/gcc/config/s390/s390.h
+++ b/gcc/config/s390/s390.h
@@ -332,6 +332,11 @@ extern const char *s390_host_detect_local_cpu (int argc, const char **argv);
 
 #define STACK_SIZE_MODE (Pmode)
 
+/* Make the stack pointer to be moved downwards while issuing stack probes with
+   -fstack-check.  We need this to prevent memory below the stack pointer from
+   being accessed.  */
+#define STACK_CHECK_MOVING_SP 1
+
 #ifndef IN_LIBGCC2
 
 /* Width of a word, in units (bytes).  */


                 reply	other threads:[~2021-11-04 18:40 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211104184044.7E7243858439@sourceware.org \
    --to=krebbel@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).