Floating Point-How Important to Unix?

Johnny Billquist bqt at Update.UU.SE
Thu Apr 16 06:06:30 AEST 1998


On Fri, 10 Apr 1998, Ed G. wrote:

> I am not an expert on PDP-11 op codes, so you may well be right about 
> this.  
> 
> In response to your criticism, I looked up jmp and branch 
> instructions in the *Processor Handbook*.  Based only on my quick 
> skim of the handbook, I don't think negative relative addresses would 
> be a problem because: 
> 
> 1. branch instructions are followed by a signed byte offset (-128, 
> 127).  This would not be a problem for my routine which only looks at 
> the first four bits of every word and would ignore the offset in the 
> odd byte.

Correct.

> 2. jump instructions, which seem at first glance to be a problem 
> because they are followed by a 16 bit word, are not because they 
> always use absolute addressing, never relative and hence would never 
> be followed by a negative number.

2 wrong.

. Where did you get the idea that jump instructions have to be absolute?
. What about jumps to absolute addresses in the flt. op-code range?

I'm not sure about the 2BSD assembler, but the normal way of coding is to
have *all* addressing relative in the DEC assemblers. That means not just
jumps, but all instructions which takes arguments.
Almost all have word arguments, branch being one of the few exceptions.

	Johnny

Johnny Billquist                  || "I'm on a bus
                                  ||  on a psychedelic trip
email: bqt at update.uu.se           ||  Reading murder books
pdp is alive!                     ||  tryin' to stay hip" - B. Idol


Received: (from major at localhost)
	by minnie.cs.adfa.oz.au (8.8.5/8.8.5) id GAA05804
	for pups-liszt; Thu, 16 Apr 1998 06:33:36 +1000 (EST)
X-Authentication-Warning: minnie.cs.adfa.oz.au: major set sender to owner-pups at minnie.cs.adfa.oz.au using -f


More information about the TUHS mailing list