[Lldb-commits] [PATCH] D37923: Implement interactive command interruption

Zachary Turner via lldb-commits lldb-commits at lists.llvm.org
Tue Sep 19 18:57:50 PDT 2017


On Tue, Sep 19, 2017 at 11:51 AM Zachary Turner <zturner at google.com> wrote:

> On Tue, Sep 19, 2017 at 11:40 AM Jim Ingham <jingham at apple.com> wrote:
>
>> I must be missing something.
>>
>> DisaptchInputInterrupt knows how to interrupt a running process, and
>> because of Enrico's Python interruption stuff it will interrupt script
>> execution at some point but it wasn't very reliable last time I tried it.
>>
>> But the whole point of this patch is that in general commands don't
>> listen to that interrupt if they are just running in a loop doing work.
>> Sending the interrupt is not enough.
>>
>> Jim
>>
>
> I guess you are saying they installed a custom IOHandler?  IF that's the
> case, then yea I guess it won't work.
>

After some additional thought, I stilled think testing below the sb api
layer is more appropriate.

>   While Xcode might be going through the SB api, users of upstream lldb
(which is what we supposed to be testing upstream) are not.

In order to achieve maximum test coverage and minimal flakiness, there
should be 2 tests:

 the first test is for core functionality and tests that if you pass call
tge interrupt function, it gets interrupted and the output is as expected.

The second test test checks that if you call the Python api, it calls the
function that has been tested by step 1.

If you want a third function that tests both, you can certainly do that,
but this way the creation of a test is not blocked on the addition of a
Python api.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20170920/80d23cef/attachment.html>


More information about the lldb-commits mailing list