Hello.
As far as I know autoboxing is implemented via valueOf().
http://stackoverflow.com/questions/408661/what-code-does-the-compiler-generate-for-autoboxing

On 20.01.2014 13:42, Anthony Petrov wrote:
i Petr,

In a few places in src/share/classes/sun/awt/datatransfer/DataTransferer.java you're eliminating calls to Integer.valueOf() and instead assign the values directly. Note that this causes the auto-boxing to take place unconditionally, and thus may hurt the performance a bit. I suggest to leave the valueOf() calls as they are to take advantage of the Integer's cache. Please refer to the javadoc for this method for more details. The same suggestion applies to Long (and maybe Boolean, too?)


--
Best regards, Sergey.

Reply via email to