From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 7856) id 421ED385781A; Mon, 6 Mar 2023 07:56:26 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 421ED385781A DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1678089386; bh=BJ5Z6DwDib98OgsH86p1FEUK3sdtZVTOhGM7vVsPAlk=; h=From:To:Subject:Date:From; b=W+dT916AoFK76W9Sw6ZnNYZEq0/uEp1oUCvRANGpuYwcNOQoflHaXtHhXf6nb2il/ iPjr2JLYJBl/R6c05rFAf8arN5YY7K11xeCZwxFt7AgpySk8USYmltnB/oVduNRCsJ Zp9i1QiWBp77QmD6Z9dHDZf7YGfNm6Ilbuf+wT6E= MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Xi Ruoyao To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-6501] LoongArch: testsuite: Disable stack protector for some tests X-Act-Checkin: gcc X-Git-Author: Xi Ruoyao X-Git-Refname: refs/heads/master X-Git-Oldrev: 75eccddef5784bc5e262af31f535267a9c4e993e X-Git-Newrev: 67401d45972edb1c09918f9f7feea0ba00680ac4 Message-Id: <20230306075626.421ED385781A@sourceware.org> Date: Mon, 6 Mar 2023 07:56:26 +0000 (GMT) List-Id: https://gcc.gnu.org/g:67401d45972edb1c09918f9f7feea0ba00680ac4 commit r13-6501-g67401d45972edb1c09918f9f7feea0ba00680ac4 Author: Xi Ruoyao Date: Fri Mar 3 16:32:41 2023 +0800 LoongArch: testsuite: Disable stack protector for some tests Stack protector will affect stack layout and break the expectation of these tests, causing test failures if GCC is configured with --enable-default-ssp. gcc/testsuite/ChangeLog: * gcc.target/loongarch/prolog-opt.c (dg-options): Add -fno-stack-protector. * gcc.target/loongarch/stack-check-cfa-1.c (dg-options): Likewise. * gcc.target/loongarch/stack-check-cfa-2.c (dg-options): Likewise. Diff: --- gcc/testsuite/gcc.target/loongarch/prolog-opt.c | 2 +- gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c | 2 +- gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gcc/testsuite/gcc.target/loongarch/prolog-opt.c b/gcc/testsuite/gcc.target/loongarch/prolog-opt.c index 0470a1f1eee..e6a64263384 100644 --- a/gcc/testsuite/gcc.target/loongarch/prolog-opt.c +++ b/gcc/testsuite/gcc.target/loongarch/prolog-opt.c @@ -1,7 +1,7 @@ /* Test that LoongArch backend stack drop operation optimized. */ /* { dg-do compile } */ -/* { dg-options "-O2 -mabi=lp64d" } */ +/* { dg-options "-O2 -mabi=lp64d -fno-stack-protector" } */ /* { dg-final { scan-assembler "addi.d\t\\\$r3,\\\$r3,-16" } } */ extern int printf (char *, ...); 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 f0c6877fc25..3533fe7b685 100644 --- a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c +++ b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-1.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O2 -fstack-clash-protection --param stack-clash-protection-guard-size=16 -funwind-tables" } */ +/* { dg-options "-O2 -fstack-clash-protection --param stack-clash-protection-guard-size=16 -funwind-tables -fno-stack-protector" } */ /* { dg-require-effective-target supports_stack_clash_protection } */ /* { dg-skip-if "" { *-*-* } { "-fstack-check" } { "" } } */ 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 c6e07bc561a..e5e711105ac 100644 --- a/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c +++ b/gcc/testsuite/gcc.target/loongarch/stack-check-cfa-2.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-O2 -fstack-clash-protection --param stack-clash-protection-guard-size=16 -funwind-tables" } */ +/* { dg-options "-O2 -fstack-clash-protection --param stack-clash-protection-guard-size=16 -funwind-tables -fno-stack-protector" } */ /* { dg-require-effective-target supports_stack_clash_protection } */ /* { dg-skip-if "" { *-*-* } { "-fstack-check" } { "" } } */