Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 312552

Summary: Revert scanner config / PDOMManager locking to 11-May
Product: [Tools] CDT Reporter: James Blackburn <jamesblackburn+eclipse>
Component: cdt-coreAssignee: James Blackburn <jamesblackburn+eclipse>
Status: RESOLVED FIXED QA Contact: Doug Schaefer <cdtdoug>
Severity: normal    
Priority: P3 CC: recoskie
Version: 7.0   
Target Milestone: 7.0   
Hardware: PC   
OS: All   
Whiteboard:
Attachments:
Description Flags
patch 1 jamesblackburn+eclipse: iplog-

Description James Blackburn CLA 2010-05-12 05:10:29 EDT
Created attachment 168103 [details]
patch 1

Proposed patch attached.

PDOMManager: reverted
CfgDiscoveredPathManager: Use an ILock rather than a scheduling rule / java mutex for locking.

ILocks are deadlock safe (though under deadlock conditions a lock would be released).

To debug ILock deadlocks enable the following debug option:
org.eclipse.core.jobs/jobs/errorondeadlock=true
Comment 1 James Blackburn CLA 2010-05-12 05:10:56 EDT
Chris you ok with this?
Comment 2 James Blackburn CLA 2010-05-12 05:28:45 EDT
I've committed my proposed fix to CfgDiscoveredPathManager. 
I realise the time-zones are against you :), but I'm faily confident that if this code can still deadlock in 7.0, this change will stop it locking up the IDE.

Do attach backtraces of any deadlock conditions though!
Comment 3 CDT Genie CLA 2010-07-28 15:26:50 EDT
*** cdt cvs genie on behalf of jblackburn ***
Bug 312552 Use ILock rather than scheduling rule for mutual exclusion. Scheduling rules require knowing in advance all scheduling rules clients require.

[*] CfgDiscoveredPathManager.java 1.17 http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.cdt/all/org.eclipse.cdt.managedbuilder.core/src/org/eclipse/cdt/build/internal/core/scannerconfig/CfgDiscoveredPathManager.java?root=Tools_Project&r1=1.16&r2=1.17