fixed some minor problems with copying conformant arrays,

and a LB that pointed below SP in transfer
This commit is contained in:
ceriel 1987-11-03 15:04:21 +00:00
parent 9ae4e7924a
commit 2837aa68a7
2 changed files with 8 additions and 7 deletions

View file

@ -37,13 +37,13 @@ _copy_array(p, a)
char dummy; char dummy;
ppdescr--; ppdescr--;
sz = (((*ppdescr)->highminlow + 1) * (*ppdescr)->size + sz = ((*ppdescr)->highminlow + 1) * (*ppdescr)->size;
(EM_WSIZE -1)) & ~ (EM_WSIZE - 1);
if ((char *) &a - (char *) &dummy > 0) { if ((char *) &a - (char *) &dummy > 0) {
(*ppdescr)->addr = q = (char *) &a; (*ppdescr)->addr = q = (char *) &a;
} }
else (*ppdescr)->addr = q = (char *) &a - sz; else (*ppdescr)->addr = q = (char *) &a -
((sz + (EM_WSIZE - 1)) & ~ (EM_WSIZE - 1));
while (sz--) *q++ = *p++; while (sz--) *q++ = *p++;
} }

View file

@ -130,6 +130,11 @@ _target
adp -EM_PSIZE adp -EM_PSIZE
loi EM_PSIZE loi EM_PSIZE
str 1 ; temporary stackpointer str 1 ; temporary stackpointer
lae _MainLB
loi EM_PSIZE
str 0
lae _CurrentProcess lae _CurrentProcess
loi EM_PSIZE loi EM_PSIZE
lae _MainProcess lae _MainProcess
@ -137,10 +142,6 @@ _target
cmp cmp
zeq *2 zeq *2
lae _MainLB
loi EM_PSIZE
str 0
lae _StackBase lae _StackBase
loi EM_PSIZE loi EM_PSIZE
lae _CurrentProcess lae _CurrentProcess