Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 325677 - edc - disassembly - context menu item "Show Function Offsets" not working
Summary: edc - disassembly - context menu item "Show Function Offsets" not working
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-edc (show other bugs)
Version: 7.0.1   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Ken Ryall CLA
QA Contact: Ken Ryall CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-09-18 09:07 EDT by Kirk Beitz CLA
Modified: 2011-05-13 10:54 EDT (History)
0 users

See Also:


Attachments
patch to fill function name & offset for instructions so "Show Function Offsets" works in DisassemblyBackendDsf (13.86 KB, patch)
2010-09-18 09:07 EDT, Kirk Beitz CLA
cdtdoug: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kirk Beitz CLA 2010-09-18 09:07:31 EDT
Created attachment 179172 [details]
patch to fill function name & offset for instructions so "Show Function Offsets" works in DisassemblyBackendDsf

when the user chooses "Show Function Offsets" from the context menu for edc, nothing is displayed.  in contrast, dsf gdb displays function name + offset.

the attached patch was formerly part of a much larger patch in Bug 325284, but has been extracted due to that bug relying on Bug 325277.  it represents the simplest patch to HEAD as of 2010.09.17 w.r.t. performing this functionality.


- EDCInstructionFunctionInfo.java
  - a new container for function name & starting address that can be made to
    apply to a function or a portion thereof if so requested, including a
    single line.  the simple constructor is for when function name & start
    are known at call time.  the alternate constructor will take an IEDCModule
    and ILineEntry and construct the function & address if possible.

- EDCInstruction.java
  - modified to add setters for functionName & offset; it already had getters
    for both as part of its contract to fulfill implementation of IInstruction;
    these have been modified to return the values stored by the setters.

- Disassembly.java
  - modified to populate EDCInstructions with function & offset info prior to
    being passed returned to the caller via RM (i.e. DisassemblyBackendDsf).

- ARMDisassembly.java
- RangeAndMode.java
  - modified to demonstrate the optimization to pass Disassembly#mixSource an
    EDCInstructionFunctionInfo object so it doesn't have to be calculated per
    line.

this patch applies cleanly to head as of 2010.09.18, and has been tested with the edc windows debugger; a modified version of the attached patch has been tested together with other disassembly changes, and is planned for later merge together at the same time.
Comment 1 Kirk Beitz CLA 2010-10-06 22:45:40 EDT
resolved with 2010.oct.04 edc merge commits by ken.ryall@nokia.com