Community
Participate
Working Groups
Build Identifier: 3.6 org.eclipse.cdt.dsf.debug.internal.ui.disassembly.DisassemblyBackendDsf gotoSymbol needs to handle IExpressionDMLocation when using IExpressions.getExpressionAddressData. org.eclipse.cdt.dsf.debug.service.IExpressions.getExpressionAddressData can return IExpressionDMAddress or IExprssionDMLocation object for a request. IExpressionDMLocation in this case does not have a valid address but a valid location. Current code in DisassemblyBackendDsf.gotoSymbol handles IExpressionDMLocation object as IExpressionDMAddress object and calls IExpressionDMAddress.getAddress and uses the returned IAddress object. This results in using an useless address. There is a need to handles cases of IExpressionDMLocation. Reproducible: Always
Created attachment 181426 [details] proposed fix on gotoSymbol Please see my proposed fix at lines 825-875, or look for keyword 'Bug 328391'
I tested the propose fix with typing the following entries in the disassembly view using dsf gdb based debug session. 124 124 + 8 main main + 8 $eip $eip + 8 eip &main &main + 8 The main is the symbol of a c program with main function. They are working fine.
(In reply to comment #1) > Created an attachment (id=181426) [details] > proposed fix on gotoSymbol > > Please see my proposed fix at lines 825-875, or look for keyword 'Bug 328391' Could you attach a regular patch? Thanks.
(In reply to comment #2) > I tested the propose fix with typing the following entries in the disassembly > view using dsf gdb based debug session. > 124 > 124 + 8 > main > main + 8 > $eip > $eip + 8 > eip > &main > &main + 8 Those expressions work for me without any fix (using DSF-GDB). Do you have an example which does not work?
you can try &main+1 or 127, where the address is not evenly aligned.
(In reply to comment #5) Please ignore my comments, I reply for the wrong bug.
I committed a fix to properly handle the case where the address is a IExpressionDMLocation.INVALID_ADDRESS. Please verify this solution.
*** cdt cvs genie on behalf of aleherbau *** Bug 328391 - DisassemblyBackendDsf gotoSymbol needs to handle IExpressionDMLocation when using IExpressions.getExpressionAddressData [*] DisassemblyBackendDsf.java 1.19 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf/org.eclipse.cdt.dsf.ui/src/org/eclipse/cdt/dsf/debug/internal/ui/disassembly/DisassemblyBackendDsf.java?root=Tools_Project&r1=1.18&r2=1.19 [*] DisassemblyBackendDsf.java 1.8.2.7 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf/org.eclipse.cdt.dsf.ui/src/org/eclipse/cdt/dsf/debug/internal/ui/disassembly/DisassemblyBackendDsf.java?root=Tools_Project&r1=1.8.2.6&r2=1.8.2.7