[all-commits] [llvm/llvm-project] 30b93d: [Memprof] Adds the option to collect AccessCountHi...

Matthew Weingarten via All-commits all-commits at lists.llvm.org
Wed Jun 26 08:37:45 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 30b93db5476e3ae2efdaba25fb53fcc3c081da77
      https://github.com/llvm/llvm-project/commit/30b93db5476e3ae2efdaba25fb53fcc3c081da77
  Author: Matthew Weingarten <matt at weingarten.org>
  Date:   2024-06-26 (Wed, 26 Jun 2024)

  Changed paths:
    M compiler-rt/include/profile/MIBEntryDef.inc
    M compiler-rt/include/profile/MemProfData.inc
    M compiler-rt/lib/memprof/memprof_allocator.cpp
    M compiler-rt/lib/memprof/memprof_flags.inc
    M compiler-rt/lib/memprof/memprof_mapping.h
    M compiler-rt/lib/memprof/memprof_mibmap.cpp
    M compiler-rt/lib/memprof/memprof_rawprofile.cpp
    M compiler-rt/lib/memprof/memprof_rtl.cpp
    M compiler-rt/lib/memprof/tests/rawprofile.cpp
    M llvm/include/llvm/ProfileData/MIBEntryDef.inc
    M llvm/include/llvm/ProfileData/MemProf.h
    M llvm/include/llvm/ProfileData/MemProfData.inc
    M llvm/include/llvm/ProfileData/MemProfReader.h
    M llvm/lib/ProfileData/MemProfReader.cpp
    M llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
    M llvm/test/Transforms/PGOProfile/Inputs/memprof.exe
    M llvm/test/Transforms/PGOProfile/Inputs/memprof.memprofraw
    M llvm/test/Transforms/PGOProfile/Inputs/memprof.nocolinfo.exe
    M llvm/test/Transforms/PGOProfile/Inputs/memprof.nocolinfo.memprofraw
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_internal_linkage.exe
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_internal_linkage.memprofraw
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_loop_unroll.exe
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_loop_unroll.memprofraw
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_missing_leaf.exe
    M llvm/test/Transforms/PGOProfile/Inputs/memprof_missing_leaf.memprofraw
    M llvm/test/Transforms/PGOProfile/memprof_internal_linkage.ll
    A llvm/test/tools/llvm-profdata/Inputs/basic-histogram.memprofexe
    A llvm/test/tools/llvm-profdata/Inputs/basic-histogram.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/basic.memprofexe
    M llvm/test/tools/llvm-profdata/Inputs/basic.memprofraw
    A llvm/test/tools/llvm-profdata/Inputs/basic_v3.memprofexe
    A llvm/test/tools/llvm-profdata/Inputs/basic_v3.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/buildid.memprofexe
    M llvm/test/tools/llvm-profdata/Inputs/buildid.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/inline.memprofexe
    M llvm/test/tools/llvm-profdata/Inputs/inline.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/multi.memprofexe
    M llvm/test/tools/llvm-profdata/Inputs/multi.memprofraw
    A llvm/test/tools/llvm-profdata/Inputs/padding-histogram.memprofexe
    A llvm/test/tools/llvm-profdata/Inputs/padding-histogram.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/pic.memprofexe
    M llvm/test/tools/llvm-profdata/Inputs/pic.memprofraw
    M llvm/test/tools/llvm-profdata/Inputs/update_memprof_inputs.sh
    A llvm/test/tools/llvm-profdata/memprof-basic-histogram.test
    M llvm/test/tools/llvm-profdata/memprof-basic.test
    A llvm/test/tools/llvm-profdata/memprof-basic_v3.test
    M llvm/test/tools/llvm-profdata/memprof-inline.test
    M llvm/test/tools/llvm-profdata/memprof-multi.test
    A llvm/test/tools/llvm-profdata/memprof-padding-histogram.test
    M llvm/test/tools/llvm-profdata/memprof-pic.test
    M llvm/unittests/ProfileData/MemProfTest.cpp

  Log Message:
  -----------
  [Memprof] Adds the option to collect AccessCountHistograms for memprof. (#94264)

Adds compile time flag -mllvm -memprof-histogram and runtime flag
histogram=true|false to turn Histogram collection on and off. The
-memprof-histogram flag relies on -memprof-use-callbacks=true to work.

Updates shadow mapping logic in histogram mode from having one 8 byte
counter for 64 bytes, to 1 byte for 8 bytes, capped at 255. Only
supports this granularity as of now.

Updates the RawMemprofReader and serializing MemoryInfoBlocks to binary
format, including changing to a new version of the raw binary format
from version 3 to version 4.

Updates creating MemoryInfoBlocks with and without Histograms. When two
MemoryInfoBlocks are merged, AccessCounts are summed up and the shorter
Histogram is removed.

Adds a memprof_histogram test case.

Initial commit for adding AccessCountHistograms up until RawProfile for
memprof



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list