From patchwork Thu Mar 2 19:20:21 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Schmidt X-Patchwork-Id: 734759 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 3vZ2GL1SKqz9s7n for ; Fri, 3 Mar 2017 06:20:41 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="jPTBhJth"; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:to:cc :from:subject:date:mime-version:content-type :content-transfer-encoding:message-id; q=dns; s=default; b=up8D/ z8uziBC9gEViK7hb+HBKE50Ls2g8yRf46V1lrD4e4hyEpZbAO4UZeslL1XZorYVr v4L/+wD/foM3hhZr+Pze4Pnxn4LLtWJgPADg+O2EcuB79F10b3cCZTqpVXh5zJ4r P2R7qzMQyi+AsuNvvRU4lNqP5zlbmVp43ZnDoU= 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:to:cc :from:subject:date:mime-version:content-type :content-transfer-encoding:message-id; s=default; bh=TT4FMlqbWie AsB7DLPYQBMxd6VY=; b=jPTBhJthoxDfDhFfPf/Kp3nEbID/vGaruxifSSy/8z4 dsqUOEXA45EXBJBZWdEg9fY05MQ1wvA0jrUih1fvfdzhHd63CGA5yNlISxjL1OUk 4NWAxfzHPmBnjOSwLkKYZV+M9WQj3CULPo0sURfw9wJMWJ9Bu/TVZr/QoYWgTldI = Received: (qmail 71392 invoked by alias); 2 Mar 2017 19:20:30 -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 71378 invoked by uid 89); 2 Mar 2017 19:20:29 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-9.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS, KAM_LAZY_DOMAIN_SECURITY, KHOP_DYNAMIC, RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.2 spammy=sk:UNSPEC_, sk:vlogica, sk:unspec_, gpc_reg_operand X-HELO: mx0a-001b2d01.pphosted.com Received: from mx0b-001b2d01.pphosted.com (HELO mx0a-001b2d01.pphosted.com) (148.163.158.5) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 02 Mar 2017 19:20:28 +0000 Received: from pps.filterd (m0098421.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.20/8.16.0.20) with SMTP id v22J9Euc017203 for ; Thu, 2 Mar 2017 14:20:27 -0500 Received: from e38.co.us.ibm.com (e38.co.us.ibm.com [32.97.110.159]) by mx0a-001b2d01.pphosted.com with ESMTP id 28xs8c8k7b-1 (version=TLSv1.2 cipher=AES256-SHA bits=256 verify=NOT) for ; Thu, 02 Mar 2017 14:20:26 -0500 Received: from localhost by e38.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 2 Mar 2017 12:20:25 -0700 Received: from d03dlp02.boulder.ibm.com (9.17.202.178) by e38.co.us.ibm.com (192.168.1.138) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Thu, 2 Mar 2017 12:20:23 -0700 Received: from b03cxnp08027.gho.boulder.ibm.com (b03cxnp08027.gho.boulder.ibm.com [9.17.130.19]) by d03dlp02.boulder.ibm.com (Postfix) with ESMTP id D7C803E40047; Thu, 2 Mar 2017 12:20:22 -0700 (MST) Received: from b03ledav003.gho.boulder.ibm.com (b03ledav003.gho.boulder.ibm.com [9.17.130.234]) by b03cxnp08027.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id v22JKGcg8716708; Thu, 2 Mar 2017 12:20:22 -0700 Received: from b03ledav003.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B75146A03D; Thu, 2 Mar 2017 12:20:22 -0700 (MST) Received: from bigmac.rchland.ibm.com (unknown [9.10.86.201]) by b03ledav003.gho.boulder.ibm.com (Postfix) with ESMTP id 6EB126A043; Thu, 2 Mar 2017 12:20:22 -0700 (MST) To: GCC Patches Cc: Segher Boessenkool , David Edelsohn From: Bill Schmidt Subject: [PATCH, rs6000, committed] Fix bootstrap failures for uninitialized memory Date: Thu, 2 Mar 2017 13:20:21 -0600 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 X-TM-AS-GCONF: 00 X-Content-Scanned: Fidelis XPS MAILER x-cbid: 17030219-0028-0000-0000-0000073097C3 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00006710; HX=3.00000240; KW=3.00000007; PH=3.00000004; SC=3.00000206; SDB=6.00829166; UDB=6.00406472; IPR=6.00606663; BA=6.00005186; NDR=6.00000001; ZLA=6.00000005; ZF=6.00000009; ZB=6.00000000; ZP=6.00000000; ZH=6.00000000; ZU=6.00000002; MB=3.00014502; XFM=3.00000012; UTC=2017-03-02 19:20:24 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 17030219-0029-0000-0000-0000340759D1 Message-Id: X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2017-03-02_17:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 spamscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1702020001 definitions=main-1703020166 X-IsSubscribed: yes Hi, The expanded warnings for uninitialized memory caught a couple of problems in the rs6000 back end, causing bootstrap to fail. Some of them were just introduced yesterday, while others are a bit older. These are just misnumbering of operands, skipping over one and causing it to be uninitialized. Bootstrapped and tested on powerpc64le-unknown-linux-gnu, committed as obvious. Thanks, Bill 2017-03-02 Bill Schmidt * config/rs6000/vector.md (vector_ne__p): Correct operand numbers. (vector_ae__p): Likewise. (vector_nez__p): Likewise. (vector_ne_v2di_p): Likewise. (vector_ae_v2di_p): Likewise. (vector_ne__p): Likewise. * config/rs6000/vsx.md (vsx_tsqrt2_fg): Correct operand numbers. (vsx_tsqrt2_fe): Likewise. Index: gcc/config/rs6000/vector.md =================================================================== --- gcc/config/rs6000/vector.md (revision 245843) +++ gcc/config/rs6000/vector.md (working copy) @@ -700,7 +700,7 @@ (unspec:CC [(ne:CC (match_operand:VI 1 "vlogical_operand") (match_operand:VI 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (ne:VI (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -708,7 +708,7 @@ (const_int 0)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (mode); + operands[3] = gen_reg_rtx (mode); }) ;; This expansion handles the V16QI, V8HI, and V4SI modes in the @@ -719,7 +719,7 @@ (unspec:CC [(ne:CC (match_operand:VI 1 "vlogical_operand") (match_operand:VI 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (ne:VI (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -730,7 +730,7 @@ (const_int 1)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (mode); + operands[3] = gen_reg_rtx (mode); }) ;; This expansion handles the V16QI, V8HI, and V4SI modes in the @@ -763,7 +763,7 @@ (unspec:CC [(eq:CC (match_operand:V2DI 1 "vlogical_operand") (match_operand:V2DI 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (eq:V2DI (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -771,7 +771,7 @@ (const_int 0)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (V2DImode); + operands[3] = gen_reg_rtx (V2DImode); }) ;; This expansion handles the V2DI mode in the implementation of the @@ -786,7 +786,7 @@ (unspec:CC [(eq:CC (match_operand:V2DI 1 "vlogical_operand") (match_operand:V2DI 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (eq:V2DI (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -797,7 +797,7 @@ (const_int 1)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (V2DImode); + operands[3] = gen_reg_rtx (V2DImode); }) ;; This expansion handles the V4SF and V2DF modes in the Power9 @@ -811,7 +811,7 @@ (unspec:CC [(eq:CC (match_operand:VEC_F 1 "vlogical_operand") (match_operand:VEC_F 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (eq:VEC_F (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -819,7 +819,7 @@ (const_int 0)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (mode); + operands[3] = gen_reg_rtx (mode); }) ;; This expansion handles the V4SF and V2DF modes in the Power9 @@ -833,7 +833,7 @@ (unspec:CC [(eq:CC (match_operand:VEC_F 1 "vlogical_operand") (match_operand:VEC_F 2 "vlogical_operand"))] UNSPEC_PREDICATE)) - (set (match_dup 4) + (set (match_dup 3) (eq:VEC_F (match_dup 1) (match_dup 2)))]) (set (match_operand:SI 0 "register_operand" "=r") @@ -844,7 +844,7 @@ (const_int 1)))] "TARGET_P9_VECTOR" { - operands[4] = gen_reg_rtx (mode); + operands[3] = gen_reg_rtx (mode); }) (define_expand "vector_gt__p" Index: gcc/config/rs6000/vsx.md =================================================================== --- gcc/config/rs6000/vsx.md (revision 245843) +++ gcc/config/rs6000/vsx.md (working copy) @@ -1383,28 +1383,28 @@ ;; *tsqrt* returning the fg flag (define_expand "vsx_tsqrt2_fg" - [(set (match_dup 3) + [(set (match_dup 2) (unspec:CCFP [(match_operand:VSX_B 1 "vsx_register_operand" "")] UNSPEC_VSX_TSQRT)) (set (match_operand:SI 0 "gpc_reg_operand" "") - (gt:SI (match_dup 3) + (gt:SI (match_dup 2) (const_int 0)))] "VECTOR_UNIT_VSX_P (mode)" { - operands[3] = gen_reg_rtx (CCFPmode); + operands[2] = gen_reg_rtx (CCFPmode); }) ;; *tsqrt* returning the fe flag (define_expand "vsx_tsqrt2_fe" - [(set (match_dup 3) + [(set (match_dup 2) (unspec:CCFP [(match_operand:VSX_B 1 "vsx_register_operand" "")] UNSPEC_VSX_TSQRT)) (set (match_operand:SI 0 "gpc_reg_operand" "") - (eq:SI (match_dup 3) + (eq:SI (match_dup 2) (const_int 0)))] "VECTOR_UNIT_VSX_P (mode)" { - operands[3] = gen_reg_rtx (CCFPmode); + operands[2] = gen_reg_rtx (CCFPmode); }) (define_insn "*vsx_tsqrt2_internal"