From: Richard Henderson Date: Tue, 24 Jan 2012 17:44:15 +0000 (-0800) Subject: sparc: Use match_code in zero_or_v7_operand. X-Git-Tag: releases/gcc-4.7.0~824 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f1d4a790ec622a2c905b4b1e379731d670450470;p=thirdparty%2Fgcc.git sparc: Use match_code in zero_or_v7_operand. Failure to do so means that genpreds doesn't know that we're matching a const_int, and it generates the wrong mode test. * config/sparc/predicates.md (zero_or_v7_operand): Use match_code. From-SVN: r183481 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4197c182ed47..c06613e49306 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2012-01-25 Richard Henderson + + * config/sparc/predicates.md (zero_or_v7_operand): Use match_code. + 2012-01-25 Richard Henderson PR target/51968 diff --git a/gcc/config/sparc/predicates.md b/gcc/config/sparc/predicates.md index 81e532064984..308fbd6bb741 100644 --- a/gcc/config/sparc/predicates.md +++ b/gcc/config/sparc/predicates.md @@ -1,5 +1,5 @@ ;; Predicate definitions for SPARC. -;; Copyright (C) 2005, 2007, 2008, 2010 Free Software Foundation, Inc. +;; Copyright (C) 2005, 2007, 2008, 2010, 2012 Free Software Foundation, Inc. ;; ;; This file is part of GCC. ;; @@ -113,8 +113,9 @@ ;; Return true if OP is Zero, or if the target is V7. (define_predicate "zero_or_v7_operand" - (ior (match_test "op == const0_rtx") - (match_test "!TARGET_V8 && !TARGET_V9"))) + (and (match_code "const_int") + (ior (match_test "INTVAL (op) == 0") + (match_test "!TARGET_V8 && !TARGET_V9")))) ;; Predicates for symbolic constants.