Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 149821 Details for
Bug 287907
Indexer holds exclusive index lock for too long
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
More granular index locking
lock_granularity.txt (text/plain), 2.15 KB, created by
Sergey Prigogin
on 2009-10-17 18:47:23 EDT
(
hide
)
Description:
More granular index locking
Filename:
MIME Type:
Creator:
Sergey Prigogin
Created:
2009-10-17 18:47:23 EDT
Size:
2.15 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.cdt.core >Index: parser/org/eclipse/cdt/internal/core/pdom/PDOMWriter.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.cdt/all/org.eclipse.cdt.core/parser/org/eclipse/cdt/internal/core/pdom/PDOMWriter.java,v >retrieving revision 1.39 >diff -u -r1.39 PDOMWriter.java >--- parser/org/eclipse/cdt/internal/core/pdom/PDOMWriter.java 18 Jul 2009 18:59:11 -0000 1.39 >+++ parser/org/eclipse/cdt/internal/core/pdom/PDOMWriter.java 17 Oct 2009 21:30:25 -0000 >@@ -191,18 +191,18 @@ > int linkageID, int configHash, HashSet<IASTPreprocessorIncludeStatement> contextIncludes, > IWritableIndex index, int readlockCount, boolean flushIndex, > ArrayList<IStatus> stati, IProgressMonitor pm) throws InterruptedException, CoreException { >- index.acquireWriteLock(readlockCount); >- long start= System.currentTimeMillis(); >- try { >- for (int i= 0; i < ifls.length; i++) { >- if (pm.isCanceled()) >- return; >- >- final IIndexFileLocation ifl= ifls[i]; >- if (ifl != null) { >- if (fShowActivity) { >- System.out.println("Indexer: adding " + ifl.getURI()); //$NON-NLS-1$ >- } >+ for (int i= 0; i < ifls.length; i++) { >+ if (pm.isCanceled()) >+ return; >+ >+ final IIndexFileLocation ifl= ifls[i]; >+ if (ifl != null) { >+ if (fShowActivity) { >+ System.out.println("Indexer: adding " + ifl.getURI()); //$NON-NLS-1$ >+ } >+ index.acquireWriteLock(readlockCount); >+ long start= System.currentTimeMillis(); >+ try { > Throwable th= null; > try { > storeFileInIndex(index, ifl, symbolMap, linkageID, configHash, contextIncludes); >@@ -220,12 +220,12 @@ > if (i < ifls.length - 1) { > updateFileCount(0, 0, 1); // update header count > } >+ } finally { >+ index.releaseWriteLock(readlockCount, flushIndex); > } >+ fStatistics.fAddToIndexTime+= System.currentTimeMillis() - start; > } >- } finally { >- index.releaseWriteLock(readlockCount, flushIndex); > } >- fStatistics.fAddToIndexTime+= System.currentTimeMillis()-start; > } > > private void resolveNames(final Map<IIndexFileLocation, Symbols> symbolMap, IIndexFileLocation[] ifls,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
eclipse.sprigogin
:
iplog-
Actions:
View
|
Diff
Attachments on
bug 287907
: 149821 |
150451
|
150633
|
155176
|
155189
|
155709
|
156475
|
157044
|
157435
|
157438