Skip to content

tracer memory corruption + independent fixes - #479

Open
Atraxus wants to merge 12 commits into
hz-b:masterfrom
Atraxus:master
Open

Atraxus wants to merge 12 commits into
hz-b:masterfrom
Atraxus:master

Conversation

@Atraxus

@Atraxus Atraxus commented Sep 16, 2026 •

Copy link
Copy Markdown
Collaborator

Type of Change

  • Bug fix (non breaking change, fixing an issue)
  • New feature
  • Breaking change (fix or feature that causes existing functionality to not work as expected)
  • Documentation / Wiki update

Description

Fixes a memory corruption in non-sequential tracing: the source event took slot 0, then the hit loop stored at hitIndex + 1 over [0, maxEvents), so a ray still hitting elements at the end wrote one event past its allotment into the neighbouring attribute buffer. This affects any non-sequential trace where a ray reaches the event ceiling — on UE112 it corrupted two events and aborted the CSV writer mid-file. Elements now get maxEvents - 1 with the source slot reserved. Also includes three independent fixes found along the way — ElementTypeToString missing Undefined and RayListSource (throws under --verbose on ray-list beamlines, now with a Count sentinel and round-trip test), a missing else in ObjectMask::setShouldRecordObject, and the UI aborting with element id: -1 when opening CLI-traced files — plus a clang-format pass and a docs note recording 19 as the reference version. 130/130 tests; every commit builds and is format-clean.

Addition: Fix for the rotation of the paraboloid added, which was not applied correctly before. This now follows what the ellipsoid and RAY-UI already did.


✅ Pre-Merge Checklist

Important

By requesting a review, you confirm this PR is complete from your side. Once approved, it may be merged by someone else. Both developers and reviewers must ensure the PR is truly ready for merge when all checks are green.

Please complete each item before requesting a review.

  • Code follows the project's coding standards
  • Unit tests for new functionality are added and pass
  • All existing tests pass
  • Resolved TODO Comments (prefer new issues instead)
  • Documentation, if applicable, including:
    • Doxygen comments for any new rayx-core API functions
    • Helpful inline comments where needed for clarity
    • Wiki pages, e.g. updated build instructions, new Element etc.
  • Commits:
    • Use clear and readable commit messages (e.g. Conventional commits)
    • Squash and rebase onto master if individual commits don’t add value
    • Ensure linear commit history (required by master)

@Atraxus
Atraxus force-pushed the master branch 2 times, most recently from 61299ba to 67bb03c Compare September 16, 2026 15:43
@Atraxus Atraxus changed the title Fixing RAYX drift away from RAY-UIs rml standard tracer memory corruption + independent fixes Sep 16, 2026
@Atraxus
Atraxus marked this pull request as ready for review September 22, 2026 13:51

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant