<div dir="ltr"><p>Dear Security group and members,</p><p>Hello,</p><p>I recently submitted a PR that introduces a parallel intrinsic implementation for AES/ECB operations, aiming to replace the current per-block processing approach and improve performance for multi-block encryption/decryption.</p><p>This work is motivated by several performance limitations in the existing AES/ECB/PKCS5Padding implementation (except for AVX-512 support):</p><ol><li><p><strong>Excessive stub call overhead</strong> – each 16-byte block triggers a separate intrinsic call, leading to high invocation frequency.</p></li><li><p><strong>Limited instruction-level parallelism</strong> – serialized block processing does not fully utilize available ILP.</p></li><li><p><strong>Redundant setup and teardown</strong> – encryption state is repeatedly initialized for every block.</p></li></ol><h3>Summary of changes</h3><ul><li><p>Added a parallel AES intrinsic implementation to process multiple blocks in a single native call.</p></li><li><p>Reduced intrinsic invocation overhead.</p></li><li><p>Improved utilization of instruction-level parallelism.</p></li></ul><h3>Performance results (JMH)</h3><p>Test platform: Intel(R) Core(TM) i9-14900HX<br>OpenJDK 17 baseline:</p><p>Benchmark Mode Cnt Score Error Units<br>AesTest.test avgt 5 13334.163 ± 220.891 ns/op</p><p>With optimized implementation:</p><p>Benchmark Mode Cnt Score Error Units<br>AesTest.test avgt 5 10391.371 ± 94.966 ns/op</p><p>This shows approximately <strong>28.3% performance improvement</strong>.</p><p>I would greatly appreciate your feedback on:</p><ul><li><p>The design of the parallel intrinsic approach</p></li><li><p>Any potential correctness or portability concerns</p></li><li><p>Suggestions for further optimization or alignment with HotSpot intrinsic conventions</p></li></ul><div>JBS Issue: <a disabled>https://bugs.openjdk.org/browse/JDK-8376164</a> — This issue tracks the performance improvement of AES/ECB operations by introducing a parallel intrinsic to reduce per-block overhead and enhance throughput.</div><p>I am very happy to revise or extend the patch based on your guidance.<br>Thank you for your time and for maintaining such a great platform.</p><p>Best regards,<br>Xinyang Wu</p></div>