MACRO-11 help

From: Pete Turnbull <pete_at_dunnington.u-net.com>
Date: Tue Sep 17 02:10:00 2002

On Sep 16, 22:15, Jerome H. Fine wrote:

> I understand your answer. Under normal situations (when MACRO-11
> source is translated and the actual code is placed into an OBJ file which
> is then LINKed), both ways are acceptable. BUT, Patrick was setting up
> the program via ODT (see line four). If Patrick did not realize what the
'
> character in the string 177566' meant, perhaps he just put 177566 instead
> so that the three word instruction became:
> 001000 Mov #110,XBUF 012767 000110 177566
> which, of course, is NOT what Patrick intended. However
> 001000 MovB #110,_at_#XBUF 112737 000110 177566
> is correct and does the job.
>
> So it is not that the first method is incorrect, but for some it might be
> confusing.

Hmm. I'd argue that it *is* incorrect, or at the very least, bad practice.
 Relative addresses are meant for situations where the target is a label,
indicating something which must move if the code does, like the target of a
JSR, or a block of data attached to the code; if you mean to indicate
something like a memory-mapped register, which has an absolute and
invariant address, you should use absolute addressing.

Given that Pat said he was going to enter the code using ODT, I imagine he
expected the MACRO output to be the correct numbers to enter. But he used
the wrong addressing mode to do that :-)

> My personal opinion is that the MACRO-11 program should make the
> situation plain, but unfortunately I suspect that MACRO-11 will never
> be modified by the present owners.

I suspect you're right :-) Besides, the output is meant for the linker,
not ODT, and I'm not sure how you could make it really plain that the
numerical value in the output is not what the linker will turn it into,
without a lot of (usually) unneccessary clutter.

-- 
Pete						Peter Turnbull
						Network Manager
						University of York
Received on Tue Sep 17 2002 - 02:10:00 BST

This archive was generated by hypermail 2.3.0 : Fri Oct 10 2014 - 23:35:39 BST