API for internal state

Skip to first unread message

Rajeev Kumar

Feb 6, 2023, 8:30:50 PMFeb 6
can someone help me how to access registers, memory through API

Tommy Murphy

Feb 6, 2023, 9:01:52 PMFeb 6
to Rajeev Kumar, RISC-V ISA Dev
Your question doesn't really make sense as it stands.
Please explain in more detail and as clearly as possible what you mean and what exactly you want to do.
What does the subject line "API for internal state" mean?
Internal state of what?
What does "can someone help me how to access registers, memory through API" mean?
Why do you think that you need an API to access memory?
What registers are you talking about?
What target hardware/simulator are you using?
What are you trying to achieve in software?
What language are you using?
What tools?


Feb 7, 2023, 4:01:39 PMFeb 7
to RISC-V ISA Dev, rajeevr...@gmail.com
On Monday, February 6, 2023 at 7:30:50 PM UTC-6 rajeevr...@gmail.com wrote:
can someone help me how to access registers, memory through API

There are times when the registers are in "the registers", on the kernel stack, or
in memory. If you are in a remote heart you cannot access the other heart's
registers. If you are a kernel thread, it is still extraordinarily hard to properly
access a threads registers while they are on the kernel stack with any degree
of reliability. So, in general it is best to wait until any kernel activities have been 
cleaned up and the thread registers are in a known place in memory--AND--that
the thread is locked against being Activated into execution. This is the state a
debugger accesses a threads registers and memory.

Tommy Murphy

Feb 7, 2023, 4:14:31 PMFeb 7
to MitchAlsup, RISC-V ISA Dev, rajeevr...@gmail.com
Hi Mitch

I'm not really sure what question you're attempting to answer given that, as I've already said, the original post was so vague as to be arguably meaningless.

I think it would be better, and more productive, for the original poster to clarify the question(s) and maybe some of the issues that I asked about.

Just my tuppence worth... :⁠-⁠)



Feb 7, 2023, 4:16:28 PMFeb 7
to RISC-V ISA Dev, Tommy Murphy, rajeevr...@gmail.com, MitchAlsup
Not really trying to answer his question, as to point out how hard it would be
to answer his question.

Reply all
Reply to author
0 new messages