public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Xi Ruoyao <xry111@xry111.site>
To: gcc-patches@gcc.gnu.org
Cc: WANG Xuerui <i@xen0n.name>, Lulu Cheng <chenglulu@loongson.cn>,
	Chenghua Xu <xuchenghua@loongson.cn>,
	Yujie Yang <yangyujie@loongson.cn>,
	Xi Ruoyao <xry111@xry111.site>
Subject: [PATCH 2/2] LoongArch: testsuite: Adjust stack offsets in stack-check-cfa tests
Date: Fri,  3 Mar 2023 16:40:11 +0800	[thread overview]
Message-ID: <20230303084011.8989-3-xry111@xry111.site> (raw)
In-Reply-To: <20230303084011.8989-1-xry111@xry111.site>

Once upon the time we used to save two registers unnecessarily, costing
16 bytes.  Now the issue seems fixed (not sure by which commit though),
adjust the stack offsets to reflex the change.

gcc/testsuite/ChangeLog:

	* gcc.target/loongarch/stack-check-cfa-1.c (dg-final): Adjust
	expected stack offset.
	* gcc.target/loongarch/stack-check-cfa-2.c (dg-final): Likewise.
---
 gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c | 2 +-
 gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c
index 3533fe7b685..cd72154f46c 100644
--- a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c
+++ b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c
@@ -6,7 +6,7 @@
 #define SIZE 128*1024
 #include "stack-check-prologue.h"
 
-/* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 131088} 1 } } */
+/* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 131072} 1 } } */
 /* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 0} 1 } } */
 
 /* Checks that the CFA notes are correct for every sp adjustment.  */
diff --git a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c
index e5e711105ac..3e5ca05b2da 100644
--- a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c
+++ b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c
@@ -6,7 +6,7 @@
 #define SIZE 1280*1024 + 512
 #include "stack-check-prologue.h"
 
-/* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 1311248} 1 } } */
+/* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 1311232} 1 } } */
 /* { dg-final { scan-assembler-times {\.cfi_def_cfa_offset 0} 1 } } */
 
 /* Checks that the CFA notes are correct for every sp adjustment.  */
-- 
2.39.2


  parent reply	other threads:[~2023-03-03  8:40 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-03  8:40 [PATCH 0/2] LoongArch: testsuite: Fix tests related to stack Xi Ruoyao
2023-03-03  8:40 ` [PATCH 1/2] LoongArch: testsuite: Disable stack protector for some tests Xi Ruoyao
2023-03-03  8:40 ` Xi Ruoyao [this message]
2023-03-03 16:21 ` [PATCH 0/2] LoongArch: testsuite: Fix tests related to stack Mike Stump
2023-03-05 16:21   ` Xi Ruoyao
2023-03-06  1:15     ` Lulu Cheng
2023-03-06  2:48       ` Xi Ruoyao
2023-03-06  3:16         ` Xi Ruoyao
2023-03-06  5:59           ` Xi Ruoyao
2023-03-06  8:02             ` Xi Ruoyao
2023-03-06  8:12               ` Lulu Cheng
2023-03-06  8:18                 ` Xi Ruoyao
2023-03-06  8:22                   ` Lulu Cheng

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=20230303084011.8989-3-xry111@xry111.site \
    --to=xry111@xry111.site \
    --cc=chenglulu@loongson.cn \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=i@xen0n.name \
    --cc=xuchenghua@loongson.cn \
    --cc=yangyujie@loongson.cn \
    /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).