On 2018-08-04, at 09:21:14, Charles Mills wrote:
> 
> The HLASM team's dance card is already pretty full but you can certainly
> picture something like that in HLASM:
> 
> J *+3I
> 
> Meaning "here + 3 instructions." 'I' is perhaps not the best indicator
> because it is easily confused with a digit, although J *+n seldom ends in a
> legitimate 1.
> 
> Yes, the assembler would have to do look-ahead. Yes, HLASM would have to
> impose some limits and caveats.
> 
> I'm not crazy about it. It solves the "what if the instruction length
> changes, such as from A to AG?" problem, but not the "what if someone
> hastily and with inadequate thought inserts or deletes an instruction?"
> problem.
>  
Knuth's scheme wasn't relative bytes, nor instructions, nor even source
code lines.  It was an actual coded label with very local scope.  No
hazard from inserting instructions.


> -----Original Message-----
> From: Peter Relson
> Sent: Saturday, August 4, 2018 7:23 AM
> 
>> "This isn't a 'real' branch-that is, we aren't going very far..."
> 
> Donald Knuth's assembler, which we had available in college in the 70's, 
> had the concept of a "relative label".
> I can't remember if there was one name pattern for "forward" and one for 
> "backward" or whether you couldn't use it for "backward". It avoided  
>   
(IIRC, the former.)

> unnecessarily unreadable label names, and avoided the uniqueness problem. 
> And when used properly (i.e., well within a "screen" amout) it was 
> perfectly clear.
>  
And hardly needed cross-reference.

-- gil

Reply via email to