JDK-8010849 : (str) Optimize StringBuilder.append(null)
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.lang
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2013-03-26
  • Updated: 2013-05-23
  • Resolved: 2013-04-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8 b86Fixed
Related Reports
Relates :  
Description
Martin Buchholz <martinrb@google.com> writes:

One of our users noticed that a lot of CPU time was being spent in StringBuilder.append(null).
We can apply the previously proven optimization that improves it by a factor of 2 on microbenchmarks.
Comments
This change actually breaks StringBuffer synchronization in the null case - see 8014814.
21-05-2013

http://cr.openjdk.java.net/~martin/webrevs/openjdk8/StringBuilder.appendNull/
26-03-2013