summaryrefslogtreecommitdiff
path: root/parse-opcodes
diff options
context:
space:
mode:
authorGravatar Benjamin Barenblat <bbaren@google.com>2016-03-10 10:32:30 -0500
committerGravatar Benjamin Barenblat <bbaren@google.com>2016-03-10 10:32:30 -0500
commit7df34219bfd75086415583689e6230d3791b6187 (patch)
tree83e8703bb13256806f5b572a2c12a0961c11b495 /parse-opcodes
parent0f4ae756c1af09883d930c04368f9e1c3aa1de6d (diff)
Go: Update parse-opcodes to use obj.As
Diffstat (limited to 'parse-opcodes')
-rwxr-xr-xparse-opcodes8
1 files changed, 6 insertions, 2 deletions
diff --git a/parse-opcodes b/parse-opcodes
index 0f7d449..79a1f0f 100755
--- a/parse-opcodes
+++ b/parse-opcodes
@@ -787,7 +787,11 @@ def make_go():
print
print 'package riscv'
print
- print 'import "log"'
+ print 'import ('
+ print '\t"log"'
+ print
+ print '\t"cmd/internal/obj"'
+ print ')'
print
print 'type inst struct {'
print '\topcode uint32'
@@ -796,7 +800,7 @@ def make_go():
print '\tfunct7 uint32'
print '}'
print
- print 'func encode(a int16) *inst {'
+ print 'func encode(a obj.As) *inst {'
print '\tswitch a {'
for name in namelist:
print_go_insn(name)