Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [Dltk-dev] SourceParserUtil cache miss

Not sure if this is related but this is my patch that i have in SourceModule

    public void makeConsistent(IProgressMonitor monitor) throws ModelException {
        // if (isConsistent())
        // return;
        // makeConsistent(false/*don't create AST*/, 0, monitor);

        HashSet<Openable> elementsOutOfSynchWithBuffers = ModelManager
                .getModelManager().getElementsOutOfSynchWithBuffers();
        synchronized (elementsOutOfSynchWithBuffers) {
            if (!elementsOutOfSynchWithBuffers.contains(this))
                return;
            elementsOutOfSynchWithBuffers.remove(this);
        }

        openWhenClosed(createElementInfo(), monitor);
    }

the above method is what i use, because i also did see double parsing and so on.

And we also use very large files so it was noticeable..


On Sun, Apr 15, 2012 at 22:22, Jae Gangemi <jgangemi@xxxxxxxxx> wrote:
hello all -

  i'm noticing some kind of ISourceModuleInfo cache miss occuring in the SourceParserUtil.

  when i double click on a document to open in the editor, the ISourceModuleInfo is requested (line 48 of SourceParserUtil) is NOT the same object that is returned when SourceParserUtil gets invoked by the folding structure code, but it is the same object when the Reconcile thread fires next.

  the double parse is causing some slow downs on more complex objects.

  i've tried stepping through the code numerous times trying to track down the issue, but i haven't been able to figure out why the objects aren't the same. hopefully someone on the list can help. :)

--
-jae

_______________________________________________
dltk-dev mailing list
dltk-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/dltk-dev



Back to the top