test(relinker): cover unsupported CIE version in unwind record parsing #14527
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/14527"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by slopgobblercobbler on 2026-11-01T15:27:43Z.
What
Cover unsupported CIE version (!= 1, 3, 4) in unwind record parsing with unit tests in UnwindRecordBoundsTests.cpp.
Tested
Built and executed unwind_record_bounds_tests.exe successfully (all 86 cases passed).
Checklist
Imported from boykopovar/AnyPS5. Originally posted by BunnyFl on 2026-11-02T01:26:43Z.
Review: APPROVED
Windows 11, WinLibs GCC 15.2.0 r7, relinker-only Release. Head 03598c6f5c merged into upstream/main
93dbd0f82a:unwind_record_bounds_tests:34 unwind record cases passed.EhFrameReader.cpp:165disabled, this branch's test fails (Unwind record validation failed, exit 1), while main's test still passes (30 cases). So the new cases cover the check, and matching on theunsupported CIE versionmessage keeps them from passing on another error.Heads-up: #14513 and #14573 replace the same
"30 unwind record cases passed"line, so this will conflict with whichever merges first.Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-02T04:45:45Z.
Review: COMMENTED
Reviewed — no blocking findings
The new cases feed the relinker's
eh_framereader four unsupported CIE versions (0, 2, 5 and 255) and expect the "unsupported CIE version" rejection. The reader accepts versions 1, 3 and 4 and rejects others with that message (EhFrameReader.cpplines 164-165), and the byte layout of the test record matches the reader's order (length, zero identifier, then version). The relinker jobs passed at this head; I did not confirm that they runUnwindRecordBoundsTests.What I ran
03598c6f5cc8c1cd737be3abec8ecfb3a097048d; basef2d874c1fdccf781c0fa5d86619bb5dd8894b958. 1 file, +32/-1:core/relinker/relinker/tests/UnwindRecordBoundsTests.cpp.core/relinker/relinker/src/analysis/UnusedNidFilter/EhFrameReader.cpplines 159-165 at base).Results
EhFrameReader.cppline 165)Read-only check output
Precheck was not run: this session does not run code from PR heads. The read-only checks were run from the trusted main checkout. Hosted:
gh api repos/boykopovar/AnyPS5/commits/03598c6f5cc8c1cd737be3abec8ecfb3a097048d/check-runs.Negative control
Not run here. A negative control needs a build, and code from this head is not run here.
Findings
Blocking
None.
Non-blocking
None.
Sources
github.com/boykopovar/AnyPS5@f2d874c1fd/core/relinker/relinker/src/analysis/UnusedNidFilter/EhFrameReader.cpp (L159-L165)github.com/boykopovar/AnyPS5@03598c6f5c/core/relinker/relinker/tests/UnwindRecordBoundsTests.cppNot verified
UnwindRecordBoundsTestswas not confirmed.To get this to a good state
Imported from boykopovar/AnyPS5. Originally posted by MarcZX10 on 2026-11-14T04:32:38Z.
Review: APPROVED
Reviewed — looks good
The added cases exercise rejected CIE versions 0, 2, 5, and 255 against the existing unsupported-version check at the exact reviewed head
f7e40a1368e4116c548f9f5d671ae999be691e25.What I ran
No commands or tests were run in this review; source was inspected with the pinned reader.
Results
Findings
Blocking
None.
Non-blocking
None.
Not verified
The reported test run, compilation, and runtime behavior were not independently verified. The only changed file listed in the manifest was read:
core/relinker/relinker/tests/UnwindRecordBoundsTests.cpp. No files were excluded in the manifest.To get this to a good state
Nothing is required.