aboutsummaryrefslogtreecommitdiffstats
path: root/prog/encodingexec.go
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2016-10-19 14:41:46 +0200
committerDmitry Vyukov <dvyukov@google.com>2016-11-11 14:27:54 -0800
commitd3a93e8370682fa5231bc94faf11ed3681b2ac99 (patch)
treea3f5827fe456cb7cc5f47e870c6069c0497ca3e5 /prog/encodingexec.go
parent959ec07095ff4ec4423a1365e0f0f94844a77507 (diff)
sys: attach Dir to all types
Dir is a static info, so we don't need to compute, propagate and attach it in prog whenever we generate/change programs. Attach Dir to all types.
Diffstat (limited to 'prog/encodingexec.go')
-rw-r--r--prog/encodingexec.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/prog/encodingexec.go b/prog/encodingexec.go
index 239ef3514..f30cb7073 100644
--- a/prog/encodingexec.go
+++ b/prog/encodingexec.go
@@ -69,7 +69,7 @@ func (p *Prog) SerializeForExec() []byte {
if arg1.Kind == ArgData && len(arg1.Data) == 0 {
return
}
- if arg1.Dir != DirOut {
+ if arg1.Type.Dir() != sys.DirOut {
w.write(ExecInstrCopyin)
w.write(physicalAddr(arg) + w.args[arg1].Offset)
w.writeArg(arg1)