Data Organization and Addressing Capabilities
2-40 MC68030 USER’S MANUAL MOTOROLA
To implement growth of the queue from high to low memory, use:
–(An) to put data into the queue,
–(Am) to get data from the queue.
After a "put'' operation, the "put'' address register points to the last item place din the queue,
and the unchanged "get'' address register points to the last item removed from the queue.
After a "get'' operation, the "get'' address register points to the last item removed from the
queue, and the unchanged "put'' address register points to the last item placed in the queue.
This is illustrated as:
To implement the queue as a circular buffer, the "get'' or "put'' operation should be
performed first, and then the relevant address register should be checkout and adjusted, if
necessary. The address register is adjusted by adding the buffer length (in bytes) to the
register contents.
LOW MEMORY
(FREE)
HIGH MEMORY
LAST GET (FREE)
LAST PUT
NEXT GET
PUT - (An)
GET - (Am)