Bug 95710 - [implementation] Open NLS wizard can take minutes
Summary: [implementation] Open NLS wizard can take minutes
Status: VERIFIED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Text (show other bugs)
Version: 3.1   Edit
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: 3.1 RC2   Edit
Assignee: Dani Megert CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
Depends on:
Blocks:
 
Reported: 2005-05-18 03:50 EDT by Martin Aeschlimann CLA
Modified: 2005-06-08 12:01 EDT (History)
0 users

See Also:


Attachments
Trace (4.91 KB, application/x-zip-compressed)
2005-05-26 08:37 EDT, Tobias Widmer CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Aeschlimann CLA 2005-05-18 03:50:52 EDT
M7

open the NLS wizard on 'AdvancedQuickAssistTest' (in jdt.ui.tests)
   -> takes around a minute on my system
Comment 1 Tobias Widmer CLA 2005-05-26 08:37:21 EDT
The problem is obvious: Once more the evil plus operator...

Attaching trace
Comment 2 Tobias Widmer CLA 2005-05-26 08:37:51 EDT
Created attachment 21809 [details]
Trace
Comment 3 Dani Megert CLA 2005-05-30 11:21:02 EDT
This is not a regression - same bug in 3.0. However, it's bad enought to
consider for 3.1 RC2.

Looks like getKey() is called millions of times since adding just two string
using '+' is not that much slower than using string buffer. The real bad guy is
NLSSubstitution.generateKey(...).
Comment 4 Dani Megert CLA 2005-05-31 16:38:51 EDT
Approving for 3.1 RC2.
Fixed in HEAD.
Comment 5 David Saff CLA 2005-06-08 11:49:47 EDT
Verified in N20050608-0010 directly and through code inspection.  Dani, please
update state to VERIFIED