From patchwork Thu Oct 20 09:25:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tsukasa OI X-Patchwork-Id: 6089 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:4ac7:0:0:0:0:0 with SMTP id y7csp155052wrs; Thu, 20 Oct 2022 02:33:03 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5teXqDP6NFraAN2npoL79SlCBMAMMOdXYRyvzTj2iCubR0g4/ci327+us+pcOTOjBHUc0J X-Received: by 2002:a05:6402:d62:b0:460:42c8:fc6d with SMTP id ec34-20020a0564020d6200b0046042c8fc6dmr2200022edb.182.1666258382958; Thu, 20 Oct 2022 02:33:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666258382; cv=none; d=google.com; s=arc-20160816; b=Mh/1yCTvXeR0Sk5W4PPRdoDHcxtIzxTRUbIKCwsZ80V67I59HLxBWE9V+qibjkSzlr xs9kVCypeWkd8hjRfF3gkFV6BmYBmns2DVp/+mh35qRpQzMChklA6SKHiah158DfoaOY 2N9uUsS3v384k1sktk/SVCRA/G7IN9i/5/1Vv8l+oUMmZuUzKrw0mrNau7gYKr9nQ49w O8eJVGqSXwD/Q+KXDs/W03zliXvK7Lb0iSr7tAW77mZM8R1MRlfNxC35MMUEwALvTfrZ +bsT/VJE9X5EuIhmGCFfV8BzmaNffOSHKuoAPrLW1xwE4DyKkduWv/yRJfq/67La+GY0 mzVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:cc:reply-to:from:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence :content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:dmarc-filter:delivered-to:dkim-signature :dkim-filter; bh=r0aaAv7OLLsxbWQ3RLGxINi4GmezOuh09aFpYxc1dNk=; b=jefFqsU8W5XW21SoUgk1ScH17Kf6vkYHYPaOjBzjnoFlR+rOHNMFZlpTXDciuVzVnp F+KGtALSgEb2GYG1r8Ll9l/d/ZBX/ndaSH8u5uSBCnHb/MW7ghdXnGIra5FkBet4poPI BCutFH7AWE9oHlLRhxJn0NpdqMJ+GjAhPXnqKq20fYRZVCYYb7FzuIDIICVCNbEgVfBP aNezFwg6N3FiACQNOYHUjbkI0DNNT6i5dJbe0azrYvAcv5UCxCX56JMhiTbNrEx1tbs1 g2rsDF+azOKLOlC3TAI4rR3YPpKheMo27C3K/Ag2A3i6xiKKxpSe4U3M3ctJE7U5cEBN nb+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sourceware.org header.s=default header.b=KGmmnvLB; spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sourceware.org Received: from sourceware.org (ip-8-43-85-97.sourceware.org. [8.43.85.97]) by mx.google.com with ESMTPS id k16-20020a170906971000b0078307781936si14333408ejx.359.2022.10.20.02.33.02 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 20 Oct 2022 02:33:02 -0700 (PDT) Received-SPF: pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) client-ip=8.43.85.97; Authentication-Results: mx.google.com; dkim=pass header.i=@sourceware.org header.s=default header.b=KGmmnvLB; spf=pass (google.com: domain of binutils-bounces+ouuuleilei=gmail.com@sourceware.org designates 8.43.85.97 as permitted sender) smtp.mailfrom="binutils-bounces+ouuuleilei=gmail.com@sourceware.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sourceware.org Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id B19BB39490AD for ; Thu, 20 Oct 2022 09:29:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B19BB39490AD DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1666258181; bh=r0aaAv7OLLsxbWQ3RLGxINi4GmezOuh09aFpYxc1dNk=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=KGmmnvLBb5oEZNkVn5vnOcpzWjL0DV4WUSepAUQwmR2QEkYwpxw4lVEcTmxAPHHWV rFDpFPJKW5yITYuGLRYScY+uYP9QvXdHMQ1uTneNQynwczqDG5RAHmr+iE8qimVM3z hgxpdqrE1eo0MelQxBbCnNfWrx9z8lkY8lk+mPks= X-Original-To: binutils@sourceware.org Delivered-To: binutils@sourceware.org Received: from mail-sender-0.a4lg.com (mail-sender-0.a4lg.com [IPv6:2401:2500:203:30b:4000:6bfe:4757:0]) by sourceware.org (Postfix) with ESMTPS id 610DD381DC60 for ; Thu, 20 Oct 2022 09:28:34 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 610DD381DC60 Received: from [127.0.0.1] (localhost [127.0.0.1]) by mail-sender-0.a4lg.com (Postfix) with ESMTPSA id BAE09300089; Thu, 20 Oct 2022 09:28:32 +0000 (UTC) To: Tsukasa OI , Andrew Burgess , Mike Frysinger , Nick Clifton Subject: [PATCH 11/40] cpu/frv: Initialize some variables Date: Thu, 20 Oct 2022 09:25:57 +0000 Message-Id: In-Reply-To: References: Mime-Version: 1.0 X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, GIT_PATCH_0, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: binutils@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Binutils mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Tsukasa OI via Binutils From: Tsukasa OI Reply-To: Tsukasa OI Cc: binutils@sourceware.org Errors-To: binutils-bounces+ouuuleilei=gmail.com@sourceware.org Sender: "Binutils" X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1747198550557286074?= X-GMAIL-MSGID: =?utf-8?q?1747198550557286074?= GCC generates a warning if a variable may be used uninitialized on some cases ("-Wmaybe-uninitialized"). Despite that this will not cause a build failure even on the default configuration (with "--enable-werror"), it is better to be fixed. The cause of this warning, sim/frv/sem.c is generated by CGEN from cpu/frv.cpu. This commit adds initialization of some variables that caused GCC warnings. cpu/ChangeLog: * frv.cpu (cmpb): Initialize cc variable. (load-double-gr-u-semantics, clddu) Initialize address variable. --- cpu/frv.cpu | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cpu/frv.cpu b/cpu/frv.cpu index cdb169eddc1..6af8c3ab347 100644 --- a/cpu/frv.cpu +++ b/cpu/frv.cpu @@ -4266,6 +4266,7 @@ "cmpb$pack $GRi,$GRj,$ICCi_1" (+ pack (GRk-null) OP_00 GRi ICCi_1 OPE2_0C GRj) (sequence ((QI cc)) + (set cc 0) (set-n cc (eq (and GRi #xff000000) (and GRj #xff000000))) (set-z cc (eq (and GRi #x00ff0000) (and GRj #x00ff0000))) (set-v cc (eq (and GRi #x0000ff00) (and GRj #x0000ff00))) @@ -4655,6 +4656,7 @@ (define-pmacro (load-double-gr-u-semantics) (sequence ((WI address)) + (set address 0) (load-double-semantics 0 DI GR address GRj) (if (ne (index-of GRi) (index-of GRdoublek)) (sequence () @@ -5309,6 +5311,7 @@ (+ pack GRdoublek OP_62 GRi CCi cond OPE4_1 GRj) (if (eq CCi (or cond 2)) (sequence ((WI address)) + (set address 0) (load-double-semantics 0 DI GR address GRj) (if (ne (index-of GRi) (index-of GRdoublek)) (set GRi address))))