[Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. I am not sure this will actually solve the problems you are seeing. This may avoid corrupting the internal DenseMap data structures, but it will not make the algorithm using them actually correct. For example the pattern in `ParseTypeFromDWARF` is: 1. check the "already

[Lldb-commits] [lldb] r335235 - Disable gmodules tests on linux

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 06:55:19 2018 New Revision: 335235 URL: http://llvm.org/viewvc/llvm-project?rev=335235&view=rev Log: Disable gmodules tests on linux These tests are extremely environment-dependent. if the environment is not module-enabled (which is the likely scenario), they won't

[Lldb-commits] [lldb] r335236 - ScriptInterpreterPython cleanup

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 07:09:15 2018 New Revision: 335236 URL: http://llvm.org/viewvc/llvm-project?rev=335236&view=rev Log: ScriptInterpreterPython cleanup Instead of #ifdef-ing the contents of all files in the plugin for all non-python builds, just disable the plugin at the cmake level.

[Lldb-commits] [PATCH] D47991: Improve SBThread's stepping API using SBError parameter.

2018-06-21 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D47991#1137834, @aprantl wrote: > This patch is adding new overloads to SBAPI calls that don't return an > SBError, such as: > > // Old: > void StepOutOfFrame(SBFrame &frame); > // New: > void StepOutOfFrame(SBFrame &frame, SBError &e

[Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D48393#1138989, @labath wrote: > I am not sure this will actually solve the problems you are seeing. This may > avoid corrupting the internal DenseMap data structures, but it will not make > the algorithm using them actually correct. > For

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Zachary Turner via lldb-commits
Related question: Is the laziness done to save memory, startup time, or both? On Thu, Jun 21, 2018 at 7:36 AM Greg Clayton via Phabricator < revi...@reviews.llvm.org> wrote: > clayborg added a comment. > > In https://reviews.llvm.org/D48393#1138989, @labath wrote: > > > I am not sure this will act

[Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Zachary Turner via Phabricator via lldb-commits
zturner added a subscriber: friss. zturner added a comment. Related question: Is the laziness done to save memory, startup time, or both? https://reviews.llvm.org/D48393 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Greg Clayton via lldb-commits
> On Jun 21, 2018, at 7:47 AM, Zachary Turner wrote: > > Related question: Is the laziness done to save memory, startup time, or both? Both. It allows us to fetch only what we need when we need it. Time to break at main.cpp:123 is much quicker. Using LLDB for symbolication is much quicker as

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Zachary Turner via lldb-commits
Performance i get. Gdb is almost unusable for large programs because of how long it takes to load debug info. Do you have specific numbers on memory usage? How much memory (absolute and %) is saved by loading debug info lazily on a relatively large project? On Thu, Jun 21, 2018 at 7:54 AM Greg Cla

[Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Pavel Labath via Phabricator via lldb-commits
labath added a comment. In https://reviews.llvm.org/D48393#1139270, @clayborg wrote: > In https://reviews.llvm.org/D48393#1138989, @labath wrote: > > > I am not sure this will actually solve the problems you are seeing. This > > may avoid corrupting the internal DenseMap data structures, but it

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Greg Clayton via lldb-commits
> On Jun 21, 2018, at 7:58 AM, Zachary Turner wrote: > > Performance i get. Gdb is almost unusable for large programs because of how > long it takes to load debug info. Agreed. With our new DWARF5 tables, we will be even better. Or test on a mac with dSYM files and you will get similar numbe

[Lldb-commits] [lldb] r335244 - Modernize UUID class

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 08:07:43 2018 New Revision: 335244 URL: http://llvm.org/viewvc/llvm-project?rev=335244&view=rev Log: Modernize UUID class Instead of a separate GetBytes + GetByteSize methods I introduce a single GetBytes method returning an ArrayRef. This is NFC cleanup now, but

[Lldb-commits] [PATCH] D48295: [WIP] Implement new methods for handling an error in MI commands.

2018-06-21 Thread Alexander Polyakov via Phabricator via lldb-commits
apolyakov updated this revision to Diff 152310. apolyakov retitled this revision from "[WIP] Implement new ReturnMIStatus method of CMICmdBase class." to "[WIP] Implement new methods for handling an error in MI commands.". apolyakov edited the summary of this revision. apolyakov added a comment.

[Lldb-commits] [lldb] r335246 - Remove UUID::SetFromCString

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 08:24:39 2018 New Revision: 335246 URL: http://llvm.org/viewvc/llvm-project?rev=335246&view=rev Log: Remove UUID::SetFromCString Replace uses with SetFromStringRef. NFC. Modified: lldb/trunk/include/lldb/Utility/UUID.h lldb/trunk/source/API/SBTarget.cpp

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Frédéric Riss via lldb-commits
> On Jun 21, 2018, at 3:18 AM, Pavel Labath via Phabricator > wrote: > > labath added a comment. > > I am not sure this will actually solve the problems you are seeing. This may > avoid corrupting the internal DenseMap data structures, but it will not make > the algorithm using them actuall

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Frédéric Riss via lldb-commits
> On Jun 21, 2018, at 8:03 AM, Pavel Labath via Phabricator > wrote: > > labath added a comment. > > In https://reviews.llvm.org/D48393#1139270, @clayborg wrote: > >> In https://reviews.llvm.org/D48393#1138989, @labath wrote: >> >>> I am not sure this will actually solve the problems you ar

[Lldb-commits] [lldb] r335247 - Fix macos build for r335244

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 08:40:33 2018 New Revision: 335247 URL: http://llvm.org/viewvc/llvm-project?rev=335247&view=rev Log: Fix macos build for r335244 I've made the code accept only 16 byte UUIDs, which is technically not NFC (previously it would also accept 20 byte ones, but use only t

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Greg Clayton via lldb-commits
> On Jun 21, 2018, at 8:32 AM, Frédéric Riss wrote: > > > >> On Jun 21, 2018, at 3:18 AM, Pavel Labath via Phabricator >> wrote: >> >> labath added a comment. >> >> I am not sure this will actually solve the problems you are seeing. This may >> avoid corrupting the internal DenseMap data

[Lldb-commits] [PATCH] D47991: Improve SBThread's stepping API using SBError parameter.

2018-06-21 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. In https://reviews.llvm.org/D47991#1139249, @clayborg wrote: > that is the right way to do it, but we can't overload on return type only. We > will need the old version of the code to be in the API for compatibility. > Overloading by return type will result is two symbo

[Lldb-commits] [PATCH] D48295: [WIP] Implement new methods for handling an error in MI commands.

2018-06-21 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl accepted this revision. aprantl added a comment. I think that works. Assuming that we can use these new helpers in lots of other places :-) https://reviews.llvm.org/D48295 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lis

Re: [Lldb-commits] [lldb] r335236 - ScriptInterpreterPython cleanup

2018-06-21 Thread Jim Ingham via lldb-commits
This change will break building from Xcode without Python. It will take a bunch of monkeying with the project files to achieve the same effect as your cmake changes, and I don't have time to do that right now. I have no problem with changing cmake to just not build the relevant files, but can

[Lldb-commits] [PATCH] D48295: Implement new methods for handling an error in MI commands.

2018-06-21 Thread Alexander Polyakov via Phabricator via lldb-commits
apolyakov updated this revision to Diff 152339. apolyakov retitled this revision from "[WIP] Implement new methods for handling an error in MI commands." to "Implement new methods for handling an error in MI commands.". apolyakov added a comment. Removed usage examples. Also I wanted to ask if s

Re: [Lldb-commits] [lldb] r335236 - ScriptInterpreterPython cleanup

2018-06-21 Thread Pavel Labath via lldb-commits
Sure, I can do that. The though of xcode compatibility did enter my mind briefly while doing this, but I just assumed that XCode always builds with python enabled. I guess I was wrong. Out of curiosity, what are you using the !Python build for? On Thu, 21 Jun 2018 at 18:16, Jim Ingham wrote: > >

Re: [Lldb-commits] [PATCH] D48393: Make DWARFParsing more thread-safe

2018-06-21 Thread Jim Ingham via lldb-commits
Part of gdb's slow startup used to be because it built its indexes manually. But also, while gdb does do lazy ingestion of debug information it's laziness is (or was last time I looked at it) on a compile-unit boundary, so when you stop in a file that includes a many complex types you can end

[Lldb-commits] [PATCH] D48295: Implement new methods for handling an error in MI commands.

2018-06-21 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. Perhaps it's supposed to mark a return argument? The lldb-mi tool uses a (compared to the rest of the project) very odd Windows-like coding style that I'm not particularly familiar with. It would be nice to convert all of it over to just use the plain LLVM style so it i

Re: [Lldb-commits] [lldb] r335236 - ScriptInterpreterPython cleanup

2018-06-21 Thread Greg Clayton via lldb-commits
> On Jun 21, 2018, at 10:30 AM, Pavel Labath via lldb-commits > wrote: > > Sure, I can do that. The though of xcode compatibility did enter my > mind briefly while doing this, but I just assumed that XCode always > builds with python enabled. I guess I was wrong. > > Out of curiosity, what ar

[Lldb-commits] [lldb] r335260 - Partially revert r335236

2018-06-21 Thread Pavel Labath via lldb-commits
Author: labath Date: Thu Jun 21 10:36:32 2018 New Revision: 335260 URL: http://llvm.org/viewvc/llvm-project?rev=335260&view=rev Log: Partially revert r335236 Jim pointed out that XCode has build configurations that build without python and removing the ifdefs around the python code breaks them.

Re: [Lldb-commits] [lldb] r335236 - ScriptInterpreterPython cleanup

2018-06-21 Thread Pavel Labath via lldb-commits
Thanks for the explanation. The ifdef parts should be reverted by r335236. On Thu, 21 Jun 2018 at 18:39, Greg Clayton wrote: > > > > > On Jun 21, 2018, at 10:30 AM, Pavel Labath via lldb-commits > > wrote: > > > > Sure, I can do that. The though of xcode compatibility did enter my > > mind brie

[Lldb-commits] [lldb] r335263 - Fix an issue where DW_OP_deref might be dereferencing a file address. Convert the file address to a load address so this works.

2018-06-21 Thread Greg Clayton via lldb-commits
Author: gclayton Date: Thu Jun 21 10:58:06 2018 New Revision: 335263 URL: http://llvm.org/viewvc/llvm-project?rev=335263&view=rev Log: Fix an issue where DW_OP_deref might be dereferencing a file address. Convert the file address to a load address so this works. https://bugs.llvm.org/show_bug.cg

Re: [Lldb-commits] [lldb] r335263 - Fix an issue where DW_OP_deref might be dereferencing a file address. Convert the file address to a load address so this works.

2018-06-21 Thread Jonas Devlieghere via lldb-commits
Hi Greg, Would you mind adding a test case for this? Thanks, Jonas > On Jun 21, 2018, at 6:58 PM, Greg Clayton via lldb-commits > wrote: > > Author: gclayton > Date: Thu Jun 21 10:58:06 2018 > New Revision: 335263 > > URL: http://llvm.org/viewvc/llvm-project?rev=335263&view=rev > Log: > Fix

[Lldb-commits] [PATCH] D48450: Support CFDictionary

2018-06-21 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere created this revision. JDevlieghere added a reviewer: davide. Add data formatter for CFDictionary. Repository: rL LLVM https://reviews.llvm.org/D48450 Files: packages/Python/lldbsuite/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py packages

Re: [Lldb-commits] [lldb] r335263 - Fix an issue where DW_OP_deref might be dereferencing a file address. Convert the file address to a load address so this works.

2018-06-21 Thread Greg Clayton via lldb-commits
I can't think if an easy way to add a test for this or I would have. Greg > On Jun 21, 2018, at 11:19 AM, Jonas Devlieghere > wrote: > > Hi Greg, > > Would you mind adding a test case for this? > > Thanks, > Jonas > >> On Jun 21, 2018, at 6:58 PM, Greg Clayton via lldb-commits >> wrote:

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Vedant Kumar via Phabricator via lldb-commits
vsk accepted this revision. vsk added a comment. This revision is now accepted and ready to land. LGTM, thanks! Repository: rL LLVM https://reviews.llvm.org/D48450 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cg

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Davide Italiano via Phabricator via lldb-commits
davide added a comment. LGTM. Repository: rL LLVM https://reviews.llvm.org/D48450 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [PATCH] D47992: [lldb-mi] Clean up and update a few MI commands.

2018-06-21 Thread Alexander Polyakov via Phabricator via lldb-commits
apolyakov updated this revision to Diff 152351. apolyakov retitled this revision from "[lldb-mi] Correct error processing in exec-next command." to "[lldb-mi] Clean up and update a few MI commands.". apolyakov edited the summary of this revision. apolyakov added a comment. I didn't committed patc

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. It might be nice to split up the tests a bit. The data formatter tests have a history of testing 1000 things at once and saying "something failed in the this test with 1000 things". It would be nice if we knew that only dictionaries were failing by testing each type in

[Lldb-commits] [PATCH] D47992: [lldb-mi] Clean up and update a few MI commands.

2018-06-21 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. In https://reviews.llvm.org/D47992#1139691, @apolyakov wrote: > I didn't committed patch https://reviews.llvm.org/D48295 yet, so I think if > we change `HandleSBError` handlers from > `std::function` to `std::function` > we'll be able to create anonymous namespace and

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Jonas Devlieghere via Phabricator via lldb-commits
JDevlieghere updated this revision to Diff 152354. JDevlieghere added a comment. - Also test CFDictionaryRef https://reviews.llvm.org/D48450 Files: packages/Python/lldbsuite/test/functionalities/data-formatter/data-formatter-objc/TestDataFormatterObjC.py packages/Python/lldbsuite/test/fun

Re: [Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Jim Ingham via lldb-commits
Yes, I really wish unittest2 allowed non-aborting tests. If you split up all these tests, then you make the testsuite have to build and run some little executable over and over. It would be so nice if there were a way to say: self.startTestBundle() self.assertTrue(something) ... self.

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Jim Ingham via Phabricator via lldb-commits
jingham added subscribers: JDevlieghere, jingham. jingham added a comment. Yes, I really wish unittest2 allowed non-aborting tests. If you split up all these tests, then you make the testsuite have to build and run some little executable over and over. It would be so nice if there were a way t

[Lldb-commits] [PATCH] D47992: [lldb-mi] Clean up and update a few MI commands.

2018-06-21 Thread Alexander Polyakov via Phabricator via lldb-commits
apolyakov added a comment. I don't like creating a new class just for one feature. It looks like only 3 commands use that code, so maybe we should let it be at it is? https://reviews.llvm.org/D47992 ___ lldb-commits mailing list lldb-commits@lists.

[Lldb-commits] [lldb] r335271 - [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Jonas Devlieghere via lldb-commits
Author: jdevlieghere Date: Thu Jun 21 12:13:47 2018 New Revision: 335271 URL: http://llvm.org/viewvc/llvm-project?rev=335271&view=rev Log: [DataFormatter] Add CFDictionary data formatter Add data formatter for NSCFDictionary/CFDictionaryRef. Differential revision: https://reviews.llvm.org/D48450

[Lldb-commits] [PATCH] D48450: [DataFormatter] Add CFDictionary data formatter

2018-06-21 Thread Jonas Devlieghere via Phabricator via lldb-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL335271: [DataFormatter] Add CFDictionary data formatter (authored by JDevlieghere, committed by ). Changed prior to commit: https://reviews.llvm.org/D48450?vs=152354&id=152359#toc Repository: rL LLVM

[Lldb-commits] [PATCH] D47992: [lldb-mi] Clean up and update a few MI commands.

2018-06-21 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. fine with leaving it as is if needed as well https://reviews.llvm.org/D47992 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [PATCH] D48463: Prevent dead locking when calling PrintAsync

2018-06-21 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. While working on the `expr` completion, I've encountered the issue that sometimes lldb deadlocks when doing input/output. The underlying cause for this is that we seem to expect that we can always call `Debugger::PrintAsync` from any point of lldb and that this

[Lldb-commits] [PATCH] D48463: Prevent dead locking when calling PrintAsync

2018-06-21 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor added subscribers: friss, jingham. teemperor added a comment. Not sure who should review this, but maybe Fred or Jim know :) https://reviews.llvm.org/D48463 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cg

[Lldb-commits] [PATCH] D48463: Prevent dead locking when calling PrintAsync

2018-06-21 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor updated this revision to Diff 152402. teemperor added a comment. - Small code style adjustment. https://reviews.llvm.org/D48463 Files: include/lldb/Core/Debugger.h source/Core/Debugger.cpp source/Core/IOHandler.cpp Index: source/Core/IOHandler.cpp ==

[Lldb-commits] [PATCH] D48463: Prevent dead locking when calling PrintAsync

2018-06-21 Thread Jim Ingham via Phabricator via lldb-commits
jingham added a reviewer: clayborg. jingham added a comment. The IOHandlers are Greg's construct. He's likely the best person to review this. https://reviews.llvm.org/D48463 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.ll

[Lldb-commits] [PATCH] D48465: Added initial code completion support for the `expr` command

2018-06-21 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor created this revision. teemperor added a reviewer: jingham. Herald added subscribers: JDevlieghere, aprantl. This patch adds initial code completion support for the `expr` command. We now have a completion handler in the expression CommandObject that essentially just attempts to parse t

[Lldb-commits] [PATCH] D48465: Added initial code completion support for the `expr` command

2018-06-21 Thread Raphael Isemann via Phabricator via lldb-commits
teemperor added a comment. Note that there are two parent revisions. One is just refactoring because I needed to reuse some of the parsing setup code. The other patch (the AsyncPrint one) fixes a deadlock that affected this patch. The deadlock can be reproduces by starting lldb, going to a rand

[Lldb-commits] [PATCH] D48465: Added initial code completion support for the `expr` command

2018-06-21 Thread Adrian Prantl via Phabricator via lldb-commits
aprantl added a comment. Very nice! Comment at: include/lldb/Expression/ExpressionParser.h:52 + virtual bool Complete(StringList &matches, unsigned line, unsigned pos, +unsigned typed_pos) = 0; Could you add a Doxygen comment? =

[Lldb-commits] [lldb] r335313 - Remove dead code

2018-06-21 Thread Frederic Riss via lldb-commits
Author: friss Date: Thu Jun 21 17:22:50 2018 New Revision: 335313 URL: http://llvm.org/viewvc/llvm-project?rev=335313&view=rev Log: Remove dead code Our DWARF parsing code had a workaorund for Objective-C "self" not being marked as artifial by the compiler. Clang has been doing this since 2010, s