]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/btrace.c
btrace: update tail call heuristic
authorMarkus Metzger <markus.t.metzger@intel.com>
Tue, 12 Jan 2016 15:05:15 +0000 (16:05 +0100)
committerMarkus Metzger <markus.t.metzger@intel.com>
Fri, 28 Oct 2016 08:57:16 +0000 (10:57 +0200)
commit2dfdb47abd418aac05380482093a87e763ab0a05
treee5e8b718ce7ea35d2e27223eb66166f91bbce433
parentb61ce85cc54bf4acc86714cacd10d6f9f7e89d1b
btrace: update tail call heuristic

An unconditional jump to the start of a function typically indicates a tail
call.

If we can't determine the start of the function at the destination address, we
used to treat it as a tail call, as well.  This results in lots of tail calls
for code for which we don't have symbol information.

Restrict the heuristic to only consider jumps as tail calls that switch
functions in the case where we can't determine the start of a function.  This
effectively disables tail call detection for code without symbol information.

gdb/
* btrace.c (ftrace_update_function): Update tail call heuristic.
gdb/ChangeLog
gdb/btrace.c