The motivation behind the previous context work was to enable access to the saved context in Forth, e.g. some SPARC64 bootloaders will attempt to read the saved register values.
This patch enables read-only access to the CPU registers in Forth for PPC, SPARC32 and SPARC64 whilst also implementing the IEEE-1275 .registers word.
NOTE: the primary reason this is read-only is because currently there exists no Forth CFA that can evaluate an xt and use the result as part of a "<value> to %g1" construction.
Mark Cave-Ayland (6): Make current CPU context available in Forth libopenbios: don't display output on execution of "go" word ppc: fix off-by-one error for register r4 in context switch ppc: add basic read-only Forth register support SPARC32: add basic read-only Forth register support SPARC64: add basic read-only Forth register support
arch/ppc/ppc.fs | 127 +++++++++++++++++++++++------------- arch/ppc/qemu/switch.S | 2 +- arch/sparc32/build.xml | 1 + arch/sparc32/cpu.fs | 100 +++++++++++++++++++++++++++++ arch/sparc64/build.xml | 1 + arch/sparc64/cpu.fs | 156 +++++++++++++++++++++++++++++++++++++++++++++ forth/debugging/client.fs | 6 ++ libopenbios/init.c | 4 ++ libopenbios/initprogram.c | 16 +---- 9 files changed, 354 insertions(+), 59 deletions(-) create mode 100644 arch/sparc32/cpu.fs create mode 100644 arch/sparc64/cpu.fs