This patch adds the ability for ScriptedThread to load artificial stack
frames. To do so, the interpreter instance can create a list that will
contain the frame index and its pc address.
Then, when the Scripted Process plugin stops, it will refresh its
Scripted Threads state by invalidating their register context and load
to list from the interpreter object and reconstruct each frame.
This patch also removes all of the default implementation for
get_stackframes from the derived ScriptedThread classes, and add the
interface code for the Scripted Thread Interface.
rdar://88721095
Signed-off-by: Med Ismail Bennani <medismail.bennani@gmail.com>
The GetStackFrames call should take a Status parameter, in case it has some good reason why it couldn't fetch the stack frames. It will make debugging these things a lot easier if you can pass the real error back to yourself.