From patchwork Thu Aug 15 14:10:44 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Charles Baylis X-Patchwork-Id: 267392 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id F15AF2C0254 for ; Fri, 16 Aug 2013 00:10:56 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:date:message-id:subject:from:to:content-type; q= dns; s=default; b=j2xwav9GbY1pFBBSgqxiAAhoO7COp9JrgB8qMeqKWLJL+p EOoisMaahzlMpO3/Y/oriYD2VPWVgmp0+TrX/d7mDsScIKO8VJcNpHWeHMGsOqeM tfSg9VUepKysQDD+vGNdhRI9MZH+YT5ZiLNJRot8+hOgsQE4twpyp1y3IJZlA= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :mime-version:date:message-id:subject:from:to:content-type; s= default; bh=VXrPhAUxAaPFmdU6dbs1k1XJYtc=; b=o/gbyDSjlHrWjWyEaAOH mC1ANBUkbVR6CCHuylsCmV47l64rgbgLTQcyyQwkVt8axj+fuiR8VUYt1QI9ck62 LagoqvAehndRPlwEkHiQHzenGeIiQH3aXAd08JYJUh9hbnf0uj+3wmRTZokUjqEu Vxudp7RWKPGDAqMHZjTWuqI= Received: (qmail 25650 invoked by alias); 15 Aug 2013 14:10:48 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 25633 invoked by uid 89); 15 Aug 2013 14:10:47 -0000 X-Spam-SWARE-Status: No, score=-2.4 required=5.0 tests=AWL, BAYES_00, KHOP_RCVD_UNTRUST, RCVD_IN_DNSWL_LOW, RCVD_IN_HOSTKARMA_YE autolearn=ham version=3.3.2 Received: from mail-lb0-f178.google.com (HELO mail-lb0-f178.google.com) (209.85.217.178) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Thu, 15 Aug 2013 14:10:46 +0000 Received: by mail-lb0-f178.google.com with SMTP id z5so688145lbh.9 for ; Thu, 15 Aug 2013 07:10:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=0Jqp+GgqLu1EY2ks9O4q1GAuZMojAFv0l7gijyIrdhU=; b=j3dBUX7c46hiwkbd03FolJSOcvieNk5aitFI5w5onx9nuOgqWJvo0A0xaEhbB258oH h0WL4t4DW5AYpxrgbuQUfo8lVt/GKBKUES+HpekLkFtZDFf3X+MBH0Qh73Odcge0ypVK 3rOzV63GeigQt3+hN3qPTv1mTwx3K6NuOiCwUtvqdKkuefDvRzqv6fKqYhY1G2cgVY+w Y06Kg7WmvMI0bIpNMKaZGFV+A+dme5pNG5UdZKrlkQLuWLRglfZteRnjT2bMT+zd4Zci nZimkLqIcfMfRRdWWFyDU7LRKaItDZ4hTRa6eB4uEgnKFUrIV+iG6RPtkJM23I8YDkTi WuiQ== X-Gm-Message-State: ALoCoQlnTwF8apThqIhBRhG2ChuIr+h8SCEKE7Y8jMoTd1Afk6OuWt96g/+16jMxikRYdjIpqKS2 MIME-Version: 1.0 X-Received: by 10.112.77.134 with SMTP id s6mr1795203lbw.38.1376575844117; Thu, 15 Aug 2013 07:10:44 -0700 (PDT) Received: by 10.112.3.169 with HTTP; Thu, 15 Aug 2013 07:10:44 -0700 (PDT) Date: Thu, 15 Aug 2013 15:10:44 +0100 Message-ID: Subject: [PATCH,ARM] fix testsuite failures for arm-none-linux-gnueabihf From: Charles Baylis To: GCC Patches X-Virus-Found: No Hi The attached patch fixes some tests which fail when testing gcc for a arm-none-linux-gnueabihf target because they do not expect to be built with a hard float ABI. The change in target-supports.exp fixes arm-fp16-ops-5.c and arm-fp16-ops-6.c. Tested on arm-none-linux-gnueabihf using qemu-arm, and does not cause any other tests to break. Comments? This is my first patch, so please point out anything wrong. 2013-08-15 Charles Baylis * gcc.dg/builtin-apply2.c: skip test on arm hardfloat ABI targets * gcc.dg/tls/pr42894.c: Use -mfloat-abi=soft as Thumb1 does not support hardfloat ABI * arm/thumb-ltu.c: Use -mfloat-abi=soft as Thumb1 does not support hardfloat ABI * target-supports.exp: don't force -mfloat-abi=soft when building for hardfloat target Index: gcc/testsuite/gcc.dg/builtin-apply2.c =================================================================== --- gcc/testsuite/gcc.dg/builtin-apply2.c (revision 201726) +++ gcc/testsuite/gcc.dg/builtin-apply2.c (working copy) @@ -1,6 +1,7 @@ /* { dg-do run } */ /* { dg-skip-if "Variadic funcs have all args on stack. Normal funcs have args in registers." { "aarch64*-*-* avr-*-* " } { "*" } { "" } } */ /* { dg-skip-if "Variadic funcs use Base AAPCS. Normal funcs use VFP variant." { "arm*-*-*" } { "-mfloat-abi=hard" } { "" } } */ +/* { dg-skip-if "Variadic funcs use Base AAPCS. Normal funcs use VFP variant." { "arm*-*-gnueabihf" } { "*" } { "-mfloat-abi=soft*" } } */ /* PR target/12503 */ /* Origin: */ Index: gcc/testsuite/gcc.dg/tls/pr42894.c =================================================================== --- gcc/testsuite/gcc.dg/tls/pr42894.c (revision 201726) +++ gcc/testsuite/gcc.dg/tls/pr42894.c (working copy) @@ -1,6 +1,7 @@ /* PR target/42894 */ /* { dg-do compile } */ /* { dg-options "-march=armv5te -mthumb" { target arm*-*-* } } */ +/* { dg-options "-march=armv5te -mthumb -mfloat-abi=soft" { target arm*-*-*hf } } */ /* { dg-require-effective-target tls } */ extern __thread int t; Index: gcc/testsuite/gcc.target/arm/thumb-ltu.c =================================================================== --- gcc/testsuite/gcc.target/arm/thumb-ltu.c (revision 201726) +++ gcc/testsuite/gcc.target/arm/thumb-ltu.c (working copy) @@ -1,6 +1,6 @@ /* { dg-do compile } */ /* { dg-skip-if "incompatible options" { arm*-*-* } { "-march=*" } { "-march=armv6" "-march=armv6j" "-march=armv6z" } } */ -/* { dg-options "-mcpu=arm1136jf-s -mthumb -O2" } */ +/* { dg-options "-mcpu=arm1136jf-s -mthumb -O2 -mfloat-abi=soft" } */ void f(unsigned a, unsigned b, unsigned c, unsigned d) { Index: gcc/testsuite/lib/target-supports.exp =================================================================== --- gcc/testsuite/lib/target-supports.exp (revision 201726) +++ gcc/testsuite/lib/target-supports.exp (working copy) @@ -2445,6 +2445,11 @@ # Must generate floating-point instructions. return 0 } + if [check-flags [list "" { *-*-gnueabihf } { "*" } { "" } ]] { + # Use existing float-abi and force an fpu which supports fp16 + set et_arm_fp16_flags "-mfpu=vfpv4" + return 1; + } if [check-flags [list "" { *-*-* } { "-mfpu=*" } { "" } ]] { # The existing -mfpu value is OK; use it, but add softfp. set et_arm_fp16_flags "-mfloat-abi=softfp"