Alarm Siren wrote:
I have carefully designed each to fit within the constraints of the ATF1504 architecture, and yet, when I came to implement the MMU, the CUPL fitter seems to be using an extra eight latches beyond what I think it should be using, which causes the design to fail, and I cannot figure out why.
In your source code, you have:
Code:
/* Internal Nodes */
NODE [map0reg0..7]; /* Map Register 0 */
NODE [map1reg0..7]; /* Map Register 1 */
NODE [map2reg0..7]; /* Map Register 2 */
NODE [map3reg0..7]; /* Map Register 3 */
NODE [map4reg0..7]; /* Map Register 4 */
NODE [map5reg0..7]; /* Map Register 5 */
NODE [map6reg0..7]; /* Map Register 6 */
NODE [map7reg0..7]; /* Map Register 7 */
Try this:
Code:
/* Internal Nodes */
PINNODE [mapareg0..7]; /* Map Register 0 */
PINNODE [mapbreg0..7]; /* Map Register 1 */
PINNODE [mapcreg0..7]; /* Map Register 2 */
PINNODE [mapdreg0..7]; /* Map Register 3 */
PINNODE [mapereg0..7]; /* Map Register 4 */
PINNODE [mapfreg0..7]; /* Map Register 5 */
PINNODE [mapgreg0..7]; /* Map Register 6 */
PINNODE [maphreg0..7]; /* Map Register 7 */
...and see what happens. Be sure to make corresponding changes in other statements.
You cannot use a numeral in the register name and also specify an array for that same name, as you are doing. For example,
map0reg0..7 is confusing to the compiler, as you have double-indexed the name (0, followed by the 0..7 declaration). Read up on the CUPL programming manual for more detals.