Automatic cost center insertion on overloaded bindings and overloaded call sites
Motivation
It should be possible to automatically add cost centers to overloaded bindings and overloaded call sites, after optimization. This would enable easier detection of overloaded calls that "survive" optimization. It could also help users determine which overloaded calls are most expensive, obviating candidates for specialization.
Proposal
Add two new cost center insertion methods enabled via -fprof-late-overloaded
and -fprof-late-overloaded-calls
. The former adding cost centers to top-level overloaded bindings, the latter adding cost centers to call sites involving dictionary arguments.