summaryrefslogtreecommitdiff
path: root/compiler-rt/include
diff options
context:
space:
mode:
authorVitaly Buka <vitalybuka@google.com>2018-10-02 00:29:41 +0000
committerVitaly Buka <vitalybuka@google.com>2018-10-02 00:29:41 +0000
commite937c6a746417992ef167c52835d90928c17a30a (patch)
tree229ee83d15b817161e149d6a9eb9d075a0d5782f /compiler-rt/include
parent03ee7b2b387e521efde4724dc51b14e67c9862b4 (diff)
[sanitizer] Include inlined frames into __sanitizer_symbolize_pc output
Summary: Behavior for existing used is not changing as the first line is going to be the same, and it was invalid to try to read more lines. New clients can read until they get empty string. Reviewers: eugenis, morehouse Subscribers: kubamracek, eraman, llvm-commits Differential Revision: https://reviews.llvm.org/D52743
Diffstat (limited to 'compiler-rt/include')
-rw-r--r--compiler-rt/include/sanitizer/common_interface_defs.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler-rt/include/sanitizer/common_interface_defs.h b/compiler-rt/include/sanitizer/common_interface_defs.h
index d11cb1addc2..bf015eb237c 100644
--- a/compiler-rt/include/sanitizer/common_interface_defs.h
+++ b/compiler-rt/include/sanitizer/common_interface_defs.h
@@ -124,6 +124,12 @@ extern "C" {
// Symbolizes the supplied 'pc' using the format string 'fmt'.
// Outputs at most 'out_buf_size' bytes into 'out_buf'.
+ // If 'out_buf' is not empty then output is zero or more non empty C strings
+ // followed by single empty C string. Multiple strings can be returned if PC
+ // corresponds to inlined function. Inlined frames are printed in the order
+ // from "most-inlined" to the "least-inlined", so the last frame should be the
+ // not inlined function.
+ // Inlined frames can be removed with 'symbolize_inline_frames=0'.
// The format syntax is described in
// lib/sanitizer_common/sanitizer_stacktrace_printer.h.
void __sanitizer_symbolize_pc(void *pc, const char *fmt, char *out_buf,