Here, %rax is not preserved by the callee. This means that the debugger cannot figure out the actual call target, and therefore, I believe it cannot safely evaluate entry values in the eventual callee.
Example: callq *%rax may branch to tail_calling_helper, which can tail call eventual_callee; alternatively, callq *%rax can branch to eventual_callee immediately. The debugger simply does not know the call target, so it does not know which function to search for call site parameter infos.
How does gcc handle this? Should llvm attempt to "work backwards" to find a non-clobbered description of the call target (perhaps using the existing describeLoadedValue API)?
When describing an indirect call, llvm may specify a clobbered register as the call target.
Example:
Here, %rax is not preserved by the callee. This means that the debugger cannot figure out the actual call target, and therefore, I believe it cannot safely evaluate entry values in the eventual callee.
Example:
callq *%rax
may branch totail_calling_helper
, which can tail calleventual_callee
; alternatively,callq *%rax
can branch toeventual_callee
immediately. The debugger simply does not know the call target, so it does not know which function to search for call site parameter infos.How does gcc handle this? Should llvm attempt to "work backwards" to find a non-clobbered description of the call target (perhaps using the existing
describeLoadedValue
API)?