aboutsummaryrefslogtreecommitdiff
path: root/gcc/ipa-cp.c
diff options
context:
space:
mode:
authorMartin Liska <mliska@suse.cz>2020-08-11 09:02:44 +0200
committerMartin Liska <mliska@suse.cz>2020-08-11 11:54:12 +0200
commit6c2583c14a8776e88f9834608686f34ec11f717f (patch)
treebd0154c6032bedb667025d3a12e9390fe15a4f78 /gcc/ipa-cp.c
parent84005b8abf9846e4a97e7c76c56acb2e432f2a0a (diff)
downloadgcc-6c2583c14a8776e88f9834608686f34ec11f717f.zip
gcc-6c2583c14a8776e88f9834608686f34ec11f717f.tar.gz
gcc-6c2583c14a8776e88f9834608686f34ec11f717f.tar.bz2
Add debug counter for IPA bits CP.
gcc/ChangeLog: * dbgcnt.def (DEBUG_COUNTER): Add ipa_cp_bits. * ipa-cp.c (ipcp_store_bits_results): Use it when we store known bits for parameters.
Diffstat (limited to 'gcc/ipa-cp.c')
-rw-r--r--gcc/ipa-cp.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/gcc/ipa-cp.c b/gcc/ipa-cp.c
index 10cc595..945a699 100644
--- a/gcc/ipa-cp.c
+++ b/gcc/ipa-cp.c
@@ -123,6 +123,7 @@ along with GCC; see the file COPYING3. If not see
#include "tree-ssa-ccp.h"
#include "stringpool.h"
#include "attribs.h"
+#include "dbgcnt.h"
template <typename valtype> class ipcp_value;
@@ -5788,9 +5789,13 @@ ipcp_store_bits_results (void)
ipa_bits *jfbits;
if (plats->bits_lattice.constant_p ())
- jfbits
- = ipa_get_ipa_bits_for_value (plats->bits_lattice.get_value (),
- plats->bits_lattice.get_mask ());
+ {
+ jfbits
+ = ipa_get_ipa_bits_for_value (plats->bits_lattice.get_value (),
+ plats->bits_lattice.get_mask ());
+ if (!dbg_cnt (ipa_cp_bits))
+ jfbits = NULL;
+ }
else
jfbits = NULL;