diff --git a/mach/proto/ncg/compute.c b/mach/proto/ncg/compute.c index d32417e68..7761976f8 100644 --- a/mach/proto/ncg/compute.c +++ b/mach/proto/ncg/compute.c @@ -14,6 +14,9 @@ static char rcsid[] = "$Id$"; #include "result.h" #include "glosym.h" #include "extern.h" +#ifdef REGVARS +#include "regvar.h" +#endif #ifdef USE_TES #include "label.h" #endif diff --git a/mach/proto/ncg/fillem.c b/mach/proto/ncg/fillem.c index 447faeb41..e2ad5028c 100644 --- a/mach/proto/ncg/fillem.c +++ b/mach/proto/ncg/fillem.c @@ -365,7 +365,6 @@ dopseudo() { } else if (argval == ms_reg) { long r_off; int r_size,r_type,r_score; - struct regvar *linkreg(); if (!regallowed) error("mes 3 not allowed here"); diff --git a/mach/proto/ncg/regvar.c b/mach/proto/ncg/regvar.c index 934b775f8..f39134892 100644 --- a/mach/proto/ncg/regvar.c +++ b/mach/proto/ncg/regvar.c @@ -28,7 +28,7 @@ extern string myalloc(); struct regvar *rvlist; struct regvar * -linkreg(of,sz,tp,sc) long of; { +linkreg(long of, int sz, int tp, int sc) { register struct regvar *rvlp; rvlp= (struct regvar *) myalloc(sizeof *rvlp); @@ -43,7 +43,7 @@ linkreg(of,sz,tp,sc) long of; { } void -tryreg(rvlp,typ) register struct regvar *rvlp; { +tryreg(struct regvar *rvlp, int typ) { int score; register i; register struct regassigned *ra; @@ -100,7 +100,8 @@ tryreg(rvlp,typ) register struct regvar *rvlp; { } } -fixregvars(saveall) { +void +fixregvars(int saveall) { register struct regvar *rv; register rvtyp,i; @@ -141,7 +142,8 @@ fixregvars(saveall) { f_regsave(); } -isregvar(off) long off; { +int +isregvar(long off) { register struct regvar *rvlp; for(rvlp=rvlist;rvlp!=0;rvlp=rvlp->rv_next) @@ -150,7 +152,8 @@ isregvar(off) long off; { return(-1); } -isregtyp(off) long off; { +int +isregtyp(long off) { register struct regvar *rvlp; for(rvlp=rvlist;rvlp!=0;rvlp=rvlp->rv_next) @@ -159,7 +162,8 @@ isregtyp(off) long off; { return(-1); } -unlinkregs() { +void +unlinkregs(void) { register struct regvar *rvlp,*t; register struct regassigned *ra; int rvtyp,i; diff --git a/mach/proto/ncg/regvar.h b/mach/proto/ncg/regvar.h index e04350356..2a66ddc4d 100644 --- a/mach/proto/ncg/regvar.h +++ b/mach/proto/ncg/regvar.h @@ -21,3 +21,10 @@ struct regassigned { extern struct regvar *rvlist; extern int nregvar[]; extern struct regassigned *regassigned[]; + +struct regvar *linkreg(long, int, int, int); +void tryreg(struct regvar *, int); +void fixregvars(int); +int isregvar(long); +int isregtyp(long); +void unlinkregs(void); diff --git a/mach/proto/ncg/subr.c b/mach/proto/ncg/subr.c index 69d4493be..0c14fa410 100644 --- a/mach/proto/ncg/subr.c +++ b/mach/proto/ncg/subr.c @@ -13,6 +13,9 @@ static char rcsid[] = "$Id$"; #include "data.h" #include "result.h" #include "extern.h" +#ifdef REGVARS +#include "regvar.h" +#endif /* * (c) copyright 1987 by the Vrije Universiteit, Amsterdam, The Netherlands.