summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2020-07-11 20:27:26 -0700
committerOri Bernstein <ori@eigenstate.org>2020-07-11 20:38:06 -0700
commit156c048f0239b99b870cf1694c6886e39b85ae09 (patch)
tree5b706e7ee59736d421a0683a72bc71fa976cc4aa
parentd68cb921e334d6fd802d6ae93398d6324cb784ff (diff)
downloadmc-master.tar.gz
Fix tests on BSDs and 9front, improve names.HEADmasterabi
-rw-r--r--6/asm.h16
-rw-r--r--6/isel.c175
-rw-r--r--6/simp.c38
-rw-r--r--6/typeinfo.c12
-rwxr-xr-xconfigure7
-rw-r--r--rt/start-freebsd.s10
-rwxr-xr-xtest/runtest.rc13
-rwxr-xr-xtest/runtest.sh4
-rw-r--r--test/tests14
9 files changed, 143 insertions, 146 deletions
diff --git a/6/asm.h b/6/asm.h
index 1789f34..6011264 100644
--- a/6/asm.h
+++ b/6/asm.h
@@ -54,13 +54,15 @@ typedef enum {
typedef enum {
ArgVoid,
- ArgReg, /* Either int or flt, depending on Loc* type */
- ArgSmallAggr_Int,
- ArgSmallAggr_Flt,
- ArgSmallAggr_Int_Int,
- ArgSmallAggr_Flt_Int,
- ArgSmallAggr_Int_Flt,
- ArgSmallAggr_Flt_Flt,
+ /* Either int or flt, depending on Loc* type */
+ ArgReg,
+ /* Small aggregates packed into registers */
+ ArgAggrI,
+ ArgAggrF,
+ ArgAggrII,
+ ArgAggrFI,
+ ArgAggrIF,
+ ArgAggrFF,
ArgBig,
} ArgType;
diff --git a/6/isel.c b/6/isel.c
index 8f682a5..0000424 100644
--- a/6/isel.c
+++ b/6/isel.c
@@ -611,34 +611,18 @@ placearg(Isel *s, Node *argn, Loc *argloc, PassIn p, Loc *rsp, int vararg, size_
static int
sufficientregs(ArgType a, size_t nfloats, size_t nints)
{
- size_t needed_ints = 0;
- size_t needed_flts = 0;
-
- switch(a) {
- case ArgSmallAggr_Int:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Int_Flt:
- needed_ints = 1;
- break;
- case ArgSmallAggr_Int_Int:
- needed_ints = 2;
- break;
- default: break;
- }
-
- switch(a) {
- case ArgSmallAggr_Flt:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Int_Flt:
- needed_flts = 1;
- break;
- case ArgSmallAggr_Flt_Flt:
- needed_flts = 2;
- break;
- default: break;
- }
-
- return (needed_flts + nfloats <= Nfloatregargs) && (needed_ints + nints <= Nintregargs);
+ static const struct {
+ int ireg;
+ int freg;
+ } needed[] = {
+ [ArgAggrI] = {1, 0},
+ [ArgAggrFI] = {1, 1},
+ [ArgAggrIF] = {1, 1},
+ [ArgAggrII] = {2, 0},
+ [ArgAggrFF] = {0, 2},
+ };
+
+ return (needed[a].freg + nfloats <= Nfloatregargs) && (needed[a].ireg + nints <= Nintregargs);
}
static Loc *
@@ -661,7 +645,7 @@ gencall(Isel *s, Node *n)
size_t nfloats, nints;
Loc *retloc1, *retloc2, *rsp; /* hard-coded registers */
Loc *ret;
- size_t nextintretreg = 0, nextfltretreg = 0;
+ size_t ri, rf;
Loc *stkbump; /* calculated stack offset */
Type *t, *fn;
Node **args;
@@ -673,6 +657,8 @@ gencall(Isel *s, Node *n)
rsp = locphysreg(Rrsp);
t = exprtype(n);
+ ri = 0;
+ rf = 0;
retloc1 = NULL;
retloc2 = NULL;
rettype = classify(t);
@@ -682,33 +668,29 @@ gencall(Isel *s, Node *n)
case ArgBig:
break;
case ArgReg:
- if (istyfloat(t)) {
- retloc1 = coreg(Rxmm0d, mode(n));
- } else {
- retloc1 = coreg(Rrax, mode(n));
- }
+ retloc1 = coreg((istyfloat(t)) ? Rxmm0d : Rrax, mode(n));
break;
- case ArgSmallAggr_Int:
- retloc1 = coreg(intretregs[nextintretreg++], tymodepart(t, 0, 0));
+ case ArgAggrI:
+ retloc1 = coreg(intretregs[ri++], tymodepart(t, 0, 0));
break;
- case ArgSmallAggr_Flt:
- retloc1 = coreg(fltretregs[nextfltretreg++], tymodepart(t, 1, 0));
+ case ArgAggrF:
+ retloc1 = coreg(fltretregs[rf++], tymodepart(t, 1, 0));
break;
- case ArgSmallAggr_Int_Int:
- retloc1 = coreg(intretregs[nextintretreg++], tymodepart(t, 0, 0));
- retloc2 = coreg(intretregs[nextintretreg++], tymodepart(t, 0, 8));
+ case ArgAggrII:
+ retloc1 = coreg(intretregs[ri++], tymodepart(t, 0, 0));
+ retloc2 = coreg(intretregs[ri++], tymodepart(t, 0, 8));
break;
- case ArgSmallAggr_Int_Flt:
- retloc1 = coreg(intretregs[nextintretreg++], tymodepart(t, 0, 0));
- retloc2 = coreg(fltretregs[nextfltretreg++], tymodepart(t, 1, 8));
+ case ArgAggrIF:
+ retloc1 = coreg(intretregs[ri++], tymodepart(t, 0, 0));
+ retloc2 = coreg(fltretregs[rf++], tymodepart(t, 1, 8));
break;
- case ArgSmallAggr_Flt_Int:
- retloc1 = coreg(fltretregs[nextfltretreg++], tymodepart(t, 1, 0));
- retloc2 = coreg(intretregs[nextintretreg++], tymodepart(t, 0, 8));
+ case ArgAggrFI:
+ retloc1 = coreg(fltretregs[rf++], tymodepart(t, 1, 0));
+ retloc2 = coreg(intretregs[ri++], tymodepart(t, 0, 8));
break;
- case ArgSmallAggr_Flt_Flt:
- retloc1 = coreg(fltretregs[nextfltretreg++], tymodepart(t, 1, 0));
- retloc2 = coreg(fltretregs[nextfltretreg++], tymodepart(t, 1, 8));
+ case ArgAggrFF:
+ retloc1 = coreg(fltretregs[rf++], tymodepart(t, 1, 0));
+ retloc2 = coreg(fltretregs[rf++], tymodepart(t, 1, 8));
break;
}
@@ -785,25 +767,25 @@ gencall(Isel *s, Node *n)
/* placearg can figure this out */
placearg(s, args[i], arg, PassInNoPref, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int:
+ case ArgAggrI:
placearg(s, args[i], arg, PassInInt, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt:
+ case ArgAggrF:
placearg(s, args[i], arg, PassInSSE, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int_Int:
+ case ArgAggrII:
placearg(s, args[i], arg , PassInInt, rsp, vararg, &nfloats, &nints, &argoff);
placearg(s, args[i], plus8(s, arg), PassInInt, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int_Flt:
+ case ArgAggrIF:
placearg(s, args[i], arg , PassInInt, rsp, vararg, &nfloats, &nints, &argoff);
placearg(s, args[i], plus8(s, arg), PassInSSE, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt_Int:
+ case ArgAggrFI:
placearg(s, args[i], arg , PassInSSE, rsp, vararg, &nfloats, &nints, &argoff);
placearg(s, args[i], plus8(s, arg), PassInInt, rsp, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrFF:
placearg(s, args[i], arg , PassInSSE, rsp, vararg, &nfloats, &nints, &argoff);
placearg(s, args[i], plus8(s, arg), PassInSSE, rsp, vararg, &nfloats, &nints, &argoff);
break;
@@ -830,25 +812,25 @@ gencall(Isel *s, Node *n)
else
g(s, Imov, retloc1, ret, NULL);
break;
- case ArgSmallAggr_Int:
+ case ArgAggrI:
g(s, Imov, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeQ), NULL);
break;
- case ArgSmallAggr_Flt:
+ case ArgAggrF:
g(s, Imovs, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeD), NULL);
break;
- case ArgSmallAggr_Int_Int:
+ case ArgAggrII:
g(s, Imov, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeQ), NULL);
g(s, Imov, retloc2, locmem(8, inri(s, selexpr(s, retnode)), NULL, ModeQ), NULL);
break;
- case ArgSmallAggr_Int_Flt:
+ case ArgAggrIF:
g(s, Imov, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeQ), NULL);
g(s, Imovs, retloc2, locmem(8, inri(s, selexpr(s, retnode)), NULL, ModeD), NULL);
break;
- case ArgSmallAggr_Flt_Int:
+ case ArgAggrFI:
g(s, Imovs, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeD), NULL);
g(s, Imov, retloc2, locmem(8, inri(s, selexpr(s, retnode)), NULL, ModeQ), NULL);
break;
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrFF:
g(s, Imovs, retloc1, locmem(0, inri(s, selexpr(s, retnode)), NULL, ModeD), NULL);
g(s, Imovs, retloc2, locmem(8, inri(s, selexpr(s, retnode)), NULL, ModeD), NULL);
break;
@@ -1307,30 +1289,30 @@ addarglocs(Isel *s, Func *fn)
/* retrievearg can figure this out */
retrievearg(s, arg, vararg, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int:
+ case ArgAggrI:
l = loc(s, arg);
movearg(s, l, PassInInt, ModeQ, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt:
+ case ArgAggrF:
l = loc(s, arg);
movearg(s, l, PassInSSE, ModeD, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int_Int:
+ case ArgAggrII:
l = loc(s, arg);
movearg(s, l , PassInInt, ModeQ, &nfloats, &nints, &argoff);
movearg(s, plus8(s, l), PassInInt, ModeQ, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Int_Flt:
+ case ArgAggrIF:
l = loc(s, arg);
movearg(s, l , PassInInt, ModeQ, &nfloats, &nints, &argoff);
movearg(s, plus8(s, l), PassInSSE, ModeD, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt_Int:
+ case ArgAggrFI:
l = loc(s, arg);
movearg(s, l , PassInSSE, ModeD, &nfloats, &nints, &argoff);
movearg(s, plus8(s, l), PassInInt, ModeQ, &nfloats, &nints, &argoff);
break;
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrFF:
l = loc(s, arg);
movearg(s, l , PassInSSE, ModeD, &nfloats, &nints, &argoff);
movearg(s, plus8(s, l), PassInSSE, ModeD, &nfloats, &nints, &argoff);
@@ -1378,12 +1360,13 @@ epilogue(Isel *s)
Loc *rsp, *rbp;
Loc *ret;
size_t i;
- size_t nextintretreg = 0, nextfltretreg = 0;
+ size_t ri = 0, rf = 0;
rsp = locphysreg(Rrsp);
rbp = locphysreg(Rrbp);
switch (s->rettype) {
- case ArgVoid: break;
+ case ArgVoid:
+ break;
case ArgReg:
/* s->ret is a value, and will be returned that way */
ret = loc(s, s->ret);
@@ -1397,45 +1380,43 @@ epilogue(Isel *s)
ret = loc(s, s->ret);
g(s, Imov, ret, coreg(Rax, ret->mode), NULL);
break;
- case ArgSmallAggr_Int:
+ case ArgAggrI:
/* s->ret is an address, and will be returned as values */
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[nextintretreg++], ModeQ));
+ load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[ri++], ModeQ));
break;
- case ArgSmallAggr_Flt:
+ case ArgAggrF:
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[nextfltretreg++], ModeD));
+ load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[rf++], ModeD));
break;
- case ArgSmallAggr_Int_Int:
+ case ArgAggrII:
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[nextintretreg++], ModeQ));
- load(s, locmem(8, ret, NULL, ModeQ), coreg(intretregs[nextintretreg++], ModeQ));
+ load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[ri++], ModeQ));
+ load(s, locmem(8, ret, NULL, ModeQ), coreg(intretregs[ri++], ModeQ));
break;
- case ArgSmallAggr_Int_Flt:
+ case ArgAggrIF:
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[nextintretreg++], ModeQ));
- load(s, locmem(8, ret, NULL, ModeD), coreg(fltretregs[nextfltretreg++], ModeD));
+ load(s, locmem(0, ret, NULL, ModeQ), coreg(intretregs[ri++], ModeQ));
+ load(s, locmem(8, ret, NULL, ModeD), coreg(fltretregs[rf++], ModeD));
break;
- case ArgSmallAggr_Flt_Int:
+ case ArgAggrFI:
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[nextfltretreg++], ModeD));
- load(s, locmem(8, ret, NULL, ModeQ), coreg(intretregs[nextintretreg++], ModeQ));
+ load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[rf++], ModeD));
+ load(s, locmem(8, ret, NULL, ModeQ), coreg(intretregs[ri++], ModeQ));
break;
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrFF:
ret = loc(s, s->ret);
- load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[nextfltretreg++], ModeD));
- load(s, locmem(8, ret, NULL, ModeD), coreg(fltretregs[nextfltretreg++], ModeD));
+ load(s, locmem(0, ret, NULL, ModeD), coreg(fltretregs[rf++], ModeD));
+ load(s, locmem(8, ret, NULL, ModeD), coreg(fltretregs[rf++], ModeD));
break;
}
/* restore registers */
- for (i = 0; savedregs[i] != Rnone; i++) {
- if (isfloatmode(s->calleesave[i]->mode)) {
+ for (i = 0; savedregs[i] != Rnone; i++)
+ if (isfloatmode(s->calleesave[i]->mode))
g(s, Imovs, s->calleesave[i], locphysreg(savedregs[i]), NULL);
- } else {
+ else
g(s, Imov, s->calleesave[i], locphysreg(savedregs[i]), NULL);
- }
- }
/* leave function */
g(s, Imov, rbp, rsp, NULL);
g(s, Ipop, rbp, NULL);
@@ -1490,16 +1471,16 @@ handlesmallstructargs(Isel *is, Func *fn)
case ArgBig:
/* No need for any extra space for this arg */
break;
- case ArgSmallAggr_Int:
- case ArgSmallAggr_Flt:
+ case ArgAggrI:
+ case ArgAggrF:
fn->stksz += 8;
fn->stksz = align(fn->stksz, min(8, Ptrsz));
htput(fn->stkoff, fn->args[i], itop(fn->stksz));
break;
- case ArgSmallAggr_Int_Int:
- case ArgSmallAggr_Int_Flt:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrII:
+ case ArgAggrIF:
+ case ArgAggrFI:
+ case ArgAggrFF:
fn->stksz += 16;
fn->stksz = align(fn->stksz, min(16, Ptrsz));
htput(fn->stkoff, fn->args[i], itop(fn->stksz));
diff --git a/6/simp.c b/6/simp.c
index 74b9c48..6b2a9d6 100644
--- a/6/simp.c
+++ b/6/simp.c
@@ -1095,12 +1095,12 @@ simpcall(Simp *s, Node *n, Node *dst)
case ArgVoid:
break;
case ArgBig:
- case ArgSmallAggr_Int:
- case ArgSmallAggr_Flt:
- case ArgSmallAggr_Int_Int:
- case ArgSmallAggr_Int_Flt:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrI:
+ case ArgAggrF:
+ case ArgAggrII:
+ case ArgAggrIF:
+ case ArgAggrFI:
+ case ArgAggrFF:
lappend(&args, &nargs, addr(s, r, exprtype(n)));
break;
case ArgReg:
@@ -1252,16 +1252,16 @@ rval(Simp *s, Node *n, Node *dst)
/*
* Compute and put the correct value into s->ret. In the case of ArgBig
* and ArgReg, exfiltrate the value from the function. In the case of
- * ArgSmallAggr_XYZ, put a pointer to the value where the function
+ * ArgAggr_XYZ, put a pointer to the value where the function
* epilogue can access it.
*/
switch (s->rettype) {
- case ArgSmallAggr_Int:
- case ArgSmallAggr_Flt:
- case ArgSmallAggr_Int_Int:
- case ArgSmallAggr_Int_Flt:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrI:
+ case ArgAggrF:
+ case ArgAggrII:
+ case ArgAggrIF:
+ case ArgAggrFI:
+ case ArgAggrFF:
t = s->ret;
u = rval(s, args[0], NULL);
u = addr(s, u, exprtype(args[0]));
@@ -1412,12 +1412,12 @@ simpinit(Simp *s, Node *f)
switch(s->rettype) {
case ArgVoid:
break;
- case ArgSmallAggr_Int:
- case ArgSmallAggr_Flt:
- case ArgSmallAggr_Int_Int:
- case ArgSmallAggr_Int_Flt:
- case ArgSmallAggr_Flt_Int:
- case ArgSmallAggr_Flt_Flt:
+ case ArgAggrI:
+ case ArgAggrF:
+ case ArgAggrII:
+ case ArgAggrIF:
+ case ArgAggrFI:
+ case ArgAggrFF:
s->ret = gentemp(f->loc, mktyptr(f->loc, ty), &dcl);
break;
case ArgBig:
diff --git a/6/typeinfo.c b/6/typeinfo.c
index b381016..b570e00 100644
--- a/6/typeinfo.c
+++ b/6/typeinfo.c
@@ -560,11 +560,11 @@ classify(Type *t)
switch(pi[0]) {
case PassInInt:
if (sz <= 8) {
- return ArgSmallAggr_Int;
+ return ArgAggrI;
}
switch(pi[1]) {
- case PassInInt: return ArgSmallAggr_Int_Int;
- case PassInSSE: return ArgSmallAggr_Int_Flt;
+ case PassInInt: return ArgAggrII;
+ case PassInSSE: return ArgAggrIF;
default:
die("Impossible return from classify_recursive");
break;
@@ -572,11 +572,11 @@ classify(Type *t)
break;
case PassInSSE:
if (sz <= 8) {
- return ArgSmallAggr_Flt;
+ return ArgAggrF;
}
switch(pi[1]) {
- case PassInInt: return ArgSmallAggr_Flt_Int;
- case PassInSSE: return ArgSmallAggr_Flt_Flt;
+ case PassInInt: return ArgAggrFI;
+ case PassInSSE: return ArgAggrFF;
default:
die("Impossible return from classify_recursive");
break;
diff --git a/configure b/configure
index 36672d3..b895748 100755
--- a/configure
+++ b/configure
@@ -71,7 +71,8 @@ case $OS in
echo export INST_MAN=$prefix/man/man >> config.mk
echo 'const Sys = "FreeBSD"' >> mbld/config.myr
echo 'const Linkcmd = ["ld", "--gc-sections"]' >> mbld/config.myr
- echo 'const Dlflags : byte[:][:] = [][:]' >> mbld/config.myr
+ echo 'const Dlflags : byte[:][:] = ["-L/usr/lib", '\
+ '"-dynamic-linker", "/libexec/ld-elf.so.1"][:]' >> mbld/config.myr
echo "const Manpath = \"man/man\"" >> mbld/config.myr
;;
*NetBSD*)
@@ -87,8 +88,8 @@ case $OS in
echo export INST_MAN=$prefix/man/man >> config.mk
echo 'const Sys = "OpenBSD"' >> mbld/config.myr
echo 'const Linkcmd = ["ld", "-nopie", "--gc-sections"]' >> mbld/config.myr
- echo 'const Dlflags = ["-dynamic-linker",' \
- '"/usr/libexec/ld.so"]' >> mbld/config.myr
+ echo 'const Dlflags = ["-L/usr/lib",'\
+ '"-dynamic-linker", "/usr/libexec/ld.so"]' >> mbld/config.myr
echo "const Manpath = \"man/man\"" >> mbld/config.myr
;;
*)
diff --git a/rt/start-freebsd.s b/rt/start-freebsd.s
index b995559..edb7a9b 100644
--- a/rt/start-freebsd.s
+++ b/rt/start-freebsd.s
@@ -1,8 +1,14 @@
.data
/* sys.__cenvp : byte## */
+.globl environ
.globl sys$__cenvp
+environ:
sys$__cenvp:
- .quad 0
+ .quad 0
+
+.globl __progname
+__progname:
+ .quad 0
.globl thread$__tls
thread$__tls:
@@ -25,6 +31,8 @@ _start:
/* load argc, argv, envp from stack */
movq (%rdi),%rax /* argc */
leaq 8(%rdi),%rbx /* argv */
+ movq (%rbx),%rcx /* save progname */
+ movq %rcx,__progname
leaq 16(%rdi,%rax,8),%rcx /* envp = argv + 8*argc + 8 */
/* store envp for some syscalls to use without converting */
diff --git a/test/runtest.rc b/test/runtest.rc
index e6aaf5a..6e53fe4 100755
--- a/test/runtest.rc
+++ b/test/runtest.rc
@@ -4,13 +4,13 @@ rfork e
MYR_MC=`{cd .. ; pwd}^/6/6.out
MYR_MUSE=`{cd .. ; pwd}^/muse/6.out
fn build {
- dir=`{echo $1 | grep '.*/'}
- if(~ $dir '') {
+ dir=`{basename -d $1}
+ if(~ $dir '.') {
rm -f $1 $1^.6 $1^.use
../obj/mbld/mbld -Bnone -o 'out' -b $1 -I../obj/lib/std -I../obj/lib/sys -I../obj/lib/regex -r../rt/_myrrt.6 $1^.myr
}
if not {
- target=`{echo $1 | grep -o '[^/]*$'}
+ target=`{basename $1}
top=`{pwd}
mkdir -p out/$dir
cd $dir
@@ -99,9 +99,10 @@ fn F {
cd $here
}
+fn posixonly {
+ status=''
+}
+
echo 'MTEST ' `{grep '^[BF]' tests | wc -l}
. tests
-
-
-
diff --git a/test/runtest.sh b/test/runtest.sh
index f7dc520..052c49b 100755
--- a/test/runtest.sh
+++ b/test/runtest.sh
@@ -133,6 +133,10 @@ F() {
cd $here
}
+posixonly() {
+ $*
+}
+
echo "MTEST $(egrep '^[BF]' tests | wc -l)"
. tests
diff --git a/test/tests b/test/tests
index 32fedef..d4b5fc1 100644
--- a/test/tests
+++ b/test/tests
@@ -181,10 +181,10 @@ B initializer E 0
B fmtalign E 0
B fmtnest P _.f2_2,_.f3__3,_4.4__
B implexpr P 12,z,hello
-B implexpr-concrete P zigzag
-B abi/001-return-tuple E 0
-B abi/002-arg-alignment E 0
-B abi/003-ret-alignment E 0
-B abi/004-torture-1 E 0
-B abi/005-torture-2 E 0
-B abi/006-torture-3 E 0
+implexpr-concrete P zigzag
+posixonly B abi/001-return-tuple E 0
+posixonly B abi/002-arg-alignment E 0
+posixonly B abi/003-ret-alignment E 0
+posixonly B abi/004-torture-1 E 0
+posixonly B abi/005-torture-2 E 0
+posixonly B abi/006-torture-3 E 0