Revert "[MemProf] Memprof profile matching and annotation"
authorTeresa Johnson <tejohnson@google.com>
Thu, 22 Sep 2022 22:11:01 +0000 (15:11 -0700)
committerTeresa Johnson <tejohnson@google.com>
Thu, 22 Sep 2022 23:08:03 +0000 (16:08 -0700)
commit794b7ea960ccc3222f2af582efadbc5e5c464292
tree626705b77993edc76b3738a36d106290483d48ae
parentf7d674910d2dadae209f4a93373481c450f089f7
Revert "[MemProf] Memprof profile matching and annotation"

This reverts commit a212d8da94d08e229aa8d65283e4b116310bba10, and follow
on fixes 0cd6763fa93159b84d70a5bb602c24996acaafaa,
e9ff53d42feac7fc157718523275619a8106f2f3, and
37c6a25e9ab230e5e21fa34e246d9fec55275df0.

After re-reading the documentation for hash_combine, I don't think this
is the appropriate hash function to use for computing the hash to use as
a stack id in the metadata, since it is not guaranteed to produce stable
values across executions. I have not hit this problem, but plan to
switch to using an MD5 hash. I am hitting an issue with one of the bots
(https://lab.llvm.org/buildbot/#/builders/171/builds/20732)
where the values produced are only the lower 32 bits of the expected
hash values, however, which I assume is related to the implementation of
hash_combine and hash_code.

I believe I fixed all of the other bot failures with the follow on fixes,
which I'll merge into the new version before reapplying.
13 files changed:
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/CodeGen/Inputs/memprof.exe [deleted file]
clang/test/CodeGen/Inputs/memprof.memprofraw [deleted file]
clang/test/CodeGen/memprof.cpp [deleted file]
llvm/include/llvm/Analysis/MemoryBuiltins.h
llvm/include/llvm/ProfileData/InstrProfReader.h
llvm/lib/Analysis/MemoryBuiltins.cpp
llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp
llvm/test/Transforms/PGOProfile/Inputs/memprof.exe [deleted file]
llvm/test/Transforms/PGOProfile/Inputs/memprof.memprofraw [deleted file]
llvm/test/Transforms/PGOProfile/Inputs/memprof_pgo.profraw [deleted file]
llvm/test/Transforms/PGOProfile/memprof.ll [deleted file]
llvm/test/Transforms/PGOProfile/memprofmissingfunc.ll [deleted file]