From patchwork Mon Aug 25 21:07:48 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Pop X-Patchwork-Id: 382863 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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id BB0211400A3 for ; Tue, 26 Aug 2014 07:08:09 +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:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; q=dns; s=default; b=P+HzNyI9YanPGLi+G d6oph9Eb7vYQYr8DacUPXwOC6juPwbSeMDOixQKRWPdfi479JYKFi+iK3Vu5RJ6E da0v8Wzf6yWDM2j6zeFcw1woF5ZXUDy2ZvHyzgMvxWSlg0TRRhaDlg2gRh2Mepo+ V6STFh5p+viqXCTwzPWTARDKa0= 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:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=default; bh=wmn470nuNyZqEM0TFZAL28F eZq0=; b=vd3xzX2B2Ek8yj2qFZfUuEaUX6goEvwDhsI7XKAuRkLYS2WZ6xKgssB mceHlcObBU0ZDZQ2LChCD4URXHZSmaH4/2qeZbV0HeANssm5LIsaeFDKRe4On5p6 Lxw3NNt0cq6zJx/waAV8nTWKoKDXtNtI4gH6T2wvVYNmnXA8GfYU= Received: (qmail 26410 invoked by alias); 25 Aug 2014 21:08:01 -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 26390 invoked by uid 89); 25 Aug 2014 21:07:59 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-ie0-f178.google.com Received: from mail-ie0-f178.google.com (HELO mail-ie0-f178.google.com) (209.85.223.178) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Mon, 25 Aug 2014 21:07:54 +0000 Received: by mail-ie0-f178.google.com with SMTP id rd18so10521180iec.37 for ; Mon, 25 Aug 2014 14:07:52 -0700 (PDT) X-Received: by 10.50.176.202 with SMTP id ck10mr18263156igc.2.1409000872052; Mon, 25 Aug 2014 14:07:52 -0700 (PDT) Received: from instance-1.c.bardezibar.internal (127.121.211.130.bc.googleusercontent.com. [130.211.121.127]) by mx.google.com with ESMTPSA id an1sm4412040igc.7.2014.08.25.14.07.50 for (version=SSLv3 cipher=RC4-SHA bits=128/128); Mon, 25 Aug 2014 14:07:50 -0700 (PDT) Date: Mon, 25 Aug 2014 21:07:48 +0000 From: Sebastian Pop To: Richard Biener Cc: Bin Cheng , Tobias Grosser , GCC Patches Subject: Re: [PATCH GCC]Fix broken Canadian when checking isl library support Message-ID: <20140825210748.GA19958@instance-1.c.bardezibar.internal> References: <000801cfbd19$ec953ff0$c5bfbfd0$@arm.com> <20140825191857.GA27780@instance-1.c.bardezibar.internal> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20140825191857.GA27780@instance-1.c.bardezibar.internal> User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Sebastian Pop wrote: > Richard Biener wrote: > > I think it would be better to identify a set of features we rely on that > > are not present in earlier versions and make the test a link > > test unconditionally. > > > > Tobias, are there include files / types / functions we require > > that are not available in earlier versions? > > The version 0.12 of ISL has an include file isl/val.h that is not present in > previous versions of ISL. > > There also was a patch from Mircea a few weeks ago that was missing the > configure bits to check that the isl version contained isl/val.h. > I will update both patches and submit for review. I see that Mircea's patch has been committed: commit c5ec3cc336c7d42d9ad2995395d430b99a9a34cc Author: mircea Date: Mon Aug 11 15:05:48 2014 +0000 Replacement of isl_int by isl_val git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@213816 138bc75d-0d04-0410-961f-82ee72b054a4 Attached a patch to check for isl/val.h instead of ISL's release number. Bootstrapping on x86-64. Ok to commit? Thanks, Sebastian From 03ca0abce2a8f76aa7e935567d4ce6f1953ed1bf Mon Sep 17 00:00:00 2001 From: Sebastian Pop Date: Mon, 25 Aug 2014 20:55:09 +0000 Subject: [PATCH] check functionality of isl version 0.12 * config/isl.m4 (_ISL_CHECK_CT_PROG): Removed. (ISL_CHECK_VERSION): Check for functionality added to ISL 0.12 instead of checking for version number. * configure: Regenerated. * configure.ac (ISL_CHECK_VERSION): Do not use ISL version number. --- config/isl.m4 | 27 +++++--------------- configure | 79 +++------------------------------------------------------ configure.ac | 2 +- 3 files changed, 11 insertions(+), 97 deletions(-) diff --git a/config/isl.m4 b/config/isl.m4 index 57ae3c5..e940f10 100644 --- a/config/isl.m4 +++ b/config/isl.m4 @@ -93,20 +93,9 @@ AC_DEFUN([ISL_REQUESTED], ] ) -# _ISL_CHECK_CT_PROG(MAJOR, MINOR) -# -------------------------------------------- -# Helper for verifying ISL compile time version. -m4_define([_ISL_CHECK_CT_PROG],[AC_LANG_PROGRAM( - [#include - #include ], - [if (strncmp (isl_version (), "isl-$1.$2", strlen ("isl-$1.$2")) != 0) - return 1; - ])]) - -# ISL_CHECK_VERSION ISL_CHECK_VERSION (MAJOR, MINOR) +# ISL_CHECK_VERSION ISL_CHECK_VERSION () # ---------------------------------------------------------------- -# Test the found ISL to be exact of version MAJOR.MINOR and at least -# REVISION. +# Test that ISL contains functionality added to the minimum expected version. AC_DEFUN([ISL_CHECK_VERSION], [ if test "${ENABLE_ISL_CHECK}" = yes ; then @@ -118,15 +107,11 @@ AC_DEFUN([ISL_CHECK_VERSION], LDFLAGS="${_isl_saved_LDFLAGS} ${isllibs}" LIBS="${_isl_saved_LIBS} -lisl" - AC_MSG_CHECKING([for version $1.$2 of ISL]) - AC_RUN_IFELSE([_ISL_CHECK_CT_PROG($1,$2)], + AC_MSG_CHECKING([for version 0.12 of ISL]) + # isl/val.h has first been added to ISL in 0.12. + AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include ]], [[;]])], [gcc_cv_isl=yes], - [gcc_cv_isl=no], - [ - AC_LINK_IFELSE([_ISL_CHECK_CT_PROG($1,$2)], - [gcc_cv_isl=yes], - [gcc_cv_isl=no]) - ]) + [gcc_cv_isl=no]) AC_MSG_RESULT([$gcc_cv_isl]) CFLAGS=$_isl_saved_CFLAGS diff --git a/configure b/configure index c292b09..5941821 100755 --- a/configure +++ b/configure @@ -1874,48 +1874,6 @@ fi return $ac_retval } # ac_fn_c_try_link - -# ac_fn_c_try_run LINENO -# ---------------------- -# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes -# that executables *can* be run. -ac_fn_c_try_run () -{ - as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if { { ac_try="$ac_link" -case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_link") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' - { { case "(($ac_try" in - *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; - *) ac_try_echo=$ac_try;; -esac -eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" -$as_echo "$ac_try_echo"; } >&5 - (eval "$ac_try") 2>&5 - ac_status=$? - $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 - test $ac_status = 0; }; }; then : - ac_retval=0 -else - $as_echo "$as_me: program exited with status $ac_status" >&5 - $as_echo "$as_me: failed program was:" >&5 -sed 's/^/| /' conftest.$ac_ext >&5 - - ac_retval=$ac_status -fi - rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} - return $ac_retval - -} # ac_fn_c_try_run cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. @@ -5906,18 +5864,14 @@ $as_echo "$as_me: WARNING: using in-tree ISL, disabling version check" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version 0.12 of ISL" >&5 $as_echo_n "checking for version 0.12 of ISL... " >&6; } - if test "$cross_compiling" = yes; then : - - cat confdefs.h - <<_ACEOF >conftest.$ac_ext + # isl/val.h has first been added to ISL in 0.12. + cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ -#include - #include +#include int main () { -if (strncmp (isl_version (), "isl-0.12", strlen ("isl-0.12")) != 0) - return 1; - +; ; return 0; } @@ -5929,31 +5883,6 @@ else fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext - -else - cat confdefs.h - <<_ACEOF >conftest.$ac_ext -/* end confdefs.h. */ -#include - #include -int -main () -{ -if (strncmp (isl_version (), "isl-0.12", strlen ("isl-0.12")) != 0) - return 1; - - ; - return 0; -} -_ACEOF -if ac_fn_c_try_run "$LINENO"; then : - gcc_cv_isl=yes -else - gcc_cv_isl=no -fi -rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ - conftest.$ac_objext conftest.beam conftest.$ac_ext -fi - { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_isl" >&5 $as_echo "$gcc_cv_isl" >&6; } diff --git a/configure.ac b/configure.ac index 8f747d6..2dc657f 100644 --- a/configure.ac +++ b/configure.ac @@ -1652,7 +1652,7 @@ if test "x$with_isl" != "xno"; then dnl with user input. ISL_INIT_FLAGS dnl The versions of ISL that work for Graphite - ISL_CHECK_VERSION(0,12) + ISL_CHECK_VERSION() dnl Only execute fail-action, if ISL has been requested. ISL_IF_FAILED([ AC_MSG_ERROR([Unable to find a usable ISL. See config.log for details.])]) -- 1.7.10.4