src/dps8/dps8_cpu.c
/*!
 cd@libertyhaven.com - sez ....
 If the instruction addresses a block of four words, the target of the
instruction is supposed to be an address that is aligned on a four-word
boundary (0 mod 4). If not, the processor will grab the four-word block
containing that address that begins on a four-word boundary, even if it has to
go back 1 to 3 words. Analogous explanation for 8, 16, and 32 cases.
 
 olin@olinsibert.com - sez ...
 It means that the appropriate low bits of the address are forced to zero. So
it's the previous words, not the succeeding words, that are used to satisfy the
request.
 
 -- Olin

 */
cd@libertyhaven.com - sez
If the instruction addresses a block of four words, the target of the
instruction is supposed to be an address that is aligned on a four-word
boundary (0 mod 4). If not, the processor will grab the four-word block
containing that address that begins on a four-word boundary, even if it has to
go back 1 to 3 words. Analogous explanation for 8, 16, and 32 cases.

olin@olinsibert.com - sez
It means that the appropriate low bits of the address are forced to zero. So
it's the previous words, not the succeeding words, that are used to satisfy the
request.

Olin
cd@libertyhaven . com - sez If the instruction addresses a block of four words the target of the instruction is supposed to be an address that is aligned on a four - word boundary ( 0 mod 4 ) . If not the processor will grab the four - word block containing that address that begins on a four - word boundary even if it has to go back 1 to 3 words . Analogous explanation for 8 16 and 32 cases . olin@olinsibert . com - sez It means that the appropriate low bits of the address are forced to zero . So it ' s the previous words not the succeeding words that are used to satisfy the request . Olin
int OPSIZE (void)
{
    DCDstruct * i = & cpu.currentInstruction;
    if (i->info->flags & (READ_OPERAND | STORE_OPERAND))
        return 1;
    else if (i->info->flags & (READ_YPAIR | STORE_YPAIR))
        return 2;
    else if (i->info->flags & (READ_YBLOCK8 | STORE_YBLOCK8))
        return 8;
    else if (i->info->flags & (READ_YBLOCK16 | STORE_YBLOCK16))
        return 16;
    else if (i->info->flags & (READ_YBLOCK32 | STORE_YBLOCK32))
        return 32;
    return 0;
}
int OPSIZE ( void ) { DCDstruct * i = & cpu . currentInstruction ; if ( i -> info -> flags & ( READ_OPERAND | STORE_OPERAND ) ) return 1 ; else if ( i -> info -> flags & ( READ_YPAIR | STORE_YPAIR ) ) return 2 ; else if ( i -> info -> flags & ( READ_YBLOCK8 | STORE_YBLOCK8 ) ) return 8 ; else if ( i -> info -> flags & ( READ_YBLOCK16 | STORE_YBLOCK16 ) ) return 16 ; else if ( i -> info -> flags & ( READ_YBLOCK32 | STORE_YBLOCK32 ) ) return 32 ; return 0 ; }
cd@libertyhaven.com - sez ....
cd@libertyhaven . com - sez ....