JDK-7165102 : Only run assertion on Integer autoboxing cache size once
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.lang
  • Affected Version: 8
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • OS: generic
  • CPU: generic
  • Submitted: 2012-04-27
  • Updated: 2012-05-30
  • Resolved: 2012-05-30
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 b40Fixed
Related Reports
Relates :  
Description
The JLS mandates a certain range of integers from -128 to 127 to cached by the autoboxing mechanism, JSL 5.1.7.  An assert checking one end of this range appears in Integer.valueOf.  However, it would be sufficient, and more efficient, to have the assert only run once in the initialization of the IntegerCache class used to store the cached data.

Comments
EVALUATION http://hg.openjdk.java.net/jdk8/tl/jdk/rev/bb2cefc89bc0
09-05-2012

EVALUATION A fine idea.
27-04-2012