Skip to content

Refactor try_step() some more #883

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

Merged
merged 1 commit into from
Apr 27, 2025
Merged

Conversation

Timmmm
Copy link
Collaborator

@Timmmm Timmmm commented Apr 25, 2025

  • Simplify the stepped code. It is equivalent to whether or not the model ends in an active state, so we can just return that.
  • Simplify handling of minstret_increment.
  • Change step_no to nat.
  • Remove unused exit_wait parameter from run_hart_active().
  • Change instbits to 32-bit instead of xlenbits.

* Simplify the `stepped` code. It is equivalent to whether or not the model ends in an active state, so we can just return that.
* Simplify handling of `minstret_increment`.
* Change `step_no` to `nat`.
* Remove unused `exit_wait` parameter from `run_hart_active()`.
* Change `instbits` to 32-bit instead of xlenbits.
@Timmmm Timmmm requested a review from pmundkur April 25, 2025 12:04
Copy link

Test Results

400 tests  ±0   400 ✅ ±0   1m 54s ⏱️ ±0s
  1 suites ±0     0 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit 50ac5fa. ± Comparison against base commit 5872942.

Copy link
Collaborator

@pmundkur pmundkur left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is nice refactor, with clearer comments. Thanks!

Copy link
Collaborator

@jordancarlin jordancarlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Timmmm Timmmm added the will be merged Scheduled to be merged in a few days if nobody objects label Apr 25, 2025
@Timmmm Timmmm merged commit 292ebf4 into riscv:master Apr 27, 2025
3 checks passed
@Timmmm Timmmm deleted the user/timh/simplify_step branch April 29, 2025 14:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
will be merged Scheduled to be merged in a few days if nobody objects
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants