Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 369998 - IBreakpointLocationProvider methods need a target or viewsite parameter
Summary: IBreakpointLocationProvider methods need a target or viewsite parameter
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-dsf (show other bugs)
Version: 8.1.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 8.1.0   Edit
Assignee: Patrick Chuong CLA
QA Contact: Pawel Piech CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-01-27 14:33 EST by Norman Yee CLA
Modified: 2012-02-29 13:24 EST (History)
4 users (show)

See Also:
aleherb+eclipse: review+


Attachments
patch (10.88 KB, patch)
2012-02-01 13:59 EST, Patrick Chuong CLA
pchuong: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Norman Yee CLA 2012-01-27 14:33:47 EST
Build Identifier: 20110916-0149

I am implementing a custom DSF debugger plugin that supports multi-core targets.  If breakpoints are set on multiple cores, the disassembly view displays all breakpoints no matter which cores the breakpoints are set on.  I want to hide the breakpoints that are not set on the core that the disassembly view is pinned to.

To fix this, I added a breakpoint adapter that implements implements the IBreakpointLocationProvider interface and planned to return null for the breakpoints whose core does not match the core that the disassembly view is pinned to.  It is not possible to do this with the current IBreakpointLocationProvider interface.  The problem is that the adapter needs the target/viewsite in order to look up the context that the disassembly view is pinned to so the target/viewsite should be added as a parameter to the methods in IBreakpointLocationProvider.



Reproducible: Always
Comment 1 Patrick Chuong CLA 2012-01-27 14:38:30 EST
The IBreakpointLocationProvider is a provisional interface, is it ok if I add a parameter to the existing API? Or I need to create a new interface and provide the same API with the additional parameter?
Comment 2 Anton Leherbauer CLA 2012-01-30 05:42:18 EST
(In reply to comment #1)
> The IBreakpointLocationProvider is a provisional interface, is it ok if I add a
> parameter to the existing API? Or I need to create a new interface and provide
> the same API with the additional parameter?

AFAIK there are no clients of the API except TI, so I think you can change it in place. A short notice on cdt-dev would be good, though.
Comment 3 Patrick Chuong CLA 2012-02-01 13:59:38 EST
Created attachment 210397 [details]
patch

Norman, can you take a look at the patch and see whether this is all you need?
Comment 4 Norman Yee CLA 2012-02-02 15:12:59 EST
The patch works for me.  Thanks Patrick!
Comment 5 Anton Leherbauer CLA 2012-02-03 02:34:05 EST
Looks good.
Comment 6 Patrick Chuong CLA 2012-02-06 13:06:05 EST
Committed patch to master.
Comment 7 CDT Genie CLA 2012-02-29 13:24:27 EST
*** cdt git genie on behalf of Patrick Chuong ***

    Bug 369998 - IBreakpointLocationProvider methods need a target or
    viewsite parameter

[*] http://git.eclipse.org/c/cdt/org.eclipse.cdt.git/commit/?id=2e5c77c1ab91a033296cfab467d53c1c9a260e54