SPARC emulation: userspace program run from gdb crashes OS running in emulator
Host environment
- Operating system: Ubuntu 22.10
- OS/kernel version: Linux 6.3.0-060300rc7-generic #202304162330 SMP PREEMPT_DYNAMIC Sun Apr 16 23:37:37 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
- Architecture: x86-64
- QEMU flavor: qemu-system-sparc
- QEMU version: QEMU emulator version 7.0.0 (Debian 1:7.0+dfsg-7ubuntu2.2)
- QEMU command line:
sudo qemu-system-sparc -M SS-5 -m 128 -drive file=sparc.qcow2,bus=0,unit=0,media=disk -net nic,model=lance,macaddr=DE:AD:BE:EF:F3:E5 -net tap,ifname=tap0
Emulated/Virtualized environment
- Operating system: SUN Solaris
- OS/kernel version: SunOS unknown 5.6 Generic_105181-05 sun4m sparc SUNW,SPARCstation-5
- Architecture: SPARC
Description of problem
SPARC emulation: userspace program run from gdb crashes OS running in emulator
Steps to reproduce
As a user (not root!):
- as -Q n -K PIC -b -L mandelbrot.s
- ld -m a.out -o test
- gdb ./test
- run
`as' is from gnu binutils (binutils-2.20.1-sol26-sparc-local.gz).
Additional information
screenshot: https://imgur.com/a/JD51DJA
It could very well be a bug in my assembly code, but it is still strange that it crashes the whole system.
Edited by folkertvanheusden