[PATCH] [compiler-rt] [asan] Refactor DescribeAddressIfStack to allow reuse for debugging API

Alexey Samsonov vonosmas at gmail.com
Wed Jul 16 13:25:24 PDT 2014


================
Comment at: lib/asan/asan_report.h:36
@@ +35,3 @@
+uptr NumberOfVarsInFrame(const char *frame_descr);
+bool GetFrameVars(const char *frame_descr,
+                  InternalScopedBuffer<StackVarDescr> &vars, uptr n_objects);
----------------
Consider the following interface instead:
  bool ParseFrameDescription(const char *frame_descr, InternalMmapVector<StackVarDescr> *vars);

Note that I passed "vars" by pointer here - we generally don't use non-const references as output parameters in sanitizer runtimes.

http://reviews.llvm.org/D4545






More information about the llvm-commits mailing list