tinygo/src/runtime/runtime_fe310_qemu.go
Ayke van Laethem 8f9419a35d targets: add hifive1-qemu for testing RISC-V bare metal in QEMU
Most tests don't pass yet, so can't add this test to the standard tests,
yet.
2019-12-07 16:47:40 +01:00

16 строки
290 Б
Go

// +build fe310,qemu
package runtime
import (
"runtime/volatile"
"unsafe"
)
// Special memory-mapped device to exit tests, created by SiFive.
var testExit = (*volatile.Register32)(unsafe.Pointer(uintptr(0x100000)))
func abort() {
// Signal a successful exit.
testExit.Set(0x5555)
}