From patchwork Mon Feb 15 09:43:53 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eric Botcazou X-Patchwork-Id: 1440415 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=gcc.gnu.org (client-ip=8.43.85.97; helo=sourceware.org; envelope-from=gcc-patches-bounces@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=adacore-com.20150623.gappssmtp.com header.i=@adacore-com.20150623.gappssmtp.com header.a=rsa-sha256 header.s=20150623 header.b=NOMmnZsO; dkim-atps=neutral Received: from sourceware.org (unknown [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4DfK1d0SCXz9rx8 for ; Mon, 15 Feb 2021 20:44:03 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 7F980393D037; Mon, 15 Feb 2021 09:43:58 +0000 (GMT) X-Original-To: gcc-patches@gcc.gnu.org Delivered-To: gcc-patches@gcc.gnu.org Received: from mail-wr1-x431.google.com (mail-wr1-x431.google.com [IPv6:2a00:1450:4864:20::431]) by sourceware.org (Postfix) with ESMTPS id 223C03858D29 for ; Mon, 15 Feb 2021 09:43:56 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 223C03858D29 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=adacore.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=botcazou@adacore.com Received: by mail-wr1-x431.google.com with SMTP id b3so8085481wrj.5 for ; Mon, 15 Feb 2021 01:43:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=ZTNgzXep7Zq2uNytV9eb6daqeHVrGv1ExtYq1y+t5f8=; b=NOMmnZsOXH5yCDqiZyxZ8iVIh4Ls88VzITpturZ1w/90Jby2yEHaLXwF5ObJMniZDJ D2f8Yegva4XjFOjXrfwwWSUWWxT3NRMbhgd2BeD0cgmrhS6J8d1etBgffxj1O9cjV29H JKobvBrAFHoQxlNrKyosLo1uj2y45TwYvcINqQZQkVZXnGg97p913sNLZY5xfn4L+MHt kJ1sgHR0btswHbz6baA0WomqG0n41kggskO5K+6Y/rnkax++yE6u01I81+Wob33ZvkEP TJYOKJ54er+ic6BLvXgrksBHdSqZT7mHnoWl7M0d6aTASc1RMh9iwY2Vf00ZUvcmBoud bzfg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=ZTNgzXep7Zq2uNytV9eb6daqeHVrGv1ExtYq1y+t5f8=; b=mqMZmRQyzRiLwSYwlWa0wrqWco64Wnk4RaehkiwLmNnBh5X/LMdqNT2+7zvCet7UOx iC4W6nBjwQQqYPW7jJPWLaZnO5ZL39R+q1D2GmMIgwt6ehYuZpovMQaL6VqebDLEDaeN cPeZMIWiwILDymb7FUwOPsuLVu3mL2H5j76A2SOdps35Lm+8JMl21MNDri4SGRUEzsDy 2ffJrH8nHS8EJV+pK60sGMoUkhlRSJvudXtXQu0SmVvv4wn7aCc0VqtVxljLnBfCkZHE 3JMUFgqj34kO/B+i6T2gqCxOZ9U3qPwS0fg6kQ1zexpdYYPiPXRraSJi26ebW6XrHhC1 HASA== X-Gm-Message-State: AOAM531lUqkvNmZxY0803kIOujR5CuJdCSEtIYfHB5zWb7B2ip3BYnUL GtU1cM7lXt/N5t80mvJO4vJ6zVlbAikmvZXR X-Google-Smtp-Source: ABdhPJxlcmD9RClcvXOsQPpSJkyRGCavMB3T9XWppBq4uVegywOcJQ5uEz+7HsA6bmaSFbgk2UWYEA== X-Received: by 2002:a5d:618e:: with SMTP id j14mr17487472wru.377.1613382235272; Mon, 15 Feb 2021 01:43:55 -0800 (PST) Received: from fomalhaut.localnet ([2a01:e0a:41b:84f0:cf71:f5e0:b050:bede]) by smtp.gmail.com with ESMTPSA id m1sm14657355wmq.36.2021.02.15.01.43.54 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 15 Feb 2021 01:43:54 -0800 (PST) From: Eric Botcazou X-Google-Original-From: Eric Botcazou To: gcc-patches@gcc.gnu.org Subject: Fix cast in df_worklist_dataflow_doublequeue Date: Mon, 15 Feb 2021 10:43:53 +0100 Message-ID: <2821264.qbJml4gSNV@fomalhaut> MIME-Version: 1.0 X-Spam-Status: No, score=-11.4 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc-patches@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gcc-patches-bounces@gcc.gnu.org Sender: "Gcc-patches" The existing cast to float gives weird results in the RTL dump files on x86 when the compiler is configured --with-fpmath=sse. Bootstrapped on x86/Linux, applied on the mainline as obvious. 2021-02-15 Eric Botcazou * df-core.c (df_worklist_dataflow_doublequeue): Use proper cast. diff --git a/gcc/df-core.c b/gcc/df-core.c index 8536e5e1f51..b4407eec460 100644 --- a/gcc/df-core.c +++ b/gcc/df-core.c @@ -1064,7 +1064,7 @@ df_worklist_dataflow_doublequeue (struct dataflow *dataflow, " n_basic_blocks %d n_edges %d" " count %d (%5.2g)\n", n_basic_blocks_for_fn (cfun), n_edges_for_fn (cfun), - dcount, dcount / (float)n_basic_blocks_for_fn (cfun)); + dcount, dcount / (double)n_basic_blocks_for_fn (cfun)); } /* Worklist-based dataflow solver. It uses sbitmap as a worklist,