diff options
| author | Fangrui Song <maskray@google.com> | 2020-07-22 18:46:57 -0700 |
|---|---|---|
| committer | Fangrui Song <maskray@google.com> | 2020-07-22 18:49:25 -0700 |
| commit | 99ad956fdaee5398fdcf46fa49cb433cf52dc461 (patch) | |
| tree | dbc524a9ad16244d337a923fd9d6c34327cf8869 /llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp | |
| parent | 9e4ab439c2ee415ef0f7b873ac25bbc63c2a4657 (diff) | |
[PGO] Don't call calloc(0, sizeof(ValueProfNode *))
A malloc implementation may return a pointer to some allocated space. It is
undefined for libclang_rt.profile- to access the object - which actually happens
in instrumentTargetValueImpl, where ValueCounters[CounterIndex] may access a
ValueProfNode (from another allocated object) and crashes when the code accesses
the object referenced by CurVNode->Next.
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeAnalyzer.cpp')
0 files changed, 0 insertions, 0 deletions
