1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00
llvm-mirror/lib/ProfileData
Wenlei He 49b058fb15 [ThinLTO][AutoFDO] Fix memory corruption due to race condition from thin backends
Summary:
This commit fixed a race condition from multi-threaded thinLTO backends that causes non-deterministic memory corruption for a data structure used only by AutoFDO with compact binary profile.
GUIDToFuncNameMap, a static data member of type DenseMap in FunctionSamples is used as a per-module mapping from function name MD5 to name string when input AutoFDO profile is in compact binary format. However with ThinLTO, we can have parallel backends modifying and accessing the class static map concurrently. The fix is to make GUIDToFuncNameMap a member of SampleProfileLoader instead of a file static data.

Reviewers: wmi, davidxl, danielcdh

Subscribers: mehdi_amini, inglorion, hiraditya, dexonsmith, llvm-commits

Tags: #llvm

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

llvm-svn: 368596
2019-08-12 17:45:14 +00:00
..
Coverage [Coverage] Speculative fix for r363325 for an older compiler 2019-06-14 00:03:22 +00:00
CMakeLists.txt Revert "test commit" 2019-08-11 05:59:20 +00:00
GCOV.cpp Rename F_{None,Text,Append} to OF_{None,Text,Append}. NFC 2019-08-05 05:43:48 +00:00
InstrProf.cpp Cleanup: llvm::bsearch -> llvm::partition_point after r364719 2019-06-30 11:19:56 +00:00
InstrProfReader.cpp [Profile] Support raw/indexed profiles larger than 4GB 2019-07-09 22:01:04 +00:00
InstrProfWriter.cpp [llvm-profdata] Add overlap command to compute similarity b/w two profile files 2019-04-30 21:19:12 +00:00
LLVMBuild.txt
ProfileSummaryBuilder.cpp [ProfileSummary] Count callsite samples when computing total samples. 2019-04-03 19:54:43 +00:00
SampleProf.cpp [ThinLTO][AutoFDO] Fix memory corruption due to race condition from thin backends 2019-08-12 17:45:14 +00:00
SampleProfReader.cpp
SampleProfWriter.cpp Rename F_{None,Text,Append} to OF_{None,Text,Append}. NFC 2019-08-05 05:43:48 +00:00