mirror of
https://github.com/golang/go
synced 2024-11-25 08:07:57 -07:00
6g: fix build on Plan 9
src/cmd/6g/cgen.c src/cmd/6g/gobj.c src/cmd/6g/reg.c . dropped unused assignments; src/cmd/6g/gg.h . added varargck pragmas; src/cmd/6g/list.c . adjusted print format for ulong casts; src/cmd/6g/peep.c . dropped redundant increment; R=golang-dev CC=golang-dev, rsc https://golang.org/cl/4953049
This commit is contained in:
parent
65276933cd
commit
219c9e9c46
@ -729,9 +729,6 @@ bgen(Node *n, int true, Prog *to)
|
|||||||
if(n->ninit != nil)
|
if(n->ninit != nil)
|
||||||
genlist(n->ninit);
|
genlist(n->ninit);
|
||||||
|
|
||||||
nl = n->left;
|
|
||||||
nr = n->right;
|
|
||||||
|
|
||||||
if(n->type == T) {
|
if(n->type == T) {
|
||||||
convlit(&n, types[TBOOL]);
|
convlit(&n, types[TBOOL]);
|
||||||
if(n->type == T)
|
if(n->type == T)
|
||||||
@ -744,7 +741,6 @@ bgen(Node *n, int true, Prog *to)
|
|||||||
patch(gins(AEND, N, N), to);
|
patch(gins(AEND, N, N), to);
|
||||||
goto ret;
|
goto ret;
|
||||||
}
|
}
|
||||||
nl = N;
|
|
||||||
nr = N;
|
nr = N;
|
||||||
|
|
||||||
switch(n->op) {
|
switch(n->op) {
|
||||||
|
@ -153,3 +153,5 @@ void listinit(void);
|
|||||||
|
|
||||||
void zaddr(Biobuf*, Addr*, int, int);
|
void zaddr(Biobuf*, Addr*, int, int);
|
||||||
|
|
||||||
|
#pragma varargck type "D" Addr*
|
||||||
|
#pragma varargck type "lD" Addr*
|
||||||
|
@ -623,7 +623,6 @@ out:
|
|||||||
// but 6l has a bug, and it can't handle
|
// but 6l has a bug, and it can't handle
|
||||||
// JMP instructions too close to the top of
|
// JMP instructions too close to the top of
|
||||||
// a new function.
|
// a new function.
|
||||||
p = pc;
|
|
||||||
gins(ANOP, N, N);
|
gins(ANOP, N, N);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -133,7 +133,7 @@ Dconv(Fmt *fp)
|
|||||||
if(fp->flags & FmtLong) {
|
if(fp->flags & FmtLong) {
|
||||||
d1 = a->offset & 0xffffffffLL;
|
d1 = a->offset & 0xffffffffLL;
|
||||||
d2 = (a->offset>>32) & 0xffffffffLL;
|
d2 = (a->offset>>32) & 0xffffffffLL;
|
||||||
snprint(str, sizeof(str), "$%ud-%ud", (ulong)d1, (ulong)d2);
|
snprint(str, sizeof(str), "$%lud-%lud", (ulong)d1, (ulong)d2);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
snprint(str, sizeof(str), "$%lld", a->offset);
|
snprint(str, sizeof(str), "$%lld", a->offset);
|
||||||
|
@ -993,7 +993,6 @@ loop:
|
|||||||
if(p->from.dval == p0->from.dval)
|
if(p->from.dval == p0->from.dval)
|
||||||
if(p->from.index == p0->from.index) {
|
if(p->from.index == p0->from.index) {
|
||||||
excise(r);
|
excise(r);
|
||||||
t++;
|
|
||||||
goto loop;
|
goto loop;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -179,7 +179,6 @@ regopt(Prog *firstp)
|
|||||||
r1 = R;
|
r1 = R;
|
||||||
firstr = R;
|
firstr = R;
|
||||||
lastr = R;
|
lastr = R;
|
||||||
nvar = 0;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* control flow is more complicated in generated go code
|
* control flow is more complicated in generated go code
|
||||||
|
Loading…
Reference in New Issue
Block a user