| Summary: | [multi-process][disassembly] The disassembly window shows wrong code when debugging multiple processes. | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Tools] CDT | Reporter: | Nicolas Blanc <nicolas.blanc> | ||||||||
| Component: | cdt-debug-dsf-gdb | Assignee: | Marc Khouzam <marc.khouzam> | ||||||||
| Status: | RESOLVED FIXED | QA Contact: | Marc Khouzam <marc.khouzam> | ||||||||
| Severity: | normal | ||||||||||
| Priority: | P3 | CC: | aleherb+eclipse, cdtdoug, john.cortell, pawel.1.piech | ||||||||
| Version: | 8.0 | Flags: | aleherb+eclipse:
review+
marc.khouzam: review? (john.cortell) |
||||||||
| Target Milestone: | 8.0 | ||||||||||
| Hardware: | PC | ||||||||||
| OS: | Linux | ||||||||||
| Whiteboard: | |||||||||||
| Attachments: |
|
||||||||||
|
Description
Nicolas Blanc
Thanks for reporting this. It is a big deal. The reason is that the IDisassemblyDMContext is still implemented by GDBControlDMContext which represents GDB, instead of being implemented by MIContainerDMC. We have to move that interface is the same fashion as for bug 335324 and bug 335325. Created attachment 194458 [details] Proposed fix This simple patch moves the IDisassemblyDMContext to MIContainerDMC. Things seem to work better and the JUnit tests for Disassembly pass. But then I ran into Bug 344408 which prevents from properly showing the source code in the disassembly view, which affects the second process we add to the multi-process session. This patch is still an improvement and I think it is ok even before we fix Bug 344408. I'll try to get others that know Disassembly better than myself to review the patch fast since we are so close to the M7 build. Toni, this patch is very simple but makes a serious change. I was hoping to get your opinion on it John, your opinion would be valuable as well. A note on the API changes. The fix still works even if we don't remove IDisassemblyDMContext from GDBControlDMContext. So, if you guys feel that part of the change impacts API too much, we could leave GDBControlDMContext as is (with a comment). Created attachment 194459 [details]
Fix for JUnit tests only
I committed the fix for the JUnit tests only, which works with or without the full fix.
Created attachment 194460 [details]
Proposed fix (no Junit)
This is the fix itself, without the JUnit change. 3-line change.
*** cdt cvs genie on behalf of mkhouzam *** Bug 344298: JUnit support for Disassembly in case of multi-process. [*] MIDisassemblyTest.java 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.tests.dsf.gdb/src/org/eclipse/cdt/tests/dsf/gdb/tests/MIDisassemblyTest.java?root=Tools_Project&r1=1.4&r2=1.5 Makes sense, +1 for the API change. I don't think this would break existing code. (In reply to comment #9) > Makes sense, +1 for the API change. I don't think this would break existing > code. Thanks Toni! Committed to HEAD. I think I messed up the review flags by re-using an already-open webpage. Toni, if you can try to re-mark it as approved, that would be nice. Thanks. *** cdt cvs genie on behalf of mkhouzam *** Bug 344298: Support for Disassembly in case of multi-process. [*] GDBControlDMContext.java 1.5 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/service/command/GDBControlDMContext.java?root=Tools_Project&r1=1.4&r2=1.5 [*] MIProcesses.java 1.15 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/mi/service/MIProcesses.java?root=Tools_Project&r1=1.14&r2=1.15 [*] GDBProcesses_7_0.java 1.49 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/dsf-gdb/org.eclipse.cdt.dsf.gdb/src/org/eclipse/cdt/dsf/gdb/service/GDBProcesses_7_0.java?root=Tools_Project&r1=1.48&r2=1.49 Bug 344408 has been fixed, but it was not sufficient for the multi-process case. I opened Bug 344471 for the multi-process case. |