Skip to content

Commit

Permalink
cmd/compile: remove auxSymInt32
Browse files Browse the repository at this point in the history
We never used it, might as well get rid of it.

Change-Id: I5c23c93e90173bff9ac1fc1b8ae1e2025215d6eb
Reviewed-on: https://go-review.googlesource.com/c/go/+/191938
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
  • Loading branch information
randall77 committed Aug 28, 2019
1 parent a8c2e5c commit b91b3d9
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 11 deletions.
6 changes: 0 additions & 6 deletions src/cmd/compile/internal/ssa/check.go
Original file line number Diff line number Diff line change
Expand Up @@ -155,12 +155,6 @@ func checkFunc(f *Func) {
case auxSymOff, auxSymValAndOff, auxTypSize:
canHaveAuxInt = true
canHaveAux = true
case auxSymInt32:
if v.AuxInt != int64(int32(v.AuxInt)) {
f.Fatalf("bad int32 AuxInt value for %v", v)
}
canHaveAuxInt = true
canHaveAux = true
case auxCCop:
if _, ok := v.Aux.(Op); !ok {
f.Fatalf("bad type %T for CCop in %v", v.Aux, v)
Expand Down
4 changes: 2 additions & 2 deletions src/cmd/compile/internal/ssa/gen/rulegen.go
Original file line number Diff line number Diff line change
Expand Up @@ -908,14 +908,14 @@ func parseValue(val string, arch arch, loc string) (op opData, oparch, typ, auxi
// Sanity check aux, auxint.
if auxint != "" {
switch op.aux {
case "Bool", "Int8", "Int16", "Int32", "Int64", "Int128", "Float32", "Float64", "SymOff", "SymValAndOff", "SymInt32", "TypSize":
case "Bool", "Int8", "Int16", "Int32", "Int64", "Int128", "Float32", "Float64", "SymOff", "SymValAndOff", "TypSize":
default:
log.Fatalf("%s: op %s %s can't have auxint", loc, op.name, op.aux)
}
}
if aux != "" {
switch op.aux {
case "String", "Sym", "SymOff", "SymValAndOff", "SymInt32", "Typ", "TypSize", "CCop":
case "String", "Sym", "SymOff", "SymValAndOff", "Typ", "TypSize", "CCop":
default:
log.Fatalf("%s: op %s %s can't have aux", loc, op.name, op.aux)
}
Expand Down
2 changes: 0 additions & 2 deletions src/cmd/compile/internal/ssa/op.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,6 @@ const (
auxTyp // aux is a type
auxTypSize // aux is a type, auxInt is a size, must have Aux.(Type).Size() == AuxInt
auxCCop // aux is a ssa.Op that represents a flags-to-bool conversion (e.g. LessThan)

auxSymInt32 // aux is a symbol, auxInt is a 32-bit integer
)

// A SymEffect describes the effect that an SSA Value has on the variable
Expand Down
2 changes: 1 addition & 1 deletion src/cmd/compile/internal/ssa/value.go
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ func (v *Value) auxString() string {
if v.Aux != nil {
return fmt.Sprintf(" {%v}", v.Aux)
}
case auxSymOff, auxSymInt32, auxTypSize:
case auxSymOff, auxTypSize:
s := ""
if v.Aux != nil {
s = fmt.Sprintf(" {%v}", v.Aux)
Expand Down

0 comments on commit b91b3d9

Please sign in to comment.