From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by sourceware.org (Postfix) with ESMTPS id F32493858D1E for ; Wed, 30 Nov 2022 11:52:48 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org F32493858D1E Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=suse.de Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.de Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id E1FC51F8D4 for ; Wed, 30 Nov 2022 11:52:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1669809167; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type; bh=csqemcjZGj8d3RanOab9vpgLzR5ZsegHH1f0vb/Ig6A=; b=JwLF59jd5zf1lhhsLCFV6U3AeaIkFQYDsXVtwgb/nicyi6hgg5EEzFiLb1bh52q4B2WqQE L9DhX+hHduzoQhlpz+8hWGg3X2g+Q3bsHKMYY4A/YATSjntXndvkKGiN1V+dCAJhKknWq7 uqkqAyRAB4gMrd49y0BdOXGaCKg6eng= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1669809167; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc: mime-version:mime-version:content-type:content-type; bh=csqemcjZGj8d3RanOab9vpgLzR5ZsegHH1f0vb/Ig6A=; b=Q5IG1VRyAOTq+uPZjxKfd9nKkTTfgfbo0y21clHs4kqSfdUVPT5eYftiOsJsXqdIcsjy4V yk7CQfdrs4RKGeCA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id C39A113A70 for ; Wed, 30 Nov 2022 11:52:47 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id ejugLg9Eh2MNLAAAMHmgww (envelope-from ) for ; Wed, 30 Nov 2022 11:52:47 +0000 Date: Wed, 30 Nov 2022 12:52:47 +0100 (CET) From: Richard Biener To: gcc-patches@gcc.gnu.org Subject: [PATCH] Improve uninit diagnostic dumps MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Message-Id: <20221130115247.C39A113A70@imap2.suse-dmz.suse.de> X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 List-Id: The following dumps the edge a use is uninitialized in a PHI. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. * tree-ssa-uninit.cc (find_uninit_use): Dump the edge for a PHI node. --- gcc/tree-ssa-uninit.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/tree-ssa-uninit.cc b/gcc/tree-ssa-uninit.cc index bf2e50511af..7fbc384f2d4 100644 --- a/gcc/tree-ssa-uninit.cc +++ b/gcc/tree-ssa-uninit.cc @@ -1249,8 +1249,8 @@ find_uninit_use (gphi *phi, unsigned uninit_opnds, int *bb_to_rpo) if (dump_file && (dump_flags & TDF_DETAILS)) { - fprintf (dump_file, "Found unguarded use in bb %u: ", - use_bb->index); + fprintf (dump_file, "Found unguarded use on edge %u -> %u: ", + e->src->index, e->dest->index); print_gimple_stmt (dump_file, use_stmt, 0); } /* Found a phi use that is not guarded, mark the phi_result as -- 2.35.3