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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2019-04-03
                 CC|                            |law at gcc dot gnu.org,
                   |                            |rguenth at gcc dot gnu.org
     Ever confirmed|0                           |1

--- Comment #3 from Richard Biener <rguenth at gcc dot gnu.org> ---
There is --param max-jump-thread-duplication-stmts but that really only counts
gimple stmts not taking into account their size.  It probably should use


  stmt_count += estimate_num_insns (stmt, &eni_size_weights);

instead of simply doing stmt_count++ and a similar adjustment in
estimate_threading_killed_stmts.

The existing heuristic probably works reasonable for non-asms and
calls with not too many arguments though.

count_stmts_in_block in path isolations has the same issue (basically
everywhere we count stmts we should use the size estimates as that
is better corresponds to the number of assembler instructions which
is what users expect for documented "statements"?)

Reply via email to