commit | daddeb26865e55432be7d82641e835911828feca | [log] [tgz] |
---|---|---|
author | Rob Pike <r@golang.org> | Thu Feb 26 17:09:16 2015 -0800 |
committer | Rob Pike <r@golang.org> | Fri Feb 27 03:51:33 2015 +0000 |
tree | 70dcc751f69b18bd1f535dff10dac676b96d9587 | |
parent | 95bf77bc68dec4423dec3599398e08d99c637d9b [diff] |
cmd/internal/obj: make Rconv a global function Clean up the obj API by making Rconv (register pretty printer) a top-level function. This means that Dconv (operand pretty printer) doesn't need an Rconv argument. To do this, we make the register numbers, which are arbitrary inside an operand (obj.Addr), disjoint sets for each architecture. Each architecture registers (ha) a piece of the space and then the global Rconv knows which architecture-specific printer to use. Clean up all the code that uses Dconv. Now register numbers are large, so a couple of fields in Addr need to go from int8 to int16 because they sometimes hold register numbers. Clean up their uses, which meant regenerating the yacc grammars for the assemblers. There are changes in this CL triggered by earlier changes to yacc, which had not been run in this directory. There is still cleanup to do in Addr, but we're getting closer to that being easy to do. Change-Id: I9290ebee013b62f7d24e886743ea5a6b232990ab Reviewed-on: https://go-review.googlesource.com/6220 Reviewed-by: Russ Cox <rsc@golang.org>
Go is an open source programming language that makes it easy to build simple, reliable, and efficient software.
For documentation about how to install and use Go, visit https://golang.org/ or load doc/install-source.html in your web browser.
Our canonical Git repository is located at https://go.googlesource.com/go. There is a mirror of the repository at https://github.com/golang/go.
Please report issues here: https://golang.org/issue/new
Go is the work of hundreds of contributors. We appreciate your help!
To contribute, please read the contribution guidelines: https://golang.org/doc/contribute.html
Unless otherwise noted, the Go source files are distributed under the BSD-style license found in the LICENSE file.
If you have just untarred a binary Go distribution, you need to set the environment variable $GOROOT to the full path of the go directory (the one containing this file). You can omit the variable if you unpack it into /usr/local/go, or if you rebuild from sources by running all.bash (see doc/install-source.html). You should also add the Go binary directory $GOROOT/bin to your shell's path.
For example, if you extracted the tar file into $HOME/go, you might put the following in your .profile:
export GOROOT=$HOME/go export PATH=$PATH:$GOROOT/bin
See https://golang.org/doc/install or doc/install.html for more details.