PDP-10 / its

Incompatible Timesharing System
Other
834 stars 80 forks source link

MIDAS 73: = does not change symbol relocation #2272

Open aap opened 4 months ago

aap commented 4 months ago

This is needed for the macros used by old versions of LISP. Simple example:

BAR 1:

RELOCATABLE
BLOCK 123
END

FOO 1:

RELOCATABLE
XXX:
BLOCK 100
FOO:
ZZ=1234
        ZZ
ZZ=FOO
        ZZ
ZZ=XXX
END

Build like this:

:MIDAS;73
BAR REL_BAR 1
:MIDAS;73
FOO REL_FOO 1
:MUDSYS;STINK
MBAR REL$L$$
MFOO REL$L$$
MFOO BIN$Y$$

If you then load and examine FOO BIN you get:

FOO/      1234
FOO+1/    100

That is, ZZ is first made absolute (1234), then relocatable (FOO) but it actually stays absolute so the word in memory (100) is the value of FOO taken as absolute. If ZZ is expunged between assignments it behaves as expected.

I also tested MIDAS 458 at it's ok there, but clearly older versions of MIDAS also treated this correctly so it would be nice to find out what's happening.

larsbrinkhoff commented 4 months ago

ToTS 3100150 SYS;TS LMIDAS version 43:

FOO/   1234   
FOO+1/   FOO   =323