[TUHS] PDP-11/70 SPL

Milo Velimirović milov at cs.uwlax.edu
Tue Mar 29 02:52:06 AEST 2016


> On Mar 28, 2016, at 11:37 AM, Johnny Billquist <bqt at update.uu.se> wrote:
> 
> Thanks for some additional information.
> 
> On 2016-03-28 18:16, Milo Velimirović wrote:
>> 
>>> On Mar 28, 2016, at 9:44 AM, Johnny Billquist <bqt at update.uu.se> wrote:
>>> 
>>> On 2016-03-28 16:18, Noel Chiappa wrote:
>>>>     > From: Dave Horsfall <dave at horsfall.org>
>>>> 
>> 
>> [ Wait & RK discussion snipped.]
>> 
>>> 
>>> 
>>>>     > I know that Kevin Dawson (I think) tried it on my /40 as well
>>>> 
>>>> The 11/40 does not have the SPL instruction; see the '75-'76 PDP-11 Processor
>>>> Handbook, pg. 4-5. (Again, sorry, just want to be accurate.)
>>> 
>>> This is also a pretty important point. But one which also begs the question how the splxxx() functions in Unix worked back then. Or did Unix not use this pattern and these functions back when the 11/40 was relevant?
>> 
>> These functions existed in V6 and can be found in the file, m40.s, that was assembled with the rest of the kernel to generate a unix that would run on a /40 class machine.
> 
> Aha. Great. Thanks. Yes, BIS and BIC on the PSW obviously works, but this would definitely not block interrupts for the next instruction. So at least in that case, a WAIT could result in the kernel sitting around waiting for the next interrupt. I don't really think DEC intend WAIT to be used in the way Unix uses it, and it don't really have the properties that would be ideas for Unix. Also somewhat indicated by the fact that DEC did not use WAIT this way themselves.

I don’t have access to the RT11 or RSX source to see how DEC used the WAIT instruction, but here’s how UNIX did it on the 11/40. It’s ridiculously simple as there’s no display register to manage.

_idle:
	mov	PS,-(sp)
	bic	$340,PS
	wait
	mov	(sp)+,PS
	rts	pc


 - Milo




More information about the TUHS mailing list