The proposed change is to improve the speed and memory performance of String.toLowerCase/toUpperCase by
(1) separate the "normal" use scenario (not supplementary character, no special case mappping handling) into a simple/quick loop iteration code path.
(2) use the package private constructor String(char[], boolean) to avoid the char[] buffer copy in above fast-path.
(1) separate the "normal" use scenario (not supplementary character, no special case mappping handling) into a simple/quick loop iteration code path.
(2) use the package private constructor String(char[], boolean) to avoid the char[] buffer copy in above fast-path.