Community
Participate
Working Groups
Build Identifier: With Linux TCF agent (but this is true also with other TCF agents which support watchpoints) when a client sets a watchpoint, the TCF agent always plants the watchpoint, unplants it and plants it again. The two last steps are unnecessary. Note that the watchpoint is first planted by the call to context_plant_breakpoint() in plant_breakpoint() routine (breakpoints.c) and is then unplanted and replanted from flush_instructions() routine (breaopints.c) because the bp->attrs_changed flag has been set (incorrectly IMO) by add_breakpoint() when the breakpoint was created. Note that this is not causing any real issue but when using TCF agent to connect to an OCD, then this can be quite costly in time when you have a system with many cores. Reproducible: Always Steps to Reproduce: 1. Instrument code in linux context_plant_breakpoint() and context_unplant_breakpoint() to monitor activity. 2. Start a debug session connected to your Linux TCF agent 3. Add a watchpointfrom the Eclipse UI (note that if you enable/disable an existing watchpointit will not exhibit the problem; you need to create a new watchpoint).
Created attachment 218076 [details] Proposed patch
Good catch. I have committed the patch. Thanks!