Commit d49c0d71 authored by Markus Duft's avatar Markus Duft Committed by Andrew Gerrand

runtime/tiny: add destroyLock stub, and docs for additional VMs

	    updated thread.c to provide destroylock, which seems to be
	      required to link.
        updated README with different virtualization programs.

R=golang-dev, adg
CC=golang-dev
https://golang.org/cl/1746047
parent eca2ec07
...@@ -6,8 +6,7 @@ for 386 and arm. ...@@ -6,8 +6,7 @@ for 386 and arm.
386 386
It is very primitive but can run go/test/sieve.go, the concurrent It is very primitive but can run go/test/sieve.go, the concurrent
prime sieve, on a uniprocessor. It has only been tested using the prime sieve, on a uniprocessor.
Bochs emulator.
To run, first build the tools by running all.bash with GOARCH=386 To run, first build the tools by running all.bash with GOARCH=386
and GOOS set to your normal GOOS (linux, darwin). Then: and GOOS set to your normal GOOS (linux, darwin). Then:
...@@ -22,14 +21,37 @@ and GOOS set to your normal GOOS (linux, darwin). Then: ...@@ -22,14 +21,37 @@ and GOOS set to your normal GOOS (linux, darwin). Then:
8l -a sieve.8 >sieve.asm # can consult sieve.asm for debugging 8l -a sieve.8 >sieve.asm # can consult sieve.asm for debugging
dd if=/dev/zero of=disk count=10000 dd if=/dev/zero of=disk count=10000
cat bootblock 8.out | dd of=disk conv=notrunc cat bootblock 8.out | dd of=disk conv=notrunc
bochs
Use the built-in print(text string) function to print to the Use the built-in print(text string) function to print to the
console. console.
BOCHS
You may have to tweak the .bochsrc depending on your system, You may have to tweak the .bochsrc depending on your system,
and you may need to install the Bochs emulator. and you may need to install the Bochs emulator.
$ cp dot-bochsrc .bochsrc
$ $EDITOR .bochsrc # tweak it if required
$ bochs
ORACLE xVM VIRTUALBOX
Get VirtualBox installed, and the do:
... build 'disk', described above
$ VBoxManage convertfromraw disk go-tiny.vdi
$ VirtualBox
create a new VM; as disk use the go-tiny.vdi image.
start the vm.
QEMU / KVM
This should work the same for qemu and kvm (really: qemu-kvm).
... build 'disk', described above
$ qemu -hda disk
ARM ARM
......
...@@ -59,6 +59,11 @@ unlock(Lock *l) ...@@ -59,6 +59,11 @@ unlock(Lock *l)
l->key = 0; l->key = 0;
} }
void destroylock(Lock *l)
{
// nothing
}
void void
noteclear(Note *n) noteclear(Note *n)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment