Peter Maydell writes: > For semihosting for Arm what matters is "what state is the core > in at the point where it makes the semihosting SVC/HLT/etc insn?". Ok, that means we *aren't* talking about -mabi=ilp32, which is good -- in my current picolibc implementation, the semihosting code uses a pure 64-bit interface for aarch64 targets, even when using ilp32 ABI. > How does RISCV specify it? Because the ISA is identical between 64- and 32- bit (and 128-bit) execution modes, the only difference between the two is the Machine XLEN value which encodes the native base integer ISA width. You switch modes by modifying this value. I don't know of any implementation in hardware or software that supports modifying this value. I'm not sure we need to support this in the semihosting code for qemu as I'm pretty sure getting qemu to support dynamic XLEN values would be a large project (a project which I don't personally feel would offer much value). -- -keith