Comparing two System Areas...

Skip to first unread message

William Cattey

May 14, 2020, 10:20:29 PM5/14/20
For my automated build process, I want to compare the bootable device images to confirm there were no unexpected changes.

I've got a python script under development (that uses the same underlying library
for SIMH that my script runner uses). It can extract the files from an OS/8 device image into the POSIX directory structure for the system hosting SIMH, and then run POSIX utilities like diff on it.

The System Area is special. Very special.

Block 0 is the boot block.
Blocks 7 thru 67 (octal) are used, but some of them are transient:
Blocks 27-50 (octal) are system scratch blocks and are guaranteed to be non-deterministically different as soon as you boot that image.

PIP /Y will enable you to copy out "The System Area." I've read the code to figure out what it's doing, but there aren't enough comments, and the magic constants used willy-nilly have left me unenlightened. The file created by PIP is 50 (decimal) blocks in size.

Really, what I want to do is compare a subset of the system area:

Blocks 0, 7-12, 13-26, 51-64, 66-67.

What's a good block-wise dump/compare utility?

OCOMP is file based.
EPIC too.
FUTIL does dump but not compare.

Do I have to open code something in PAL8? Or drive FUTIL dump output into a file that gets compared?



Steve Tockey

May 17, 2020, 11:04:47 AM5/17/20
It should not be difficult to write a small program that simply copies the disk blocks you want to compare into a separate file and then run one of the file-based comparators on the two files you generated.

— steve

William Cattey

May 17, 2020, 11:50:19 PM5/17/20
Hi Steve,

Thanks for thinking about this and replying.

It turns out that writing such a program is a bit tricky. However, out of band, I've been in communication with someone who has written such a program. I've tweaked it, and plan to add it to the pidp8 build universe on as a tool.


K. Krause

May 18, 2020, 11:00:03 AM5/18/20

you can use FUTIL to dump single blocks in a textfile. Use formatting
Do this for the different devices, then run OCOMP on these textfiles.
One hint: the text dumps,that FUTIL produces, contain <NUL> characters
between every two characters, as it does'nt store three characters in
two words. It stores one character in one word.
To eliminate these <NUL> characters, make a copy with PIP. PIP
eliminates <NUL> characters in text files.


On 15.05.20 04:20, William Cattey wrote:
> For my automated build process, I want to compare the bootable device images to confirm there were no unexpected changes.

Steve Tockey

May 18, 2020, 5:39:40 PM5/18/20
There should really be nothing tricky at all about it. Knowing what blocks you want to read off of the system disk, followed by writing them sequentially out as binary data blocks in a new file. I was going to throw something together to do just that, it would easily take me less than half a day. It was, unfortunately, a lower priority than other work I have going on. But since it looks like you've already got the problem solved by other means I might do it some day just as an exercise of curiosity.
Reply all
Reply to author
0 new messages