[PATCH] New options for asan-symbolizer script: set cross-compile prefix, set path to sysroot, print help message

Alexander Potapenko glider at google.com
Fri Sep 19 04:18:38 PDT 2014


================
Comment at: lib/asan/scripts/asan_symbolize.py:27
@@ -23,1 +26,3 @@
+fix_filename_patterns = None
+logfile = None
 
----------------
earthdok wrote:
> Why are we adding more global state? Why not make those into arguments of SymbolizationLoop's constructor?
> 
> If we *must* have them as globals, why not give them sane initial values? After this change, if I want to import SymbolizationLoop from this module (as we do in more than one place in Chromium), I have to do this:
> 
> import asan_symbolize
> asan_symbolize.logfile = sys.stdin
> symbolization_loop = asan_symbolize.SymbolizationLoop(...)
Agreed. Let us try to remove global state as much as possible.

http://reviews.llvm.org/D4703






More information about the llvm-commits mailing list