[Lldb-commits] [PATCH] D42336: Fix memory leaks in TestArm64InstEmulation

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: jasonmolenda. Herald added subscribers: kristof.beyls, javed.absar, aemerson. We never delete the created instances, so those test fail with the memory sanitizer. https://reviews.llvm.org/D42336 Files: unittests/UnwindAssembly/Inst

[Lldb-commits] [PATCH] D42338: Fix unrepresentable float value in ScalarTest

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: uweigand. float can't represent the given value in the literal, so we get this UB error: `runtime error: 1.23457e+48 is outside the range of representable values of type 'float'`. The test seems to not rely on this specific value, so l

[Lldb-commits] [PATCH] D42339: Fix uninitialized variable in GoParser

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: ribrdb. teemperor edited the summary of this revision. `m_last_tok` isn't initialized anywhere before it's used the first time (most likely in the `GoParser::Rule::error` method), which causes most of the GoParser tests to fail with sa

[Lldb-commits] [PATCH] D42340: [modules] Fix missing includes/typo in LLDB's includes. [NFC]

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: aprantl. This patch adds missing includes to the LLDB headers inside `include/` as a first step of building LLDB's source with C++ modules. Includes in lldb seem to be commented if the reason for the include is not obvious (`// for add

Re: [Lldb-commits] [PATCH] D42340: [modules] Fix missing includes/typo in LLDB's includes. [NFC]

2018-01-20 Thread Zachary Turner via lldb-commits
The comments were automatically added a long time ago when I tried to run IWYU on LLDB source code. I don't think you need to maintain them. On Sat, Jan 20, 2018 at 2:25 PM Raphael Isemann via Phabricator via lldb-commits wrote: > teemperor created this revision. > teemperor added a reviewer: a

[Lldb-commits] [PATCH] D42340: [modules] Fix missing includes/typo in LLDB's includes. [NFC]

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor updated this revision to Diff 130784. teemperor added a comment. - Ditched the commented includes. https://reviews.llvm.org/D42340 Files: include/lldb/Core/LoadedModuleInfoList.h include/lldb/Core/ThreadSafeDenseSet.h include/lldb/Core/ThreadSafeValue.h include/lldb/DataFormat

[Lldb-commits] [PATCH] D40283: lldb: Use the DWARF linkage name when importing C++ methods

2018-01-20 Thread Nelson Elhage via Phabricator via lldb-commits
nelhage added a comment. I did a little bit of looking into performance implications today. It looks like `DWARFASTParserClang::ParseTypeFromDWARF` is only called lazily as symbols are needed, which alleviates some of my concerns, and also makes it a bit trickier to construct a convenient bench

[Lldb-commits] [PATCH] D42340: [modules] Fix missing includes/typo in LLDB's includes. [NFC]

2018-01-20 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl accepted this revision. aprantl added a comment. This revision is now accepted and ready to land. Thanks! This looks generally good/useful as a cleanup, too. Comment at: include/lldb/Core/ThreadSafeDenseSet.h:49 void Clear() { -stds::lock_guard<_MutexType> guard(

[Lldb-commits] [PATCH] D42340: [modules] Fix missing includes/typo in LLDB's includes. [NFC]

2018-01-20 Thread Zachary Turner via Phabricator via lldb-commits
zturner added inline comments. Comment at: include/lldb/Core/ThreadSafeDenseSet.h:49 void Clear() { -stds::lock_guard<_MutexType> guard(m_mutex); +std::lock_guard<_MutexType> guard(m_mutex); m_set.clear(); aprantl wrote: > Out of curiosity: Why/ho

[Lldb-commits] [PATCH] D40283: lldb: Use the DWARF linkage name when importing C++ methods

2018-01-20 Thread Davide Italiano via Phabricator via lldb-commits
davide added a comment. In https://reviews.llvm.org/D40283#983057, @nelhage wrote: > I did a little bit of looking into performance implications today. It looks > like `DWARFASTParserClang::ParseTypeFromDWARF` is only called lazily as > symbols are needed, which alleviates some of my concerns,

[Lldb-commits] [PATCH] D40283: lldb: Use the DWARF linkage name when importing C++ methods

2018-01-20 Thread Nelson Elhage via Phabricator via lldb-commits
nelhage added a comment. Yes, I will need someone else to commit on my behalf -- I don't have commit access. https://reviews.llvm.org/D40283 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/ll

[Lldb-commits] [PATCH] D42345: Make loop counter unsigned in SymbolFilePDB::GetCompileUnitIndex

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. This fixes a clang warning. https://reviews.llvm.org/D42345 Files: source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp Index: source/Plugins/SymbolFile/PDB/SymbolFilePDB.cpp === --- source/Plugins/S

[Lldb-commits] [PATCH] D42346: Fix use after free in DiskFilesOrDirectories

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: zturner. We copy the local variable `Resolved` into `Storage` to keep it around. However, we then still let the `SearchDir` ref point to `Resolved` which then is used to access the already freed memory later on. With this patch we poin

[Lldb-commits] [PATCH] D42347: Fix memory leaks in MinidumpParserTest

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: dvlahovski. We never delete the allocated RegisterContext objects, causing those tests to fail with enabled memory sanitizer. https://reviews.llvm.org/D42347 Files: unittests/Process/minidump/MinidumpParserTest.cpp Index: unittes

[Lldb-commits] [PATCH] D42348: Prevent unaligned memory read in parseMinidumpString

2018-01-20 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added reviewers: dvlahovski, zturner. It's possible to hit an unaligned memory read when reading `source_length` as the `data` array is only aligned with 2 bytes (it's actually a UTF16 array). This patch memcpy's `source_length` into a local variable to