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

How best to use rmem to check a simulation execution #18

Open
VarunKoyyalagunta opened this issue Dec 31, 2021 · 0 comments
Open

How best to use rmem to check a simulation execution #18

VarunKoyyalagunta opened this issue Dec 31, 2021 · 0 comments

Comments

@VarunKoyyalagunta
Copy link

I want to use rmem to verify the execution of a riscv cpu verilog simulation.

I can grab all the required info from the simulation, eg instruction 1 wrote to memory 0x1000/8=1, instruction 2 read from store buffer 0x1000/8=1, instruction 3 read from memory 0x1000/8=1, etc. I then want to check that those simulation results are a valid RVWMO execution.

My idea is to add a step_string instruction to rmem. Given a string argument, it will search the enabled transitions for that string. If it finds one transition that contains that string, then it will take that transition. Eg, one could do

step_string "satisfy memory read by forwarding from writes: (0:3:0):R 0x0000000000001000/8 from (0:2:0):W 0x0000000000001000/8=1"

I can create the above command, and ones like it, directly from a simulation trace and feed it to rmem to check the execution.

Does that sound reasonable? Would you recommend something else?

I've implemented a primitive step_string in rmem myself and it's working on my manually written toy examples.

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

No branches or pull requests

1 participant