Repository navigation
benchmark fpu cleanup - #12098
benchmark fpu cleanup#12098philljj wants to merge 3 commits into
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
Active error-path defects can cause FPU use without acquiring vector registers and an unmatched restore, or allow decryption to proceed with uninitialized ciphertext after encryption fails.
2 open issues
What changed in this PR
This PR cleans up floating-point and vector-register handling in wolfCrypt benchmarks, targeting kernel-build issues found during FreeBSD testing.
Changes:
- Adds save/restore calls around DH peer-key generation.
- Routes ECIES errors through statistics finishers so vector registers are restored.
- Removes unreachable Linux-specific FPU handling in favor of the shared save/restore mechanism.
| File | Description |
|---|---|
wolfcrypt/benchmark/benchmark.c |
Updates DH and ECIES register handling and removes redundant Linux FPU branches. |
Review effort: Balanced
|
wolfSSL-Fenrir-bot
left a comment
There was a problem hiding this comment.
Fenrir Automated Review — PR #12098
Scan targets checked: wolfssl-pr-general
Review type: general (no scan target covers the changed files)
Coverage: 1 of 1 in-scope changed file(s) opened by the reviewer
Fenrir result: Approved ✅
No new issues found in the changed files.
Advisory only — this automated result does not count as a GitHub approval.
Review tier: Max
|
Retest this please. (PRB fips test failure, not clear) |


Description
Some fpu cleanup in wolfcrypt
benchmark.c:kernel_fpu_begin(),kernel_fpu_end()calls.The LINUXKM blocks were unreachable because
linuxkm/linuxkm_wc_port.halways definedWOLFSSL_USE_SAVE_VECTOR_REGISTERSifWOLFSSL_LINUXKM_BENCHMARKS.note: discovered when testing on FreeBSD 16.0.
fixes: zd22741.
Testing
14.3-RELEASE16.0-CURRENTmulti-test:
all-gcc-c89,c89-clang-tidy,wolfssl-all, etc.