<Sound Dev> RFR: 8271603: Unnecessary Vector usage in java.desktop [v3]

Andrey Turbanov github.com+741251+turbanoff at openjdk.java.net
Wed Aug 25 08:01:55 UTC 2021


> Usage of thread-safe collection `Vector` is unnecessary. It's recommended to use `ArrayList` if a thread-safe implementation is not needed. In post-BiasedLocking times, this is gets worse, as every access is synchronized.
> I checked only places where `Vector` was used as local variable.

Andrey Turbanov has updated the pull request incrementally with two additional commits since the last revision:

 - 8271603: Unnecessary Vector usage in java.desktop
   migrate more usages. Not sure how I missed them
 - 8271603: Unnecessary Vector usage in java.desktop
   revert back to use cycle to copy into array

-------------

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/4680/files
  - new: https://git.openjdk.java.net/jdk/pull/4680/files/7a2393eb..97ca8477

Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=4680&range=02
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=4680&range=01-02

  Stats: 214 lines in 24 files changed: 26 ins; 11 del; 177 mod
  Patch: https://git.openjdk.java.net/jdk/pull/4680.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/4680/head:pull/4680

PR: https://git.openjdk.java.net/jdk/pull/4680


More information about the sound-dev mailing list