From: ceriel Date: Thu, 10 Mar 1988 16:00:58 +0000 (+0000) Subject: fixes from Nigel Hall X-Git-Tag: release-5-5~3576 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=9258a2a3e95beff525a7c485e04db1d89f88d114;p=ack.git fixes from Nigel Hall --- diff --git a/mach/ns/libem/gto.s b/mach/ns/libem/gto.s index dbd2d932c..b9d146907 100644 --- a/mach/ns/libem/gto.s +++ b/mach/ns/libem/gto.s @@ -9,14 +9,7 @@ !r0 contains descriptor addres .gto: - addr 0(sp), r7 !first put future localbase in sp - subd 8(r0), r7 - subd 4, r7 - adjspd r7 !done - movd -4(sp), r1 !save this memory location - enter[], 0 !adjust local base - movd r1, 0(sp) !restore saved memory location - addr 0(sp), r7 !adjust stackpointer now - subd 4(r0), r7 - adjspd r7 - jump r0 !adjust programcounter + lprd fp,8(r0) + lprd sp,4(r0) + movd 0(r0),tos + ret 0 diff --git a/mach/ns/libem/putchar.s b/mach/ns/libem/putchar.s index 6a4856b77..26fa7f337 100644 --- a/mach/ns/libem/putchar.s +++ b/mach/ns/libem/putchar.s @@ -7,12 +7,14 @@ .sect .text +! putchar, for a unix + .putchar: - save [r0, r1, r2, r3] - movqd 4, r0 - addr 20(sp), r1 - movqd 1, r2 - xord r3, r3 - svc - restore[r0,r1,r2,r3] - ret 1 + enter [],0 + movqd 1,tos + addr 8(fp),tos + movqd 1,tos + bsr _write + asjspb -12 + exit [] + ret 0 diff --git a/mach/ns/libem/trp.s b/mach/ns/libem/trp.s index 274938d60..7eebda5cf 100644 --- a/mach/ns/libem/trp.s +++ b/mach/ns/libem/trp.s @@ -10,12 +10,11 @@ .trp: save [r0, r1] movd 12(sp), r0 !error number + movd r0,tos cmpd r0, 16 bge 1f - sbitd r0, r1 - andw @.ignmask, r1 - beq 1f - br 3f !do not trap + tbitd r0, @.ignmask + bfs 3f !do not trap 1: !do trap movd @.trpreg, r1 cmpqd 0, r1 @@ -23,6 +22,7 @@ movqd 0, @.trpreg jsr r1 3: + adjspd $-4 restore [r0, r1] ret 4 2: