[cmake-developers] Debugger for CMake

Brad King brad.king at kitware.com
Mon Feb 13 14:59:29 EST 2017


On 01/31/2017 02:55 PM, Justin Berger wrote:
> I looked through the code for cmServer, since it maintains an instance
> of cmake in process, it could register as a debug listener and get events
> / set breakpoints and all in response to different requests coming in.
> The issue here though is that it seems like (and maybe this is wrong?) the actual
> call out to configure blocks on the libuv loop thread so it can't get or
> process any requests while configure is running; so maybe keeping them as
> seperate services running on separate loops is better.  

I'd like to see if we can make the debug server part of the existing server
mode rather than adding another mode as the original MR does.  The current
server mode already has infrastructure for protocol version negotiation,
capability listing, etc.  We should be able to use/re-use that as appropriate.

As for the server blocking on the configure call, that is in response to the
client's request for configuration of the build tree.  With the currently
available protocol blocking is okay.  If additional internal granularity of
responsibility is needed for a debug server then such refactoring would be
appropriate.  As long as the current protocol remains unchanged from the
perspective of the client then the debug server can choose to offer a
different protocol on top of a common internal implementation.

Caveat: I have limited understanding of the server mode internals.

Thanks,
-Brad



More information about the cmake-developers mailing list