summaryrefslogtreecommitdiff
path: root/lib/sanitizer_common/sanitizer_symbolizer.h
diff options
context:
space:
mode:
authorAlexey Samsonov <vonosmas@gmail.com>2014-07-26 01:37:23 +0000
committerAlexey Samsonov <vonosmas@gmail.com>2014-07-26 01:37:23 +0000
commiteaa8710699fffec3e60d2f6bf11ca4109fe387da (patch)
treec82adacda8a0125758f91675e085f2007b9f0e17 /lib/sanitizer_common/sanitizer_symbolizer.h
parentd195654929d6e1f31c2c6bc1fa3b3ba57ba22d04 (diff)
downloadcompiler-rt-eaa8710699fffec3e60d2f6bf11ca4109fe387da.tar.gz
[Sanitizer] Simplify Symbolizer creation interface.
Get rid of Symbolizer::Init(path_to_external) in favor of thread-safe Symbolizer::GetOrInit(), and use the latter version everywhere. Implicitly depend on the value of external_symbolizer_path runtime flag instead of passing it around manually. No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@214005 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/sanitizer_common/sanitizer_symbolizer.h')
-rw-r--r--lib/sanitizer_common/sanitizer_symbolizer.h14
1 files changed, 3 insertions, 11 deletions
diff --git a/lib/sanitizer_common/sanitizer_symbolizer.h b/lib/sanitizer_common/sanitizer_symbolizer.h
index 7057a89e2..801afbf9c 100644
--- a/lib/sanitizer_common/sanitizer_symbolizer.h
+++ b/lib/sanitizer_common/sanitizer_symbolizer.h
@@ -78,14 +78,9 @@ class Symbolizer {
/// Returns platform-specific implementation of Symbolizer, or null if not
/// initialized.
static Symbolizer *GetOrNull();
- /// Returns platform-specific implementation of Symbolizer. Will
- /// automatically initialize symbolizer as if by calling Init(0) if needed.
+ /// Initialize and return platform-specific implementation of symbolizer
+ /// (if it wasn't already initialized).
static Symbolizer *GetOrInit();
- /// Initialize and return the symbolizer, given an optional path to an
- /// external symbolizer. The path argument is only required for legacy
- /// reasons as this function will check $PATH for an external symbolizer. Not
- /// thread safe.
- static Symbolizer *Init(const char* path_to_external = 0);
// Fills at most "max_frames" elements of "frames" with descriptions
// for a given address (in all inlined functions). Returns the number
// of descriptions actually filled.
@@ -122,10 +117,7 @@ class Symbolizer {
private:
/// Platform-specific function for creating a Symbolizer object.
- static Symbolizer *PlatformInit(const char *path_to_external);
- /// Create a symbolizer and store it to symbolizer_ without checking if one
- /// already exists. Not thread safe.
- static Symbolizer *CreateAndStore(const char *path_to_external);
+ static Symbolizer *PlatformInit();
/// Initialize the symbolizer in a disabled state. Not thread safe.
static Symbolizer *Disable();