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

Address trigger has higher priority than alignment #387

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

timsifive
Copy link
Collaborator

Used this test to confirm that
riscv-software-src/riscv-isa-sim#1013 works
right.


# Slow path because CSR was *just* written. (This is spike-specific.)
sw x0, (a2)
beqz a2, fail
Copy link
Collaborator

Choose a reason for hiding this comment

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

Presumably this branch should be removed since the store can't possibly write x2?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Good point. Definitely a cut and paste issue. I just removed the checks, since if the trigger didn't match then you end up with an unaligned exception which will cause the test to fail.

# Fast path
li TESTNUM, 18
sw x0, (a2)
beqz a2, fail
Copy link
Collaborator

Choose a reason for hiding this comment

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

Same here. Or I guess if you're trying to make sure the store didn't write memory, you'd need to store a nonzero value and lb a byte of it back to see if it's still zero.

@timsifive timsifive requested a review from aswaterman June 1, 2022 16:02
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