1991-08-21 11:38:52 +00:00
|
|
|
# (c) copyright 1983 by the Vrije Universiteit, Amsterdam, The Netherlands.
|
1994-06-24 14:02:31 +00:00
|
|
|
# $Id$
|
1991-08-21 11:38:52 +00:00
|
|
|
#
|
|
|
|
# Don't generate line updating code by default (i.e.: -L flag provided to cem).
|
|
|
|
# To put it on again: use -NL
|
|
|
|
var LFLAG=-L
|
2013-05-14 21:24:38 +00:00
|
|
|
var MODULA2_INCLUDES=-I{EM}/share/ack/include/modula2
|
2013-05-12 19:45:55 +00:00
|
|
|
var OCCAM_INCLUDES=-I{EM}/share/ack/include/occam
|
|
|
|
var C_INCLUDES=-I{EM}/share/ack/include/ansi
|
1991-08-21 11:38:52 +00:00
|
|
|
|
|
|
|
callname ack
|
|
|
|
name cpp
|
|
|
|
# no from, this is a preprocessor
|
|
|
|
to .i
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/cpp.ansi
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -I* CPP_F={CPP_F?} -I*
|
|
|
|
mapflag -U* CPP_F={CPP_F?} -U*
|
|
|
|
mapflag -D* CPP_F={CPP_F?} -D*
|
|
|
|
mapflag -P CPP_F={CPP_F?} -P
|
|
|
|
mapflag -C CPP_F={CPP_F?} -C
|
|
|
|
mapflag -wo CPP_F={CPP_F?} -o
|
2007-02-20 00:46:10 +00:00
|
|
|
args {CPP_F?} \
|
|
|
|
({SUFFIX?}:.ocm={OCCAM_INCLUDES}) \
|
|
|
|
-D__{ARCH} -D__{PLATFORM} \
|
1993-08-05 11:09:12 +00:00
|
|
|
-D__ACK \
|
1991-10-07 15:29:25 +00:00
|
|
|
{SYSINCLUDES?} \
|
|
|
|
{C_INCLUDES} \
|
|
|
|
{INCLUDES?} \
|
2007-04-21 23:03:35 +00:00
|
|
|
-D{ARCH} \
|
1991-08-21 11:38:52 +00:00
|
|
|
-DEM_WSIZE={w} -DEM_PSIZE={p} \
|
2007-04-21 23:03:35 +00:00
|
|
|
-DEM_SSIZE={s} -DEM_LSIZE={l} -DEM_FSIZE={f} -DEM_DSIZE={d} \
|
1991-08-21 11:38:52 +00:00
|
|
|
-D_EM_WSIZE={w} -D_EM_PSIZE={p} \
|
|
|
|
-D_EM_SSIZE={s} -D_EM_LSIZE={l} -D_EM_FSIZE={f} -D_EM_DSIZE={d} \
|
|
|
|
<
|
|
|
|
stdout
|
|
|
|
prep is
|
|
|
|
end
|
1991-10-07 15:29:25 +00:00
|
|
|
name f77
|
|
|
|
from .f
|
|
|
|
to .c
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/f2c
|
1991-10-07 15:29:25 +00:00
|
|
|
mapflag -ansi F2_F={F2_F?} -A
|
|
|
|
mapflag -w* F2_F={F2_F?} -w*
|
|
|
|
args \
|
|
|
|
{F2_F?}
|
|
|
|
stdin
|
|
|
|
stdout
|
|
|
|
prep cond
|
|
|
|
rts .f
|
|
|
|
need .f
|
|
|
|
callname f77
|
|
|
|
callname f2c
|
|
|
|
end
|
1991-08-21 11:38:52 +00:00
|
|
|
name cem
|
|
|
|
from .c
|
|
|
|
to .k
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_cemcom.ansi
|
1991-08-21 11:38:52 +00:00
|
|
|
# mapflag -I* CPP_F={CPP_F?} -I*
|
|
|
|
# mapflag -U* CPP_F={CPP_F?} -U*
|
|
|
|
# mapflag -D* CPP_F={CPP_F?} -D*
|
|
|
|
mapflag -M* CEM_F={CEM_F?} -M*
|
|
|
|
mapflag -L CEM_F={CEM_F?} -L
|
|
|
|
mapflag -A CEM_F={CEM_F?} -A
|
|
|
|
mapflag -NL LFLAG=
|
|
|
|
mapflag -KR CEM_F={CEM_F?} -R
|
|
|
|
mapflag -w CEM_F={CEM_F?} -w
|
|
|
|
mapflag -wa CEM_F={CEM_F?} -a
|
|
|
|
mapflag -wo CEM_F={CEM_F?} -o
|
|
|
|
mapflag -ws CEM_F={CEM_F?} -s
|
1992-03-27 17:33:19 +00:00
|
|
|
mapflag -g* CEM_F={CEM_F?} -g
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -p CEM_F={CEM_F?} -p
|
|
|
|
mapflag -V* CEM_F={CEM_F?} -V*
|
|
|
|
rts .c
|
|
|
|
need .c
|
|
|
|
args \
|
|
|
|
{CPP_F?} \
|
2007-02-20 00:46:10 +00:00
|
|
|
-D__{ARCH} -D__{PLATFORM} \
|
1993-08-05 11:09:12 +00:00
|
|
|
-D__ACK \
|
1991-08-21 11:38:52 +00:00
|
|
|
{SYSINCLUDES?} \
|
1991-10-07 15:29:25 +00:00
|
|
|
{C_INCLUDES} \
|
1991-08-21 11:38:52 +00:00
|
|
|
{INCLUDES?} \
|
2007-02-20 00:46:10 +00:00
|
|
|
({ANSI_C?.xx}:.xx=-D{ARCH} \
|
1992-04-23 13:28:28 +00:00
|
|
|
-DEM_WSIZE={w} -DEM_PSIZE={p} \
|
|
|
|
-DEM_SSIZE={s} -DEM_LSIZE={l} -DEM_FSIZE={f} -DEM_DSIZE={d}) \
|
1991-08-21 11:38:52 +00:00
|
|
|
-D_EM_WSIZE={w} -D_EM_PSIZE={p} \
|
|
|
|
-D_EM_SSIZE={s} -D_EM_LSIZE={l} -D_EM_FSIZE={f} -D_EM_DSIZE={d} \
|
2013-05-21 18:18:11 +00:00
|
|
|
-Vw{w}.{wa}i{w}.{wa}p{p}.{pa}f{f}.{fa}s{s}.{sa}l{l}.{la}d{d}.{da}x{x}.{xa} \
|
1991-08-21 11:38:52 +00:00
|
|
|
{CC_ALIGN?} \
|
|
|
|
{CEM_F?} {LFLAG?} < >
|
|
|
|
callname acc
|
|
|
|
callname cc
|
|
|
|
end
|
|
|
|
name pc
|
|
|
|
from .p
|
|
|
|
to .k
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_pc
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -L PC_F={PC_F?} -L
|
|
|
|
# mapflag -s PC_F={PC_F?} -s
|
|
|
|
mapflag -_ PC_F={PC_F?} -U
|
|
|
|
mapflag -w PC_F={PC_F?} -w
|
|
|
|
mapflag -V* PC_F={PC_F?} -V*
|
|
|
|
mapflag -M* PC_F={PC_F?} -M*
|
1992-03-27 17:33:19 +00:00
|
|
|
mapflag -g* PC_F={PC_F?} -g
|
1991-08-21 11:38:52 +00:00
|
|
|
# mapflag -i* PC_F={PC_F?} -i*
|
|
|
|
mapflag -A PC_F={PC_F?} -A
|
|
|
|
# mapflag -R PC_F={PC_F?} -R
|
|
|
|
mapflag --* PC_F={PC_F?} -*
|
|
|
|
#range checks can only be disabled through comments
|
|
|
|
args \
|
|
|
|
-Vw{w}.{w}i{w}.{w}l{l}.{w}p{p}.{w}f{d}.{w}S{w}.{w} \
|
|
|
|
{PC_F?} < > {SOURCE}
|
|
|
|
prep cond
|
|
|
|
rts .p
|
|
|
|
need .p
|
|
|
|
callname apc
|
|
|
|
callname pc
|
|
|
|
end
|
|
|
|
name m2
|
|
|
|
from .mod.def
|
|
|
|
to .k
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_m2
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -I* M2_INCL={M2_INCL?} -I*
|
|
|
|
mapflag -L M2_F={M2_F?} -L
|
1995-12-04 15:01:07 +00:00
|
|
|
mapflag -g* M2_F={M2_F?} -g*
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -w* M2_F={M2_F?} -w*
|
|
|
|
mapflag -W* M2_F={M2_F?} -W*
|
|
|
|
mapflag -_ M2_F={M2_F?} -U
|
|
|
|
mapflag -M* M2_F={M2_F?} -M*
|
|
|
|
mapflag -x M2_F={M2_F?} -x
|
|
|
|
mapflag -Xs M2_F={M2_F?} -s
|
|
|
|
mapflag -V* M2_F={M2_F?} -V*
|
|
|
|
mapflag --* M2_F={M2_F?} -*
|
|
|
|
args \
|
2007-02-20 00:46:10 +00:00
|
|
|
{M2_INCL?} {MODULA2_INCLUDES} {M2SYSLIB?} \
|
1991-08-21 11:38:52 +00:00
|
|
|
-Vw{w}.{w}i{w}.{w}p{p}.{w}l{l}.{w}f{f}.{w}d{d}.{w} \
|
|
|
|
{M2_ALIGN?} {M2_F?} < >
|
|
|
|
prep cond
|
|
|
|
rts .mod
|
|
|
|
need .mod
|
|
|
|
callname m2
|
|
|
|
end
|
|
|
|
name ocm
|
|
|
|
from .ocm
|
|
|
|
to .k
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_occam
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -L OCM_F={OCM_F?} -L
|
|
|
|
mapflag -V* OCM_F={OCM_F?} -V*
|
|
|
|
args -Vw{w}p{p}l{l} {OCM_F?}
|
|
|
|
stdin
|
|
|
|
stdout
|
|
|
|
rts .ocm
|
|
|
|
need .ocm
|
|
|
|
prep cond
|
|
|
|
callname ocm
|
|
|
|
end
|
|
|
|
name abc
|
|
|
|
from .b
|
|
|
|
to .k
|
2013-05-14 17:01:38 +00:00
|
|
|
program {EM}/lib/ack/em_bem
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -h ABC_F={ABC_F?} -h
|
|
|
|
mapflag -w ABC_F={ABC_F?} -w
|
|
|
|
mapflag -L ABC_F={ABC_F?} -L
|
|
|
|
mapflag -E ABC_F={ABC_F?} -E
|
|
|
|
# mapflag -d ABC_F={ABC_F?} -d
|
|
|
|
args -Vw{w}p{p}f{d} {ABC_F?} < > {SOURCE}
|
|
|
|
prep cond
|
|
|
|
rts .b
|
|
|
|
need .b
|
|
|
|
callname abc
|
|
|
|
end
|
2013-05-12 19:45:55 +00:00
|
|
|
var A68INIT={EM}/lib/ack/em_a68s_init
|
1991-08-21 11:38:52 +00:00
|
|
|
name a68s
|
|
|
|
from .8.a68
|
|
|
|
to .k
|
2013-05-15 20:14:06 +00:00
|
|
|
program {EM}/lib/ack/em_a68s{w}{p}
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -PA* A68INIT=*
|
|
|
|
args < > {SOURCE}.lst {A68INIT}{w}{p} /dev/null
|
|
|
|
prep cond
|
|
|
|
rts .8
|
|
|
|
need .8
|
|
|
|
callname a68s
|
|
|
|
end
|
|
|
|
name encode
|
|
|
|
from .e
|
|
|
|
to .k
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_encode
|
1991-08-21 11:38:52 +00:00
|
|
|
args <
|
|
|
|
prep cond
|
|
|
|
stdout
|
|
|
|
end
|
|
|
|
name opt
|
|
|
|
from .k
|
|
|
|
to .m
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_opt
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -LIB OPT_F={OPT_F?} -L
|
1992-08-31 16:47:40 +00:00
|
|
|
# when running the global optimizer, no multiplication optimization here.
|
|
|
|
mapflag -O2 OPT2_F=-m0
|
|
|
|
mapflag -O3 OPT2_F=-m0
|
|
|
|
mapflag -O4 OPT2_F=-m0
|
|
|
|
args {OPT_F?} {MACHOPT_F?} {OPT2_F?} <
|
1991-08-21 11:38:52 +00:00
|
|
|
stdout
|
|
|
|
optimizer
|
|
|
|
end
|
|
|
|
name ego
|
|
|
|
from .m.ma
|
|
|
|
to .gk
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_ego
|
1991-08-21 11:38:52 +00:00
|
|
|
mapflag -EGO-* EGO_F={EGO_F?} -*
|
|
|
|
mapflag -Q* EGO_F={EGO_F?} -Q*
|
|
|
|
mapflag -T* EGO_F={EGO_F?} -T*
|
|
|
|
mapflag -S* EGO_F={EGO_F?} -S*
|
|
|
|
mapflag -s* EGO_F={EGO_F?} -s*
|
|
|
|
mapflag -a EGO_F={EGO_F?} -a
|
|
|
|
mapflag -O* EGO_F={EGO_F?} -O*
|
|
|
|
args \
|
2013-05-15 20:14:06 +00:00
|
|
|
{EGO_F?} -P {EM}/lib/ack/ego \
|
2016-08-21 20:01:19 +00:00
|
|
|
{EGO_PLAT_FLAGS?} <
|
1991-08-21 11:38:52 +00:00
|
|
|
optimizer 2
|
|
|
|
stdout
|
|
|
|
combiner
|
|
|
|
end
|
|
|
|
name opt2
|
|
|
|
# output of the global optimizer is processed by a stripped version
|
|
|
|
# of the em peephole optimizer
|
|
|
|
from .gk
|
|
|
|
to .g
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_opt2
|
1991-08-21 11:38:52 +00:00
|
|
|
# mapflag -LIB OPT_F={OPT_F?} -L
|
1991-11-20 15:52:27 +00:00
|
|
|
args {OPT_F?} {MACHOPT_F?} <
|
1991-08-21 11:38:52 +00:00
|
|
|
optimizer
|
|
|
|
stdout
|
|
|
|
end
|
|
|
|
name decode
|
|
|
|
from .k.m.g.gk
|
|
|
|
to .e
|
2013-05-12 19:45:55 +00:00
|
|
|
program {EM}/lib/ack/em_decode
|
1991-08-21 11:38:52 +00:00
|
|
|
args <
|
|
|
|
stdout
|
|
|
|
end
|