Skip to content

Conversation

@bjorng
Copy link
Contributor

@bjorng bjorng commented Aug 26, 2025

The BEAM code resulting from complex binary match code sometimes repeats a test that has failed. This pull request eliminates some of those repeated tests. That can result in a considerable code size reduction for functions doing complex binary matching. Here are some example of modules where that happened: dets_v9, ssl_gen_statem, ssl_handshake, and zip.

This optimization also avoids repeating a failed call to a guard BIF.

The BEAM code resulting from complex binary match code sometimes
repeats a test that has failed. This commit eliminates some of those
repeated tests. That can result in a considerable code size reduction
for functions doing complex binary matching. Here are some example of
modules where that happened: `dets_v9`, `ssl_gen_statem`,
`ssl_handshake`, and `zip`.

This optimization also avoids repeating a failed call to a guard BIF.
@bjorng bjorng requested review from jhogberg and lucioleKi August 26, 2025 06:51
@bjorng bjorng self-assigned this Aug 26, 2025
@bjorng bjorng added team:VM Assigned to OTP team VM enhancement labels Aug 26, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Aug 26, 2025

CT Test Results

    2 files    333 suites   8m 32s ⏱️
  850 tests   846 ✅ 4 💤 0 ❌
5 587 runs  5 583 ✅ 4 💤 0 ❌

Results for commit e672410.

♻️ This comment has been updated with latest results.

To speed up review, make sure that you have read Contributing to Erlang/OTP and that all checks pass.

See the TESTING and DEVELOPMENT HowTo guides for details about how to run test locally.

Artifacts

// Erlang/OTP Github Action Bot

@bjorng bjorng added the testing currently being tested, tag is used by OTP internal CI label Aug 26, 2025
@bjorng bjorng added this to the OTP-29.0 milestone Aug 26, 2025
@bjorng bjorng merged commit 8df402d into erlang:master Sep 1, 2025
25 checks passed
@bjorng bjorng deleted the bjorn/compiler/shortcut-succeeded branch September 1, 2025 11:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement team:VM Assigned to OTP team VM testing currently being tested, tag is used by OTP internal CI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants