Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 326970 - [processes] Missing changes for GDB 7.2 (which can prevent cores to not be shown in the process label)
Summary: [processes] Missing changes for GDB 7.2 (which can prevent cores to not be sh...
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-debug-dsf-gdb (show other bugs)
Version: 8.0   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: 7.0.2   Edit
Assignee: Marc Khouzam CLA
QA Contact: Marc Khouzam CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 317500
  Show dependency tree
 
Reported: 2010-10-04 16:10 EDT by Marc Khouzam CLA
Modified: 2010-12-03 14:28 EST (History)
2 users (show)

See Also:
nobody: review+


Attachments
Un-reviewed fix for HEAD (6.96 KB, patch)
2010-10-05 14:12 EDT, Marc Khouzam CLA
marc.khouzam: iplog-
Details | Diff
Fix for HEAD (9.87 KB, patch)
2010-11-22 10:45 EST, Marc Khouzam CLA
marc.khouzam: iplog-
Details | Diff
Fix for 7_0 (4.59 KB, patch)
2010-11-22 11:17 EST, Marc Khouzam CLA
marc.khouzam: iplog-
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marc Khouzam CLA 2010-10-04 16:10:36 EDT
I guess I missed something when I fixed bug 317500.
For some reason, the new core label on the process entry is not show.  What should happen can be seen in:
http://wiki.eclipse.org/CDT/User/NewIn80#Showing_cores_in_Debug_view_labels

This works with GDB 7.1 and works for Threads for GDB 7.2 also, but not for processes for GDB 7.2
Comment 1 Marc Khouzam CLA 2010-10-04 21:25:40 EDT
I found some things that I had missed.

1- In GDBProcesses_7_1#getExecutionData(), I use the procId as a groupId in the IMIProcessDMContext case.  This is wrong for GDB 7.2
2- In GDBProcesses_7_0#getDebuggingContext(), I use the procId as a groupId when creating the container in both cases.  This is wrong for GDB 7.2
3- In GDBProcesses_7_0#attachDebuggerToProcess(), I use the procId as a groupId when I call createContainerContext()
4- In MIProcesses#getDebuggingContext(), I use the procId as a groupId when creating the container in both cases.  This code does not run for GDB 7.2, but should be fixed for consistency
5- In MIProcesses#attachDebuggerToProcess(), I use the procId as a groupId when I call createContainerContext().  This code does not run for GDB 7.2, but should be fixed for consistency
Comment 2 Marc Khouzam CLA 2010-10-05 14:12:24 EDT
Created attachment 180270 [details]
Un-reviewed fix for HEAD

I wanted to have this fixed so here is a patch that works.  I haven't properly reviewed it to make sure it is sane, but at least it is available.  I will have to be (easily) adapted for the 7_0 branch.

(In reply to comment #1)
> 4- In MIProcesses#getDebuggingContext()
> 5- In MIProcesses#attachDebuggerToProcess()

I was wrong about those two cases, they are code properly since the groupId is the same as the pId for those versions of GDB.
Comment 3 Marc Khouzam CLA 2010-10-05 14:16:00 EDT
I don't expect to complete this bug for the next four weeks, so if someone wants to take it, its fine with me.
Comment 4 Marc Khouzam CLA 2010-11-22 10:45:17 EST
Created attachment 183573 [details]
Fix for HEAD

Here is the fix for HEAD.  Same solution as before, but I made the class easier to override.  Committed to HEAD.
Comment 5 Marc Khouzam CLA 2010-11-22 11:17:29 EST
Created attachment 183574 [details]
Fix for 7_0

And here is the fix for 7_0.  Note that it is not a fix for showing the cores with 7.2, since this feature is new for CDT 8.0.  However, the couple of fixes I had missed in GDBProcesses_7_0 do belong in 7_0.

Committed to 7_0
Comment 6 Marc Khouzam CLA 2010-11-22 11:18:19 EST
Mikhail, you can let me know if you see any issues with this.
Comment 8 CDT Genie CLA 2010-11-22 11:23:08 EST
*** cdt cvs genie on behalf of mkhouzam ***
Bug 326970: [processes] Missing fixes to handle GDB 7.2 where groupId is no longer the pId

[*] GDBProcesses_7_0.java 1.21.2.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/GDBProcesses_7_0.java?root=Tools_Project&r1=1.21.2.4&r2=1.21.2.5
Comment 9 Nobody - feel free to take it CLA 2010-12-03 14:28:10 EST
Looks good to me. Not sure that I have good understanding of the related MI protocol though.