Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve memory testing #766

Merged
merged 3 commits into from
May 3, 2024
Merged

Improve memory testing #766

merged 3 commits into from
May 3, 2024

Conversation

dani-garcia
Copy link
Member

@dani-garcia dani-garcia commented May 3, 2024

Type of change

- [ ] Bug fix
- [ ] New feature development
- [x] Tech debt (refactoring, code cleanup, dependency upgrades, etc)
- [ ] Build/deploy pipeline (DevOps)
- [ ] Other

Objective

Improve how the memory-testing crate does some things:

  • Compile and run the process in release mode, to better match what our final artifacts will do.
  • Improve the structure of Cases struct, now the values that we want to look up in memory are generic, which greatly simplifies the analyze-dumps binary.
  • Removed the test string from the table output, if we don't find the test string in the dump we assume the dump is invalid and return directly.
  • Instead of waiting a predefined amount of time, the dump program now waits for the program to notify that it's ready, which speeds up the operations a bit.
  • Use black_box instead of just printing the values, to ensure the compiler doesn't optimize them out.

Copy link
Contributor

github-actions bot commented May 3, 2024

Logo
Checkmarx One – Scan Summary & Details13fb89cb-ea74-4956-bb30-cbb6eaebdc5e

No New Or Fixed Issues Found

Copy link

codecov bot commented May 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 61.74%. Comparing base (a2495b7) to head (b335273).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #766   +/-   ##
=======================================
  Coverage   61.74%   61.74%           
=======================================
  Files         173      173           
  Lines       10934    10934           
=======================================
  Hits         6751     6751           
  Misses       4183     4183           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dani-garcia dani-garcia merged commit 7e57f19 into main May 3, 2024
78 of 79 checks passed
@dani-garcia dani-garcia deleted the ps/improve-memory-testing branch May 3, 2024 16:17
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.

2 participants