Changes

Summary

  1. Bug 570078 - fixed javadoc error in SearchPattern (details)
  2. Bug 570078 - Disable meta index until deadlock issues are resolved. (details)
  3. Bug 573286 - bumped bundle versions for 4.21 (details)
  4. Bug 569069 - [performance] Optimize HashtableOfPackage (details)
  5. Bug 574203 - Lot of compiler warnings in master - reduce (details)
  6. Bug 574215 - Content assist doesn't work after else without semicolon on (details)
  7. Bug 572372 - [performance] improve getInputStreamAsCharArray (details)
  8. Bug 571310 - Fix method invocations on outer-scope variables (details)
  9. Bug 573583 - [performance] Avoid sleep for fixed period during spinning (details)
  10. Bug 574227 - [test] fixed testSourceGenAfterDirChange (details)
  11. Bug 572389 - Move jdt.core to Java 11 (details)
  12. Bug 574227 - [test] failing various Apt tests (details)
  13. Bug 573239 - use JDK 11 API where appropriate (details)
Commit c2d6207a81bedea241579f33a6bc55967920dbaf by Andrey Loskutov
Bug 570078 - fixed javadoc error in SearchPattern

Change-Id: Ibac40e87d59e443e265fba8117a07d71a7104989
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/181858
Tested-by: JDT Bot <jdt-bot@eclipse.org>
The file was modifiedorg.eclipse.jdt.core/search/org/eclipse/jdt/core/search/SearchPattern.java
Commit 4ce2883b9272dbe6a7c5b76ff500dc02904d254e by Andrey Loskutov
Bug 570078 - Disable meta index until deadlock issues are resolved.

This patch will disable meta index by default until the deadlock issues
are resolved.

Change-Id: I41a05045e6fb9c1e71a5db2fe2d78619d5f190a6
Signed-off-by: Gayan Perera <gayanper@gmail.com>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/181874
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Andrey Loskutov <loskutov@gmx.de>
The file was modifiedorg.eclipse.jdt.core/search/org/eclipse/jdt/internal/core/search/indexing/IndexManager.java
The file was modifiedorg.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/IndexManagerTests.java
Commit ee89b4d7443cf6acc84cd21621ba6af3060c542e by Andrey Loskutov
Bug 573286 - bumped bundle versions for 4.21

Change-Id: Iccbf950768dbc5f5772d1a7317d225ee74a8be48
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/181966
Tested-by: JDT Bot <jdt-bot@eclipse.org>
The file was modifiedorg.eclipse.jdt.apt.core/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.compiler.tool/pom.xml
The file was modifiedorg.eclipse.jdt.apt.core/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.tool/META-INF/MANIFEST.MF
Commit f1785daee4bc6e01623be6fc0e0047643df6a3e1 by Andrey Loskutov
Bug 569069 - [performance] Optimize HashtableOfPackage

Replace HashtableOfPackage with HashMap
HashtableOfPackage is a hotspot during compilation.

get() time is reduced from ~5ns to ~3ns for empty maps
get() time is reduced from ~14ns to less then ~12ns for non empty maps
at the cost of an additional Object allocation.
The CharArrayMap grants a smooth transition between empty map
performance and large map performance for >5 elements.

Bug: 569069
Change-Id: I45df9ee3118093e64a68aa3a547bd1a7764699db
Signed-off-by: jkubitz <jkubitz-eclipse@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/177529
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Andrey Loskutov <loskutov@gmx.de>
The file was addedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharArrayMap.java
The file was addedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharArray.java
The file was modifiedorg.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/AllJavaModelTests.java
The file was addedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharArrayMapper.java
The file was modifiedorg.eclipse.jdt.compiler.apt/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/lookup/LookupEnvironment.java
The file was modifiedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/HashtableOfPackage.java
The file was addedorg.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/compiler/map/CharArrayMapperTest.java
The file was addedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharDelegateMap.java
The file was modifiedorg.eclipse.jdt.core.tests.compiler/META-INF/MANIFEST.MF
The file was addedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharArrayHashMap.java
Commit 14e23d4926d839a278fd9abaeee1e6084c3e6f01 by Sarika Sinha
Bug 574203 - Lot of compiler warnings in master - reduce

Change-Id: I5ec9cc70ead15a9e3ca4288722a41eb0e25fc101
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/181982
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Sarika Sinha <sarika.sinha@in.ibm.com>
The file was modifiedorg.eclipse.jdt.core/.settings/.api_filters
Commit dcdb41213d2a0c255037b790a64514a84fade08e by Stephan Herrmann
Bug 574215 - Content assist doesn't work after else without semicolon on
line

Change-Id: I4cc4c5e5d16764d55f1c99fd37c2f668b40ed466
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/182070
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Stephan Herrmann <stephan.herrmann@berlin.de>
The file was modifiedorg.eclipse.jdt.core/codeassist/org/eclipse/jdt/internal/codeassist/CompletionEngine.java
The file was modifiedorg.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/CompletionTests18.java
The file was modifiedorg.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/CompletionTests3.java
Commit 680081fceaccc04731bfd58151734b054356a6d1 by Manoj Palat
Bug 572372 - [performance] improve getInputStreamAsCharArray

Streamless implementation. It's ~ 2x faster for small files.
getInputStreamAsCharArray is a hotspot during
CompilationUnit.getContents().

Change-Id: I7daf60e52cbc34997ba24164285f769f604cc515
Signed-off-by: Joerg Kubitz <jkubitz-eclipse@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/178470
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Manoj Palat <manpalat@in.ibm.com>
The file was modifiedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/Util.java
Commit 63e0f757b2acc1528310b44b3463bd2bd4858310 by Gayan Perera
Bug 571310 - Fix method invocations on outer-scope variables

When generating code for lambda expression which are generated as
outer scope variables its was not generated with outer scope access.
With the fix the CodeSnippetSingleNameReference will generate outer
scope access for both local and synthetic variables used inside
lambda statements.


Change-Id: I9b4976d117ee868b95dde052a02e36f872e3a5ac
Signed-off-by: Gayan Perera <gayanper@gmail.com>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/176748
Reviewed-by: Manoj Palat <manpalat@in.ibm.com>
Tested-by: JDT Bot <jdt-bot@eclipse.org>
The file was modifiedorg.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/eval/target/CodeSnippetRunner.java
The file was modifiedorg.eclipse.jdt.core/eval/org/eclipse/jdt/internal/eval/CodeSnippetSingleNameReference.java
The file was modifiedorg.eclipse.jdt.core.tests.compiler/src/EvalTestsTarget.zip
The file was modifiedorg.eclipse.jdt.core.tests.compiler/src/org/eclipse/jdt/core/tests/eval/CodeSnippetTest.java
Commit 3d68a94fd257ac67cb957ef8dec0f9aa2a0f7332 by Vikas Chandra
Bug 573583 - [performance] Avoid sleep for fixed period during spinning

Xtext calls performConcurrentJob during
JdtTypeProvider.findSecondaryType() with
waitingPolicy=WaitUntilReady. This waits 25ms too long in average.

Also removed sleep time after "Java indexing..."

Change-Id: I196bf0abb443a6cd25dcf2f2eb66bf6c7cb70903
Signed-off-by: Joerg Kubitz <jkubitz-eclipse@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/180686
Tested-by: Vikas Chandra <Vikas.Chandra@in.ibm.com>
Reviewed-by: Vikas Chandra <Vikas.Chandra@in.ibm.com>
The file was modifiedorg.eclipse.jdt.core/search/org/eclipse/jdt/internal/core/search/processing/JobManager.java
Commit ccabede0b1a9c0c9560a65ec4bbbca83d15bc945 by Andrey Loskutov
Bug 574227 - [test] fixed testSourceGenAfterDirChange

The creation of apt directories is not atomic and is done in two
threads in parallel. A race which thread won.

During some tests the builder thread was even so much delayed that the
folders have not been created at all.

Change-Id: I9b4e77ebf48b131ffd6c7559e7361f0e732ad8c5
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/182042
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Andrey Loskutov <loskutov@gmx.de>
The file was modifiedorg.eclipse.jdt.apt.tests/src/org/eclipse/jdt/apt/tests/MirrorUtilTests.java
The file was modifiedorg.eclipse.jdt.apt.tests/src/org/eclipse/jdt/apt/tests/PreferencesTests.java
The file was modifiedorg.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/internal/generatedfile/GeneratedSourceFolderManager.java
The file was modifiedorg.eclipse.jdt.apt.tests/src/org/eclipse/jdt/apt/tests/APITests.java
The file was modifiedorg.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/util/AptConfig.java
Commit 32abdfb9c5100e8c2ff7669768b7d7fcc83c7e23 by Andrey Loskutov
Bug 572389 - Move jdt.core to Java 11

Change-Id: I7c0c41986c711a8e271a34a8dadf355c3602f2e7
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/182172
Tested-by: JDT Bot <jdt-bot@eclipse.org>
The file was modifiedorg.eclipse.jdt.core.tests.model/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.core/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.pluggable.tests/.classpath
The file was modifiedorg.eclipse.jdt.core/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.compiler.apt.tests/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.core.formatterapp/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.core/pom.xml
The file was modifiedorg.eclipse.jdt.core.formatterapp/.classpath
The file was modifiedorg.eclipse.jdt.core/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.apt.pluggable.core/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.apt.tests/pom.xml
The file was modifiedorg.eclipse.jdt.core.formatterapp/pom.xml
The file was modifiedorg.eclipse.jdt.core/pom.xml
The file was modifiedorg.eclipse.jdt.core.tests.model/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.apt/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.compiler.tool/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.tool/.classpath
The file was modifiedorg.eclipse.jdt.compiler.tool.tests/.classpath
The file was modifiedorg.eclipse.jdt.compiler.apt.tests/.classpath
The file was modifiedorg.eclipse.jdt.compiler.apt/src/org/eclipse/jdt/internal/compiler/apt/util/EclipseFileManager.java
The file was modifiedorg.eclipse.jdt.apt.pluggable.core/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.pluggable.tests/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.core.tests.performance/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.tests/.classpath
The file was modifiedorg.eclipse.jdt.core.formatterapp/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.core.ecj.validation/.classpath
The file was modifiedorg.eclipse.jdt.compiler.apt/.classpath
The file was modifiedorg.eclipse.jdt.compiler.tool/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.compiler.tool.tests/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.compiler.tool/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.core.tests.model/.classpath
The file was modifiedorg.eclipse.jdt.core.tests.performance/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.apt.tests/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.compiler.apt/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.apt.tests/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.core.tests.performance/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.apt.pluggable.tests/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.tool.tests/pom.xml
The file was modifiedorg.eclipse.jdt.apt.tests/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.apt.core/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.core.tests.performance/.classpath
The file was modifiedorg.eclipse.jdt.core.tests.model/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.core/.classpath
The file was modifiedorg.eclipse.jdt.compiler.tool.tests/META-INF/MANIFEST.MF
The file was modifiedorg.eclipse.jdt.core.ecj.validation/.settings/org.eclipse.jdt.core.prefs
The file was modifiedorg.eclipse.jdt.apt.core/.classpath
The file was modifiedorg.eclipse.jdt.compiler.apt.tests/pom.xml
The file was modifiedorg.eclipse.jdt.compiler.apt/pom.xml
The file was modifiedorg.eclipse.jdt.apt.pluggable.core/.classpath
The file was modifiedorg.eclipse.jdt.apt.pluggable.core/pom.xml
The file was modifiedorg.eclipse.jdt.apt.pluggable.tests/.settings/org.eclipse.jdt.core.prefs
Commit 298e47435e19b1217e5593f3c29652720857f6e1 by Andrey Loskutov
Bug 574227 - [test] failing various Apt tests

- clear the apt project cache that keeps wrong project references
between test runs
- wait for workspace events before configuring new source folder after
removing source folder
- wait after switching autobuild state

Change-Id: I79579102bca9545b9fc85b89c0decce64faa87f0
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/182187
Tested-by: JDT Bot <jdt-bot@eclipse.org>
The file was modifiedorg.eclipse.jdt.apt.tests/src/org/eclipse/jdt/apt/tests/APTTestBase.java
The file was modifiedorg.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/internal/generatedfile/GeneratedSourceFolderManager.java
The file was modifiedorg.eclipse.jdt.apt.tests/src/org/eclipse/jdt/apt/tests/TestUtil.java
The file was modifiedorg.eclipse.jdt.apt.core/src/org/eclipse/jdt/apt/core/internal/AptPlugin.java
Commit 2b7c3edd9892af020cb0925039813d7383aacb63 by Andrey Loskutov
Bug 573239 - use JDK 11 API where appropriate

That code was always only meant to provide BREE 8 compatibility.

Change-Id: Ifeec0b951e9f3f00041d902370a2c5034de22ef6
Signed-off-by: Joerg Kubitz <jkubitz-eclipse@gmx.de>
Reviewed-on: https://git.eclipse.org/r/c/jdt/eclipse.jdt.core/+/182165
Tested-by: JDT Bot <jdt-bot@eclipse.org>
Reviewed-by: Andrey Loskutov <loskutov@gmx.de>
The file was modifiedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/Util.java
The file was modifiedorg.eclipse.jdt.core/compiler/org/eclipse/jdt/internal/compiler/util/CharArray.java