Skip to content

8245309: Re-examine use of ThreadLocalCoders in sun.net.www.ParseUtil #170

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from

Conversation

FrauBoes
Copy link
Member

@FrauBoes FrauBoes commented Sep 15, 2020

Replaced the use of ThreadLocalCoders with regular non-caching CharsetEncoder and added a benchmark to confirm that there is no performance impact.


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8245309: Re-examine use of ThreadLocalCoders in sun.net.www.ParseUtil

Reviewers

Download

$ git fetch https://git.openjdk.java.net/jdk pull/170/head:pull/170
$ git checkout pull/170

@bridgekeeper
Copy link

bridgekeeper bot commented Sep 15, 2020

👋 Welcome back jboes! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr Pull request is ready for review label Sep 15, 2020
@openjdk
Copy link

openjdk bot commented Sep 15, 2020

@FrauBoes The following label will be automatically applied to this pull request: net.

When this pull request is ready to be reviewed, an RFR email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label (add|remove) "label" command.

@openjdk openjdk bot added the net net-dev@openjdk.org label Sep 15, 2020
@mlbridge
Copy link

mlbridge bot commented Sep 15, 2020

Webrevs

Copy link
Member

@shipilev shipilev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Drive-by benchmark comments below.

Copy link
Member

@dfuch dfuch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Julia,

The code changes look good to me. For the benchmarks, I'll defer to the experts.

best regards,

-- daniel

@openjdk
Copy link

openjdk bot commented Sep 15, 2020

@FrauBoes This change now passes all automated pre-integration checks. In addition to the automated checks, the change must also fulfill all project specific requirements

After integration, the commit message will be:

8245309: Re-examine use of ThreadLocalCoders in sun.net.www.ParseUtil

Reviewed-by: shade, dfuchs, alanb, chegar
  • If you would like to add a summary, use the /summary command.
  • To credit additional contributors, use the /contributor command.
  • To add additional solved issues, use the /issue command.

Since the source branch of this PR was last updated there have been 19 commits pushed to the master branch:

  • 60c4902: 8253016: Box.Filler components should be unfocusable by default
  • dd43533: 8253222: Shenandoah: unused AlwaysTrueClosure after JDK-8246591
  • efe3540: 8252966: CI: Remove KILL_COMPILE_ON_FATAL_ and KILL_COMPILE_ON_ANY macros
  • fbf4699: 8253040: Remove unused Matcher::regnum_to_fpu_offset()
  • 7c564e1: 8253146: C2: Purge unused MachCallNode::_arg_size field
  • 2caa20a: 8250668: Clean up method_oop names in adlc
  • 57f92d2: 8220483: Calendar.setTime(Date date) throws NPE with Date date = null
  • 65bfe09: 8253147: The javax/swing/JPopupMenu/7154841/bug7154841.java fail on big screens
  • fc36328: 8253034: Update symbol generation to accomodate Git as the SCM
  • 4020682: 8172366: Support SHA-3 based signatures
  • ... and 9 more: https://git.openjdk.java.net/jdk/compare/9ea43a9213e560f5a2b9c762677e8ad94a44a1d7...master

As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid automatic rebasing, please merge master into your branch, and then specify the current head hash when integrating, like this: /integrate 60c4902f613acc6be79d1abc08fbd07ca686c004.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Sep 15, 2020
@openjdk openjdk bot removed the ready Pull request is ready to be integrated label Sep 15, 2020
@FrauBoes
Copy link
Member Author

Updated benchmark results:

before
Benchmark Mode Cnt Score Error Units
ThreadLocalParseUtil.appendEncodedTest avgt 5 777.917 ± 22.970 ns/op
ThreadLocalParseUtil.decodeTest avgt 5 2.274 ± 0.056 ns/op

after
Benchmark Mode Cnt Score Error Units
ThreadLocalParseUtil.appendEncodedTest avgt 5 803.085 ± 84.102 ns/op
ThreadLocalParseUtil.decodeTest avgt 5 2.446 ± 0.203 ns/op

Copy link
Member

@shipilev shipilev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Benchmark code looks good otherwise.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Sep 16, 2020
Copy link
Contributor

@AlanBateman AlanBateman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated changes to ParseUtil look good.

Copy link
Member

@dfuch dfuch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated changes look good to me as well.

@FrauBoes
Copy link
Member Author

/integrate

@openjdk openjdk bot closed this Sep 16, 2020
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Sep 16, 2020
@openjdk
Copy link

openjdk bot commented Sep 16, 2020

@FrauBoes Since your change was applied there have been 19 commits pushed to the master branch:

  • 60c4902: 8253016: Box.Filler components should be unfocusable by default
  • dd43533: 8253222: Shenandoah: unused AlwaysTrueClosure after JDK-8246591
  • efe3540: 8252966: CI: Remove KILL_COMPILE_ON_FATAL_ and KILL_COMPILE_ON_ANY macros
  • fbf4699: 8253040: Remove unused Matcher::regnum_to_fpu_offset()
  • 7c564e1: 8253146: C2: Purge unused MachCallNode::_arg_size field
  • 2caa20a: 8250668: Clean up method_oop names in adlc
  • 57f92d2: 8220483: Calendar.setTime(Date date) throws NPE with Date date = null
  • 65bfe09: 8253147: The javax/swing/JPopupMenu/7154841/bug7154841.java fail on big screens
  • fc36328: 8253034: Update symbol generation to accomodate Git as the SCM
  • 4020682: 8172366: Support SHA-3 based signatures
  • ... and 9 more: https://git.openjdk.java.net/jdk/compare/9ea43a9213e560f5a2b9c762677e8ad94a44a1d7...master

Your commit was automatically rebased without conflicts.

Pushed as commit e0cf023.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@FrauBoes FrauBoes deleted the 8245309 branch December 7, 2020 09:33
naotoj added a commit to naotoj/jdk that referenced this pull request Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integrated Pull request has been integrated net net-dev@openjdk.org
Development

Successfully merging this pull request may close these issues.

5 participants