On compiling. (Was a way off topic subject)
paulkoning at comcast.net
Wed Jun 23 19:48:52 CDT 2021
Somewhat related to the point of compiling and executing mixed together is a very strange hack I saw in the Electrologica assembler for the X8 (the company issue one, not one of the various ones built at various labs for that machine). It is essentially a "load and go" assembler, so the code is dropped into memory as it is assembled, with a list of places to be fixed up rather than the more typical two pass approach. You can use a variation of the usual "start address" directive to tell the assembler to start executing at that address right now. In other words, you can assemble some code, execute it, then go back to assembling the rest of the source text. Cute. Suppose you want to do something too hard for macros; just assemble its input data, followed by some code to convert that into the form you want, then go back to assembling more code. And that can start by backing up the assembly output pointer ("dot") so the conversion code doesn't actually take up space in the finished program.
It sure makes cross-assemblers hard, because you have to include an EL-X8 simulator in the assembler... :-)
More information about the cctalk