diff options
authorPřemysl Janouch <p.janouch@gmail.com>2017-07-03 07:47:13 +0200
committerPřemysl Janouch <p.janouch@gmail.com>2017-07-03 07:51:51 +0200
commit886f8179ab5355e442f5baed07c65b5b29c40ba5 (patch)
parentd1d43387e53a997cb25931efc30004711a4f6652 (diff)
Move Go to a subdir
-rw-r--r--dwarf/object-file-libc.go (renamed from gdb-object-file-libc.go)0
-rw-r--r--dwarf/object-file.go (renamed from gdb-object-file.go)0
-rw-r--r--dwarf/simple.go (renamed from gdb-experiment.go)0
4 files changed, 9 insertions, 8 deletions
diff --git a/README.adoc b/README.adoc
index 307f05e..07f8f9e 100644
--- a/README.adoc
+++ b/README.adoc
@@ -35,25 +35,26 @@ When no input file is specified, standard input is used. Similarly, the default
output filename is `a.out`. After the compilation, the resulting file can be
run on the target platform.
-You may have noticed the `gdb-experiment.go` file. It is a non-optimizing
+You may have noticed the 'dwarf' directory. `simple.go` is a non-optimizing
version of the compiler targeting Linux only that adds DWARF debugging
information mapping code locations onto lines in the `ir-dump.txt` byproduct
output file. It's been rewritten in Go since managing all those binary buffers
required to build the symbol table proved to be too painful in C.
- $ go run gdb-experiment.go [INPUT-FILE] [OUTPUT-FILE]
+ $ go run dwarf/simple.go [INPUT-FILE] [OUTPUT-FILE]
-Use `break *0x4000b7` to get a breakpoint at the first Brainfuck instruction.
+Type `break *0x4000b7` into gdb to get a breakpoint at the first Brainfuck
-There is also `gdb-object-file.go` that generates an object file that can be
-statically linked with `ld`, and `gdb-object-file-libc.go` generates an
+There is also `object-file.go` that generates an object file that can be
+statically linked with `ld`, and `object-file-libc.go` that generates an
OS-independent binary that can be linked against the libc with the C compiler:
- $ go run gdb-object-file-libc.go program.bf program.o
+ $ go run dwarf/object-file-libc.go program.bf program.o
$ cc program.o -o program
Contributing and Support
diff --git a/gdb-object-file-libc.go b/dwarf/object-file-libc.go
index d16a456..d16a456 100644
--- a/gdb-object-file-libc.go
+++ b/dwarf/object-file-libc.go
diff --git a/gdb-object-file.go b/dwarf/object-file.go
index f849be6..f849be6 100644
--- a/gdb-object-file.go
+++ b/dwarf/object-file.go
diff --git a/gdb-experiment.go b/dwarf/simple.go
index 13980fc..13980fc 100644
--- a/gdb-experiment.go
+++ b/dwarf/simple.go