> Yes, this looks OK. Inliner coul also take care to turn the master clone > into unanalyzed node as remove_unreachable_nodes would, but I do not think > it is worth the effort. Please put the loop later in the function so it > does not slow things down unnecesarily (there are often many inline clones)
If you're concerned about efficiency, I can move it into clone_inlined_nodes itself instead: if (duplicate) { /* We may eliminate the need for out-of-line copy to be output. In that case just go ahead and re-use it. This is not just an memory optimization. Making offline copy of fuction disappear from the program will improve future decisions on inlining. */ if (!e->callee->callers->next_caller /* Recursive inlining never wants the master clone to be overwritten. */ && update_original && can_remove_node_now_p (e->callee, e)) i.e. I can set update_original to false just before the above test, that would probably be sufficient to fix the bug. -- Eric Botcazou