bpo-34861: Make cumtime the default sorting key for cProfile by DanielNoord · Pull Request #31929 · python/cpython
Note: This does not fully resolve bpo-34861, but only tackles one of the two issues identified.
This is a resubmit of #9655 and some of the changes that were discussed there.
@pablogsal I'm tagging you since you basically asked for the PR to be split and said that this change looked good. Sorry if the ping is uncalled for.
I have also updated the documentation to better reflect what a new call to cProfile.run('re.compile("foo|bar")') would look like. This also shows that we no longer sort on standard name.