[Bug middle-end/126899] backward threader rejects joiner-style threads on statement count that DOM can thread

"aldyh at gcc dot gnu.org via Gcc-bugs" <[email protected]>
Newsgroups gmane.comp.gcc.bugs
Message-ID <[email protected]/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=126899

--- Comment #3 from Aldy Hernandez <aldyh at gcc dot gnu.org> ---
BTW, found another one that fails because the cost models differ:
gcc.dg/harden-cfr-pr111943.c (with --param=dom-jump-threading=0).  This one
pins --param=max-jump-thread-duplication-stmts=0, and the backward threader
refuses to thread even paths that copy zero statements (its estimate is
compared with >=, so 0 * 2 >= 0 fails every path), while DOM's forward threader
counts the statements it would actually copy and allows the thread.

From threadfull1:

Overall: 0 insns
    FAIL: Did not thread around loop and would copy too many statements.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.