https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120358

--- Comment #29 from Alexander Monakov <amonakov at gcc dot gnu.org> ---
The above is bisectable on the 'match' dbgcnt, which ends on this transform in
vrp1:

Folding statement: if (e_137 != n_142)
 Registering value_relation (e_137 != n_142) on (33->35)
 Registering value_relation (e_137 == n_142) on (33->34)

Visiting conditional with predicate: if (e_137 != n_142)

With known ranges
        e_137: [prange] const char16_t * [1, +INF]      n_142: [prange] const
char16_t * VARYING

Predicate evaluates to: DON'T KNOW
Matching expression match.pd:2934, gimple-match-8.cc:90
Matching expression match.pd:2938, gimple-match-4.cc:77
***dbgcnt: upper limit 22638 reached for match.***
Applying pattern match.pd:7956, gimple-match-9.cc:4682
gimple_simplified to if (1 != 0)
Folded into: if (1 != 0)

which looks highly suspicious as it eliminates this branch:

  # PT = nonlocal escaped null const-pool { D.189389 } (escaped)
  # USE = nonlocal escaped null const-pool { D.189389 } (escaped)
  n_142 = QtPrivate::qustrchr (D.204906, 46);
  D.204906 ={v} {CLOBBER(eos)};
  if (e_137 != n_142)
    goto <bb 31>; [98.33%]
  else
    goto <bb 30>; [1.67%]


above that, for e_137 we have

  # PT =
  e_137 = _130 + _136;

and for _130

  # PT = null
  _130 = str.m_data;

which is wrong?

Reply via email to