[Lldb-commits] [lldb] r313371 - Remove a couple of warnings pointed out by Ted Woodward.

2017-09-15 Thread Jim Ingham via lldb-commits
Author: jingham Date: Fri Sep 15 10:54:37 2017 New Revision: 313371 URL: http://llvm.org/viewvc/llvm-project?rev=313371&view=rev Log: Remove a couple of warnings pointed out by Ted Woodward. Modified: lldb/trunk/source/API/SBBreakpointName.cpp Modified: lldb/trunk/source/API/SBBreakpointName

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

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo created this revision. Herald added a subscriber: ki.stfu. The core of this change is the new CommandInterpreter::m_command_state, which models the state transitions for interactive commands, including an "interrupted" state transition. In general, command interruption requires cooperation

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

2017-09-15 Thread Adrian McCarthy via Phabricator via lldb-commits
amccarth added a comment. I haven't looked at the whole patch yet, but it seems the SIGINT fix is well isolated. That should probably be in a separate patch. https://reviews.llvm.org/D37923 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [PATCH] D37926: Fix the SIGINT handlers

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo created this revision. Herald added a subscriber: ki.stfu. 1. Fix a data race (g_interrupt_sent flag usage was not thread safe, signals can be handled on arbitrary threads) 2. exit() is not signal-safe, replaced it with the signal-safe equivalent _exit() https://reviews.llvm.org/D37926 F

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

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo updated this revision to Diff 115476. lemo added a comment. Split the SIGINT handles fixes into a stanalone patch https://reviews.llvm.org/D37923 Files: include/lldb/Core/IOHandler.h include/lldb/Interpreter/CommandInterpreter.h source/Commands/CommandObjectTarget.cpp source/Interp

[Lldb-commits] [PATCH] D37926: Fix the SIGINT handlers

2017-09-15 Thread Zachary Turner via Phabricator via lldb-commits
zturner added a comment. It turns out the function this called, `DispatchInputInterrupt`, already acquires a mutex. Maybe put the synchronization in there? Then you don't have to reproduce the synchronization in both MI and LLDB https://reviews.llvm.org/D37926

Re: [Lldb-commits] [PATCH] D37926: Fix the SIGINT handlers

2017-09-15 Thread Leonard Mosescu via lldb-commits
How would that fix look? If the intention is to ignore nested SIGINT then doing it directly in the handler seems cleaner and safer (re. safety, note that m_input_reader_stack.GetMutex() is a std::*recursive_*mutex so depending on it in signal handlers is a big no-no. The recursive_mutex looks like

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

2017-09-15 Thread Adrian McCarthy via Phabricator via lldb-commits
amccarth added inline comments. Comment at: source/Commands/CommandObjectTarget.cpp:2058 + break; +} num_dumped++; Many LLVM developers prefer to omit the braces when the body of the control-flow statement is a single statem

[Lldb-commits] [PATCH] D37926: Fix the SIGINT handlers

2017-09-15 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. Looks fine to me. https://reviews.llvm.org/D37926 ___ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [PATCH] D37930: Use ThreadLauncher to launch TaskPool threads

2017-09-15 Thread Francis Ricci via Phabricator via lldb-commits
fjricci created this revision. This allows for the stack size to be configured, which isn't possible with std::thread. Prevents overflowing the stack when performing complex operations in the task pool on darwin, where the default pthread stack size is only 512kb. https://reviews.llvm.org/D37930

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

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo added inline comments. Comment at: source/Commands/CommandObjectTarget.cpp:2058 + break; +} num_dumped++; amccarth wrote: > Many LLVM developers prefer to omit the braces when the body of the > control-flow statement is

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

2017-09-15 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added inline comments. Comment at: source/Commands/CommandObjectTarget.cpp:2056-2058 +if (m_interpreter.WasInterrupted()) { + break; +} Remove braces Comment at: source/Commands/CommandObjectTarget.

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

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo added inline comments. Comment at: source/Interpreter/CommandInterpreter.cpp:2713 + for (; chunk_size < size; ++chunk_size) { +assert(data[chunk_size] != '\0'); +if (data[chunk_size] == '\n') { amccarth wrote: > Should we be that trustin

[Lldb-commits] [PATCH] D37934: Fix compatibility with OpenOCD debug stub.

2017-09-15 Thread Vadim Chugunov via Phabricator via lldb-commits
vadimcn created this revision. vadimcn added a project: LLDB. OpenOCD sends register classes as two separate nodes, fixed parser to process both of them. OpenOCD returns "l" in response to "qfThreadInfo", so IsUnsupportedResponse() was false and we were ending up without any threads in the pro

[Lldb-commits] [lldb] r313407 - Resubmit "[lit] Force site configs to run before source-tree configs"

2017-09-15 Thread Zachary Turner via lldb-commits
Author: zturner Date: Fri Sep 15 15:10:46 2017 New Revision: 313407 URL: http://llvm.org/viewvc/llvm-project?rev=313407&view=rev Log: Resubmit "[lit] Force site configs to run before source-tree configs" This is a resubmission of r313270. It broke standalone builds of compiler-rt because we were

[Lldb-commits] [PATCH] D37934: Fix compatibility with OpenOCD debug stub.

2017-09-15 Thread Greg Clayton via Phabricator via lldb-commits
clayborg added a comment. The multiple feature fix is fine. As for the qfThreadInfo fix, do you not have control over the OpenOCD GDB server? I would be nice to modify it to return something valid in response to qfThreadInfo? If you don't control or have access to modify the OpenOCD GDB server

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

2017-09-15 Thread Leonard Mosescu via Phabricator via lldb-commits
lemo updated this revision to Diff 115516. lemo edited the summary of this revision. lemo added a comment. Incorporating CR feedback. https://reviews.llvm.org/D37923 Files: include/lldb/Core/IOHandler.h include/lldb/Interpreter/CommandInterpreter.h source/Commands/CommandObjectTarget.cpp

[Lldb-commits] [PATCH] D37934: Fix compatibility with OpenOCD debug stub.

2017-09-15 Thread Vadim Chugunov via Phabricator via lldb-commits
vadimcn added a comment. This is what I see in the log: < 16> send packet: $qfThreadInfo#bb < 5> read packet: $l#6c And here's code that generates it: https://github.com/gnu-mcu-eclipse/openocd/blob/b21ab1d683aaee501d45fe8a509a2043123f16fd/src/rtos/rtos.c#L370 I agree, they should have

[Lldb-commits] [PATCH] D37934: Fix compatibility with OpenOCD debug stub.

2017-09-15 Thread Greg Clayton via Phabricator via lldb-commits
clayborg accepted this revision. clayborg added a comment. This revision is now accepted and ready to land. As long as everyone agrees that no threads from qfThreadInfo means there is one thread whose thread ID is 1 then this is ok. Repository: rL LLVM https://reviews.llvm.org/D37934

[Lldb-commits] [lldb] r313436 - More precise c library feature detection for Android.

2017-09-15 Thread Eugene Zemtsov via lldb-commits
Author: eugene Date: Fri Sep 15 19:19:21 2017 New Revision: 313436 URL: http://llvm.org/viewvc/llvm-project?rev=313436&view=rev Log: More precise c library feature detection for Android. Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake lldb/trunk/source/Host/common/Socket.cpp

[Lldb-commits] [lldb] r313437 - Check availability of accept4 in C++ instad of C code.

2017-09-15 Thread Eugene Zemtsov via lldb-commits
Author: eugene Date: Fri Sep 15 19:58:49 2017 New Revision: 313437 URL: http://llvm.org/viewvc/llvm-project?rev=313437&view=rev Log: Check availability of accept4 in C++ instad of C code. Modified: lldb/trunk/cmake/modules/LLDBGenerateConfig.cmake Modified: lldb/trunk/cmake/modules/LLDBGener

[Lldb-commits] [lldb] r313442 - Fix compatibility with OpenOCD debug stub.

2017-09-15 Thread Vadim Chugunov via lldb-commits
Author: vadimcn Date: Fri Sep 15 20:53:13 2017 New Revision: 313442 URL: http://llvm.org/viewvc/llvm-project?rev=313442&view=rev Log: Fix compatibility with OpenOCD debug stub. OpenOCD sends register classes as two separate nodes, fixed parser to process both of them. OpenOCD returns "l" in re