Bug 135083 - RangeUtil#isInInterval(...) takes significant amount of time while editing
Summary: RangeUtil#isInInterval(...) takes significant amount of time while editing
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.2 RC1   Edit
Assignee: David Audel CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
Depends on:
Blocks:
 
Reported: 2006-04-05 12:57 EDT by Jerome Lanneluc CLA
Modified: 2006-04-21 12:22 EDT (History)
2 users (show)

See Also:


Attachments
Proposed improvement (3.90 KB, patch)
2006-04-06 05:50 EDT, David Audel CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jerome Lanneluc CLA 2006-04-05 12:57:34 EDT
N20060405-0010

While editing class GenericTypeTests (adding a method at the end of the CU), my profiler indicates that 34% of the time is spent in RangeUtil#isInInterval(...).
Comment 1 David Audel CLA 2006-04-06 05:50:44 EDT
Created attachment 37858 [details]
Proposed improvement
Comment 2 David Audel CLA 2006-04-06 05:56:16 EDT
Jerome has profiled with the patch and time spent is now near 5%.

This patch avoid to scan all tokens inside method body and doesn't search intervals to avoid in all the array of intervals.
Comment 3 Philipe Mulet CLA 2006-04-06 11:19:19 EDT
+1 for 3.2RC1
Comment 4 David Audel CLA 2006-04-07 04:35:45 EDT
Fix released.
Comment 5 Maxime Daniel CLA 2006-04-13 12:09:36 EDT
Verified for 3.2 RC1 using Build id: I20060413-0010.
Comment 6 Jerome Lanneluc CLA 2006-04-21 12:22:52 EDT
Added performance test FullSourceWorkspaceModelTests#testPerfReconcileBigFileWithSyntaxError()