<div class="__aliyun_email_body_block"><div  style="font-family: Tahoma, Arial, STHeitiSC-Light, SimSun"><div  style="clear: both;"><span ></span><span >When parsing date/time strings, DateTimeFormatter creates HashMaps to store intermediate parsed values. HashMap has more overhead for operations compared to specialized map implementations.</span><div  style="clear: both;"><br ></div><div  style="clear: both;">Since ChronoField is an enum and all keys in these maps are ChronoField instances, we can use EnumMap instead, which provides better performance for enum keys due to its optimized internal structure.</div><div  style="clear: both;"><br ></div><div  style="clear: both;">Parsing scenarios show improvements from 12% to 95%.</div><div  style="clear: both;"><br ></div><span >To better express my ideas, I submitted a draft PR: <a  href="https://github.com/openjdk/jdk/pull/28471" target="_blank">https://github.com/openjdk/jdk/pull/28471</a> , and I hope you can give me feedback.</span><span ></span></div><div  style="clear: both;"><span ><br ></span></div><div  style="clear: both;"><span >-</span></div><div  style="clear: both;"><span >Shaojin Wen</span></div><div  style="clear: both;"><span ><br ></span></div><div  style="clear: both;"><span ><br ></span></div></div></div>