On 12/08/2016 05:55 AM, Martin Liška wrote:
With the patch applied, one can distinguish between PROB_VERY_UNLIKELY and real zero probability:f () { int _1; <bb 2> [100.00%]: _1 = __builtin_sprintf (&d2, "%i", 12); if (_1 != 2) goto <bb 3>; [0.04%] else goto <bb 4>; [99.96%] <bb 3> [0.04%]: __builtin_abort (); <bb 4> [99.96%]: return; } Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin 0001-Print-2-digits-after-decimal-delimiter-for-BB-freque.patch From 18f0fa35f91db675f5abf6a0aa8cf3582e79c772 Mon Sep 17 00:00:00 2001 From: marxin <[email protected]> Date: Thu, 1 Dec 2016 10:55:55 +0100 Subject: [PATCH] Print 2 digits after decimal delimiter for BB frequencies gcc/ChangeLog: 2016-12-01 Martin Liska <[email protected]> * gimple-pretty-print.c (dump_edge_probability): Use newly defined PROBABILITY_FORMAT. (dump_gimple_label): Likewise. (dump_gimple_bb_header): Likewise. gcc/testsuite/ChangeLog: 2016-12-02 Martin Liska <[email protected]> * gcc.dg/tree-ssa/20040703-1.c: Update scanned pattern. * gcc.dg/tree-ssa/dump-2.c: Likewise.
OK. jeff
