mirror of
https://github.com/golang/go
synced 2024-11-19 15:54:46 -07:00
[dev.cc] cmd/gc, cmd/ld, runtime: minor tweaks for c2go
Change-Id: I3be69a4ebf300ad24b55b5f43fd7ad1f001c762e Reviewed-on: https://go-review.googlesource.com/4838 Reviewed-by: Rob Pike <r@golang.org>
This commit is contained in:
parent
535f29c68e
commit
2286989912
@ -118,7 +118,8 @@ EXTERN Bits ovar;
|
|||||||
EXTERN int change;
|
EXTERN int change;
|
||||||
EXTERN int32 maxnr;
|
EXTERN int32 maxnr;
|
||||||
|
|
||||||
EXTERN struct
|
typedef struct OptStats OptStats;
|
||||||
|
struct OptStats
|
||||||
{
|
{
|
||||||
int32 ncvtreg;
|
int32 ncvtreg;
|
||||||
int32 nspill;
|
int32 nspill;
|
||||||
@ -126,7 +127,9 @@ EXTERN struct
|
|||||||
int32 ndelmov;
|
int32 ndelmov;
|
||||||
int32 nvar;
|
int32 nvar;
|
||||||
int32 naddr;
|
int32 naddr;
|
||||||
} ostats;
|
};
|
||||||
|
|
||||||
|
EXTERN OptStats ostats;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* reg.c
|
* reg.c
|
||||||
|
@ -634,7 +634,7 @@ walkexpr(Node **np, NodeList **init)
|
|||||||
|
|
||||||
// Append captured variables to argument list.
|
// Append captured variables to argument list.
|
||||||
n->list = concat(n->list, n->left->enter);
|
n->list = concat(n->list, n->left->enter);
|
||||||
n->left->enter = NULL;
|
n->left->enter = nil;
|
||||||
// Replace OCLOSURE with ONAME/PFUNC.
|
// Replace OCLOSURE with ONAME/PFUNC.
|
||||||
n->left = n->left->closure->nname;
|
n->left = n->left->closure->nname;
|
||||||
// Update type of OCALLFUNC node.
|
// Update type of OCALLFUNC node.
|
||||||
|
@ -104,7 +104,7 @@ uleb128enc(uvlong v, char* dst)
|
|||||||
len++;
|
len++;
|
||||||
} while (c & 0x80);
|
} while (c & 0x80);
|
||||||
return len;
|
return len;
|
||||||
};
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
sleb128enc(vlong v, char *dst)
|
sleb128enc(vlong v, char *dst)
|
||||||
|
@ -22,6 +22,10 @@ enum {
|
|||||||
#define STACKSYSTEM 0
|
#define STACKSYSTEM 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*c2go
|
||||||
|
STACKSYSTEM = 0,
|
||||||
|
*/
|
||||||
|
|
||||||
StackSystem = STACKSYSTEM,
|
StackSystem = STACKSYSTEM,
|
||||||
|
|
||||||
StackBig = 4096,
|
StackBig = 4096,
|
||||||
|
Loading…
Reference in New Issue
Block a user