> This patch improves `UnixPath.encode` by reusing `JLA.getBytesNoRepl` (which 
> has fast-paths for common encoding) and avoiding a `toCharArray` call on the 
> input by refactoring the `normalizeNativePath` code to operate on `String`. 
> This might have a cost on files on Mac that need additional native 
> normalization.
> 
> This removes another `ThreadLocal` and a source of `SoftReference`s. Together 
> with the UTF-8 fast-path my UTF-8 encoded file system see substantial 
> speed-ups in a trivial `new File(str).toPath()` microbenchmark.

Claes Redestad has updated the pull request incrementally with one additional 
commit since the last revision:

  Move JLA to top, add imports

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

Changes:
  - all: https://git.openjdk.java.net/jdk/pull/2135/files
  - new: https://git.openjdk.java.net/jdk/pull/2135/files/18c3105b..b023c0a5

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

  Stats: 8 lines in 1 file changed: 5 ins; 3 del; 0 mod
  Patch: https://git.openjdk.java.net/jdk/pull/2135.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/2135/head:pull/2135

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

Reply via email to