4 ms·
If you, like myself, were wondering why the opcodes are written in octal, apparently modern hex notation was new at the time: PDP-11 was introduced in 1970, 0-F
by t-3 2y ago
If you, like myself, were wondering why the opcodes are written in octal, apparently modern hex notation was new at the time: PDP-11 was introduced in 1970, 0-F hex in 1966: https://en.wikipedia.org/wiki/Hexadecimal https://en.wikipedia.org/wiki/Hexadecimal
- ghayes 2y agoI sat confused how each 16-bit row was being shown as 8 hex digits (32-bits). Thanks for explaining it was in octal.
- msla 2y agoYep: The machine code is in octal (three bits per digit), the low-order bit is on the reader's left in this image, and the words run top to bottom. Pretty easy to read, once you get oriented.
- fweimer 2y agoThe 6-bit byte was still common at the time. Previous DEC machines had word sizes like 12 bits, 18 bits, or 36 bits. Apparently, the PDP-11 instruction encoding mostly had field widths that are multiples of three bits (although the opcode field mostly used 4 or 7 bits), and the usable address space for the machine was 15 bits when measured in words.
- zh3 2y agoOnce you know the pattern, it's super-easy to 'assemble' PDP-11 programs in your head. For example, for a double-operand instruction like 'MOV', the lower 12 bits are 4 groups of 3 bits specifying addressing modes and registers. Thus. MOV R2,R3 is 010203 (01=MOV, 0=direct source, 2=R2, 0=direct destination, 3=R3). More advanced example, this gets used to load data by utilising the PC (R7) which autoincrements each time, so a common MOV like MOV '#12345,@100' is 012737 12345 100 (MOV what the PC points too - #12345 - into the memory location the PC now points to @100 - noting the PC will be advanced 3 times in total so it ends up pointing to the next instruction). On PDP-11's with ODT (a minimal memory/register inspection/modification tool) this made it easy to enter short programs (like bootstraps) from memory - it was less a case of remembering the octal than it was remembering the code and doing mental translation to octal on the fly (systems without ODT, same process but you got to use the front panel rather than a terminal).
- fasa99 2y agoI didn't understand any of that. But what I got out of it was, this hardcore mf doesn't code in assembly, he codes in binary.