[all-commits] [llvm/llvm-project] 8f778b: [sanitizer_common] Add facility to get the full re...

Teresa Johnson via All-commits all-commits at lists.llvm.org
Thu Nov 19 09:19:41 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 8f778b283de5757fa8bf4da255a3a34b3a5cdbd3
      https://github.com/llvm/llvm-project/commit/8f778b283de5757fa8bf4da255a3a34b3a5cdbd3
  Author: Teresa Johnson <tejohnson at google.com>
  Date:   2020-11-19 (Thu, 19 Nov 2020)

  Changed paths:
    M compiler-rt/include/sanitizer/common_interface_defs.h
    M compiler-rt/lib/sanitizer_common/sanitizer_common_interface.inc
    M compiler-rt/lib/sanitizer_common/sanitizer_file.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_file.h
    M compiler-rt/lib/sanitizer_common/sanitizer_fuchsia.cpp
    M compiler-rt/lib/sanitizer_common/sanitizer_interface_internal.h
    A compiler-rt/test/sanitizer_common/TestCases/Posix/sanitizer_set_report_path_test.cpp

  Log Message:
  -----------
  [sanitizer_common] Add facility to get the full report path

Add a new interface __sanitizer_get_report_path which will return the
full path to the report file if __sanitizer_set_report_path was
previously called (otherwise it returns null). This is useful in
particular for memory profiling handlers to access the path which
was specified at compile time (and passed down via
__memprof_profile_filename), including the pid added to the path when
the file is opened.

There wasn't a test for __sanitizer_set_report_path, so I added one
which additionally tests the new interface.

Differential Revision: https://reviews.llvm.org/D91765




More information about the All-commits mailing list