From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2093) id 1AE0D385741C; Thu, 28 Apr 2022 03:23:04 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1AE0D385741C MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Kito Cheng To: gcc-cvs@gcc.gnu.org Subject: [gcc r12-8295] testsuite: Skip target not support -pthread [PR104676]. X-Act-Checkin: gcc X-Git-Author: Jia-Wei Chen X-Git-Refname: refs/heads/master X-Git-Oldrev: d1ee29fd7fb972fee141a0e475f780be4253758a X-Git-Newrev: d5b66a905322262483af5c4ca6cb6676c24e1f3f Message-Id: <20220428032304.1AE0D385741C@sourceware.org> Date: Thu, 28 Apr 2022 03:23:04 +0000 (GMT) X-BeenThere: gcc-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 Apr 2022 03:23:04 -0000 https://gcc.gnu.org/g:d5b66a905322262483af5c4ca6cb6676c24e1f3f commit r12-8295-gd5b66a905322262483af5c4ca6cb6676c24e1f3f Author: Jia-Wei Chen Date: Tue Apr 19 11:11:24 2022 +0800 testsuite: Skip target not support -pthread [PR104676]. The "ftree-parallelize-loops=" imply -pthread option in gcc/gcc.cc, some target are not support pthread like elf target use newlib, and will get an error: "*-*-elf-gcc: error: unrecognized command-line option '-pthread'" so we add an additional condition "{target pthread}" to make sure the dg-additional-options runs on support targets. gcc/testsuite/ChangeLog PR target/104676 * gcc.dg/torture/pr104676.c: Add "{target pthread}" check. Diff: --- gcc/testsuite/gcc.dg/torture/pr104676.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/testsuite/gcc.dg/torture/pr104676.c b/gcc/testsuite/gcc.dg/torture/pr104676.c index 50845bb9e15..0991b78f758 100644 --- a/gcc/testsuite/gcc.dg/torture/pr104676.c +++ b/gcc/testsuite/gcc.dg/torture/pr104676.c @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-additional-options "-ftree-loop-distribution -ftree-parallelize-loops=2" } */ +/* { dg-additional-options "-ftree-loop-distribution -ftree-parallelize-loops=2" { target pthread } } */ struct S { int f;