Re: [lldb-dev] Bug in CommandObjectFrameVariable::DoExecute()

2016-11-18 Thread Enrico Granata via lldb-dev
On 11/18/16 3:55 PM, Zachary Turner via lldb-dev wrote: On line 708 of CommandObjectFrame.cpp, I'm looking at this code: options.SetRootValueObjectName(name_cstr); This code occurs inside the else block of an if/else. name_cstr is declared prior to the if/else block and initialized to nullptr

[lldb-dev] Code ownership resignation

2016-11-16 Thread Enrico Granata via lldb-dev
Hi, as some of you likely already know I will be leaving Apple at the end of November This career change also means I will not be as involved in lldb as I have been in the past. It also means I don't believe I would be doing the best interest of the community by serving as a code owner. For t

Re: [lldb-dev] LLDB support for python scripts in ELF section, like .debug_gdb_scripts in GDB

2016-10-20 Thread Enrico Granata via lldb-dev
LLDB has a similar feature, except: a) it tries to load python scripts from dSYM bundles. If you have debug info stored in foo.dSYM, it will look for foo.dSYM/Contents/Resources/Python/foo.py As far as I know, dSYMs only exist on Apple systems, so clearly you would need to design something else

Re: [lldb-dev] Connecting to lldb-rpc-server

2016-10-07 Thread Enrico Granata via lldb-dev
It is my understanding that this is not possible in the current architecture > On Oct 7, 2016, at 11:55 AM, Rex Fenley wrote: > > We expect to have a rich user experience as this tool progresses, using > Python to generate UI will limit our development process. It would be much > simpler if we

Re: [lldb-dev] Connecting to lldb-rpc-server

2016-10-07 Thread Enrico Granata via lldb-dev
I can see a couple of avenues for your use case: - you can write custom LLDB commands (obligatory reference: http://lldb.llvm.org/python-reference.html ) and have your users type these via the console instead of by clicking buttons - you could write a

Re: [lldb-dev] Connecting to lldb-rpc-server

2016-10-07 Thread Enrico Granata via lldb-dev
I am gonna echo Kate's question, but delve one level deeper Why do you want to send commands to LLDB from a different process? We have a bunch of different extension points in LLDB, so it's possible that what you're trying to do is actually already possible > On Oct 7, 2016, at 10:41 AM, Rex Fe

Re: [lldb-dev] RFC: Break/Watchpoint refactor

2016-09-27 Thread Enrico Granata via lldb-dev
> On Sep 27, 2016, at 1:09 PM, Daniel Austin Noland via lldb-dev > wrote: > > * Prefer explicitly deleted copy ctor / assignments over multiline macro > DISALLOW_COPY_AND_ASSIGN Why not just move DISALLOW_COPY_AND_ASSIGN over to using =delete ? That seems like a trivial change.. Thanks, -

Re: [lldb-dev] LLDB Evolution - Final Form

2016-09-19 Thread Enrico Granata via lldb-dev
> On Sep 19, 2016, at 2:31 PM, Zachary Turner via lldb-dev > wrote: > > > > On Mon, Sep 19, 2016 at 2:20 PM Mehdi Amini > wrote: > > > I’m surprise by your aversion to assertions, what is your suggested > alternative? Are you expecting to check and handle eve

Re: [lldb-dev] LLDB Evolution - Final Form

2016-09-19 Thread Enrico Granata via lldb-dev
A few remarks > On Sep 19, 2016, at 1:18 PM, Zachary Turner via lldb-dev > wrote: > > Following up with Kate's post from a few weeks ago, I think the dust has > settled on the code reformat and it went over pretty smoothly for the most > part. So I thought it might be worth throwing out some

Re: [lldb-dev] lldb type summary provider - SBProcess is invalid

2016-09-13 Thread Enrico Granata via lldb-dev
> On Sep 13, 2016, at 10:02 AM, Lei Kong via lldb-dev > wrote: > > I wrote a lldb type summary provider for wstring with 16bit wchar on Ubuntu > 16.04. > > Things work fine if I manually do the following in lldb: > > (lldb) script import mytypes > (lldb) type summary add -F mytypes.wstring_S

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-20 Thread Enrico Granata via lldb-dev
> On Apr 20, 2016, at 3:08 PM, Jeffrey Tan wrote: > > Hi Enrico, > > Instead of trying function-evaluation c_str(), I decided to decode the > information from fbstring_core fields. I got it working but have two > questions for it. > > type summary add -F data_formatter.folly_string_formatter

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-13 Thread Enrico Granata via lldb-dev
In theory what you're doing looks like it should be supported. I am not sure why your example is failing the way it is. Is your variable a global maybe? Also, using the variable name is the wrong thing to do. If you have a class with a std::string member, the name is going to return the wrong t

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-13 Thread Enrico Granata via lldb-dev
> On Apr 13, 2016, at 10:11 AM, Jeffrey Tan wrote: > > One quick question: do we support getting type summary string from inferior > method call? No - for that you are going to need to write a Python formatter. Running code in formatters is a risky endeavor for a bunch of reasons, so it is b

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-07 Thread Enrico Granata via lldb-dev
> On Apr 6, 2016, at 7:31 PM, Jeffrey Tan wrote: > > Thanks Enrico. This is very detailed! I will take a look. > Btw: originally, I was hoping that data formatter can be added without > changing the source code. Like giving a xml/json format file telling lldb the > memory layout/structure of

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-07 Thread Enrico Granata via lldb-dev
> On Apr 7, 2016, at 9:51 AM, Jim Ingham wrote: > > I don't think Enrico was suggesting that we maintain a bunch of third party > data formatters in the lldb source base. That depends - if this std::string implementation is part of a publicly available STL implementation, it might make sens

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-04-06 Thread Enrico Granata via lldb-dev
> On Apr 5, 2016, at 2:42 PM, Jeffrey Tan wrote: > > Hi Enrico, > > Any suggestion/example how to add a data formatter for our own STL string? > From the output below I can see we are using our own "fbstring_core" which I > assume I need to write a type summary for this type: > > frame varia

Re: [lldb-dev] UnicodeDecodeError for serialize SBValue description

2016-03-28 Thread Enrico Granata via lldb-dev
This is kind of orthogonal to your problem, but the reason why you are not seeing the kind of simplified printing Greg is suggesting, is because your std::string doesn’t look like any of the kinds we recognize Specifically, LLDB data formatters work by matching against type names, and once they

Re: [lldb-dev] [Bug 27020] New: "command alias r run" causes an assert

2016-03-22 Thread Enrico Granata via lldb-dev
rom: egran...@apple.com [mailto:egran...@apple.com] > Sent: Tuesday, March 22, 2016 4:14 PM > To: Ted Woodward > Cc: LLDB > Subject: Re: [lldb-dev] [Bug 27020] New: "command alias r run" causes an > assert > > Ted, > I think this is fixed by r264096 > >

Re: [lldb-dev] [Bug 27020] New: "command alias r run" causes an assert

2016-03-22 Thread Enrico Granata via lldb-dev
Ted, I think this is fixed by r264096 Can you try and make sure it works for you? > On Mar 21, 2016, at 2:51 PM, Enrico Granata via lldb-dev > wrote: > > >> On Mar 21, 2016, at 2:27 PM, via lldb-dev > <mailto:lldb-dev@lists.llvm.org>> wrote: >> >>

Re: [lldb-dev] [Bug 27020] New: "command alias r run" causes an assert

2016-03-21 Thread Enrico Granata via lldb-dev
> On Mar 21, 2016, at 2:27 PM, via lldb-dev wrote: > > Bug ID27020 > Summary "command alias r run" causes an assert > Product lldb > Version unspecified > Hardware PC > OSWindows NT > StatusNEW >

Re: [lldb-dev] something just toasted the test suite on OS X

2016-01-25 Thread Enrico Granata via lldb-dev
Should be reverted in 258791. Sent from my iPhone > On Jan 25, 2016, at 8:54 PM, Zachary Turner wrote: > > sorry, yea I stuck around for a while after that patch waiting for emails, > but nothing came through. Please revert in the meantime, I'll work on a fix > tomorrow. > >> On Mon, Jan 25

Re: [lldb-dev] something just toasted the test suite on OS X

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 6:48 PM, Todd Fiala via lldb-dev > wrote: > > Not sure exactly what it is, but all the tests are failing due to some bad > assumptions of unicode vs. str on Python 2 vs. 3 if I had to guess. > Author: zturner Date: Mon Jan 25 18:59:42 2016 New Revision: 258759 URL: htt

Re: [lldb-dev] Selectively disabling value formatter

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 4:48 PM, Siva Chandra wrote: > > I think this one: > http://llvm.org/viewvc/llvm-project?view=revision&revision=240578 > > > On Mon, Jan 25, 2016 at 4:34 PM, Enrico Granata >

Re: [lldb-dev] Selectively disabling value formatter

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 4:09 PM, Vadim Chugunov via lldb-dev > wrote: > > lldb-340.4.119 (OSX 10.11.3) > > On Mon, Jan 25, 2016 at 3:42 PM, Siva Chandra > wrote: > On Mon, Jan 25, 2016 at 12:23 AM, Vadim Chugunov via lldb-dev > mailto:lldb-dev@lists.llvm.org>> wro

Re: [lldb-dev] Selectively disabling value formatter

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 4:04 PM, Vadim Chugunov wrote: > > > > On Mon, Jan 25, 2016 at 3:31 PM, Enrico Granata > wrote: > >> >> Whose IsSynthetic() is supposed to return True,- the parent's or the >> child's? > > What do you mean with this? > The model is that y

Re: [lldb-dev] Selectively disabling value formatter

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 3:20 PM, Vadim Chugunov wrote: > > On Mon, Jan 25, 2016 at 11:04 AM, Enrico Granata > wrote: > >> On Jan 25, 2016, at 12:23 AM, Vadim Chugunov via lldb-dev >> mailto:lldb-dev@lists.llvm.org>> wrote: >> >> Hi, >> If I have an SBValue for an obj

Re: [lldb-dev] Selectively disabling value formatter

2016-01-25 Thread Enrico Granata via lldb-dev
> On Jan 25, 2016, at 12:23 AM, Vadim Chugunov via lldb-dev > wrote: > > Hi, > If I have an SBValue for an object whose type has a formatter enabled for it, > is there a way to detect this via the Python API, and if so, request an > "unmodified" view of the object? There definitely is a way

[lldb-dev] Fwd: Enrico abroad for 2 weeks

2015-12-21 Thread Enrico Granata via lldb-dev
Sending again to right audience since I suspect most LLVM folks don’t really care :-) > Begin forwarded message: > > From: Enrico Granata > Subject: Enrico abroad for 2 weeks > Date: December 21, 2015 at 3:29:51 PM PST > To: llvm-...@lists.llvm.org > > Hi, > some of you may know this already -

Re: [lldb-dev] Benchmark tests

2015-12-09 Thread Enrico Granata via lldb-dev
Historically I would do $ ./dotest.py +b but I am not strongly attached to that workflow - it's just what I learnt the first time I needed to run one Sent from my iPhone > On Dec 9, 2015, at 2:08 PM, Zachary Turner wrote: > > When you do run the benchmark tests, what command line options do

Re: [lldb-dev] Benchmark tests

2015-12-09 Thread Enrico Granata via lldb-dev
I have actually added a few benchmark tests recently. We admittedly are not that good with running those tests ever (because they're not run by default most likely - and I do wonder if some of them would take a long time to run.. I don't think I have ever run the full set, just my own as I incre

Re: [lldb-dev] [Lldb-commits] [lldb] r253317 - Add Pythonic language binding wrapper generation script.

2015-11-18 Thread Enrico Granata via lldb-dev
> On Nov 18, 2015, at 10:34 AM, Zachary Turner via lldb-dev > wrote: > > > > On Wed, Nov 18, 2015 at 10:00 AM Todd Fiala > wrote: > Checking in the static bindings is no different than projects checking in > autoconf config baked scripts so that the vast majorit

Re: [lldb-dev] proposal for reworked flaky test category

2015-10-20 Thread Enrico Granata via lldb-dev
> On Oct 19, 2015, at 4:40 PM, Zachary Turner via lldb-dev > wrote: > > Yea, I definitely agree with you there. > > Is this going to end up with an @expectedFlakeyWindows, @expectedFlakeyLinux, > @expectedFlakeyDarwin, @expectedFlakeyAndroid, @expectedFlakeyFreeBSD? > > It's starting to ge

Re: [lldb-dev] TestRdarXXXXXX

2015-08-14 Thread Enrico Granata via lldb-dev
> On Aug 14, 2015, at 11:50 AM, Zachary Turner via lldb-dev > wrote: > > There are a bunch of tests in the tree that are named after Rdars. As a > result, it's not clear to anyone outside of Apple what these are supposed to > be testing so it diminishes their usefulness and increases our mai

Re: [lldb-dev] How to deal with STL type names in C++ code?

2015-08-06 Thread Enrico Granata via lldb-dev
> On Aug 6, 2015, at 4:17 PM, Siva Chandra wrote: > > > > On Thu, Aug 6, 2015 at 3:58 PM, Enrico Granata > wrote: > >> On Aug 6, 2015, at 3:50 PM, Siva Chandra > > wrote: >> >> >> >> On Thu, Aug 6, 2015 at 3:38 PM, Enrico Granata >

Re: [lldb-dev] How to deal with STL type names in C++ code?

2015-08-06 Thread Enrico Granata via lldb-dev
line? With this, a name like >>>> std::__1::basic_string<...> can be modified into a more friendly name >>>> like std::string? We could ofcourse have more complex modifications. >>>> >>>> I think it is doable, but what is your (and the comm

Re: [lldb-dev] How to deal with STL type names in C++ code?

2015-08-06 Thread Enrico Granata via lldb-dev
ble, but what is your (and the community's) opinion >>> about adding such a feature? If you are OK, I would like to take up >>> adding such a feature. >>> >>> Thanks, >>> Siva Chandra >>> >>> On Thu, Aug 6, 2015 at 2:15 PM, Enrico Gr

Re: [lldb-dev] How to deal with STL type names in C++ code?

2015-08-06 Thread Enrico Granata via lldb-dev
Hi Eugene, > On Aug 6, 2015, at 2:02 PM, Eugene Birukov via lldb-dev > wrote: > > Hi, > > I am using LLDB C++ API to create custom debugger and trying to dump > variables with their types. To do that I am using SBValue.GetTypeName() API. > Some types are OK, but some others - especially ones