52
52
namespace llvm {
53
53
class raw_ostream ;
54
54
class ThreadPool ;
55
- }
55
+ } // namespace llvm
56
56
57
57
namespace lldb_private {
58
58
class Address ;
@@ -377,19 +377,19 @@ class Debugger : public std::enable_shared_from_this<Debugger>,
377
377
bool IsHandlingEvents () const { return m_event_handler_thread.IsJoinable (); }
378
378
379
379
Status RunREPL (lldb::LanguageType language, const char *repl_options);
380
-
380
+
381
381
// / Interruption in LLDB:
382
- // /
382
+ // /
383
383
// / This is a voluntary interruption mechanism, not preemptive. Parts of lldb
384
- // / that do work that can be safely interrupted call
384
+ // / that do work that can be safely interrupted call
385
385
// / Debugger::InterruptRequested and if that returns true, they should return
386
386
// / at a safe point, shortcutting the rest of the work they were to do.
387
- // /
388
- // / lldb clients can both offer a CommandInterpreter (through
387
+ // /
388
+ // / lldb clients can both offer a CommandInterpreter (through
389
389
// / RunCommandInterpreter) and use the SB API's for their own purposes, so it
390
390
// / is convenient to separate "interrupting the CommandInterpreter execution"
391
- // / and interrupting the work it is doing with the SB API's. So there are two
392
- // / ways to cause an interrupt:
391
+ // / and interrupting the work it is doing with the SB API's. So there are two
392
+ // / ways to cause an interrupt:
393
393
// / * CommandInterpreter::InterruptCommand: Interrupts the command currently
394
394
// / running in the command interpreter IOHandler thread
395
395
// / * Debugger::RequestInterrupt: Interrupts are active on anything but the
@@ -398,21 +398,20 @@ class Debugger : public std::enable_shared_from_this<Debugger>,
398
398
// / Since the two checks are mutually exclusive, however, it's also convenient
399
399
// / to have just one function to check the interrupt state.
400
400
401
-
402
401
// / Bump the "interrupt requested" count on the debugger to support
403
402
// / cooperative interruption. If this is non-zero, InterruptRequested will
404
403
// / return true. Interruptible operations are expected to query the
405
404
// / InterruptRequested API periodically, and interrupt what they were doing
406
405
// / if it returns \b true.
407
406
// /
408
407
void RequestInterrupt ();
409
-
408
+
410
409
// / Decrement the "interrupt requested" counter.
411
410
void CancelInterruptRequest ();
412
-
411
+
413
412
// / This is the correct way to query the state of Interruption.
414
- // / If you are on the RunCommandInterpreter thread, it will check the
415
- // / command interpreter state, and if it is on another thread it will
413
+ // / If you are on the RunCommandInterpreter thread, it will check the
414
+ // / command interpreter state, and if it is on another thread it will
416
415
// / check the debugger Interrupt Request state.
417
416
// /
418
417
// / \return
@@ -574,13 +573,13 @@ class Debugger : public std::enable_shared_from_this<Debugger>,
574
573
bool StartIOHandlerThread ();
575
574
576
575
void StopIOHandlerThread ();
577
-
576
+
578
577
// Sets the IOHandler thread to the new_thread, and returns
579
578
// the previous IOHandler thread.
580
579
HostThread SetIOHandlerThread (HostThread &new_thread);
581
580
582
581
void JoinIOHandlerThread ();
583
-
582
+
584
583
bool IsIOHandlerThreadCurrentThread () const ;
585
584
586
585
lldb::thread_result_t IOHandlerThread ();
0 commit comments