Multiple OR Plane Formats

At times it may be convienient to be able to specify more than one OR-plane format. The most obvious use of multiple formats would be when the OR plane actually has more than one physical format. In this case one OR plane field is being used as a format indicator for the remainder of the OR plane portion of the wordline. Another less obvious use of multiple formats is when you wish to give the illusion of multiple command formats, even though there is only one physical format. To illustrate, consider the case of providing a set of one-operand commands, a set of two-operand commands and a set of three-operand commands in the same PLA description. Let us assume that there are three OR plane fields and two AND plane fields. The three-operand commands will supply values for all three fields, while the one- and two-operand fields will cause default values to be assigned to the unspecified fields.

The PLA preprocessor allows multiple formats to be declared, and allows each opcode to be associated with a particular format. The first step is to define the opcodes, as follows.

oneop: equ 1
twoop: equ 2
threeop: equ 3

In this example, we will not use an opcode field, so the three symbols could just as easilly be given the same value. We give them different values just in case we change our mind about having an opcode field. The next step is to assign each opcode to a format. The "format" statement is used for this purpose. The following illustrates.

f1: format oneop
f2: format twoop
f3: format threeop

The operand field of the "format" statement is a list of one or more opcodes. The label of the statement is the name of the format. All of the opcodes in the operand field will be associated with the format named in the label.

As fields are defined, they also must be assigned to a format. The following is the definition of the field that is used only by the three operand format.

fld3a: field position=0,width=3,cmdpos=2,format=f3
fld3b: field position=0,width=3,default=1,format=f2,type=constant
fld3c: field position=0,width=3,default=0,format=f1,type=constant

Note that these three fields all occupy the same place in the OR plane. When multiple formats are used, the rules for overlapping fields are modified somewhat. There may not be any overlapping fields in a single format. Furthermore, there must be a definition for each field in each format. The "type=constant" parameter may be used to prevent the user from assigning a value to a field in a particular format. The PLA preprocessor will issue an error message if a value is assigned to a constant field.

The next step in this example is to define the field that will be shared by two operand and three operand commands. This field will be constant zero for one-operand opcodes. It must be specified in command position zero for two-operand opcodes and command position one for three-operand opcodes. The following is the definition of these fields.

fld2a: field position=3,width=8,default=0,format=f1,type=constant
fld2b: field position=3,width=8,cmdpos=(0,1),format=(f2,f3)

Note that only two field descriptions are required. The format parameter can be used to assign a field to more than one format, as illustrated above. When the "cmdpos" parameter is used with a field assigned to more than one format, a single number can be used to specify that the field appears in the same command position in each format, or a list of numbers can be used (one per format) to specify that the field appears at different command positions in each format. Now let us define the field that is shared between all three formats.

fld3: field position=11,width=1,cmdpos=(0,1,0),format=(f1,f2,f3)

The following is the definition of the two AND plane fields. Note that AND plane fields have a single format.

ca: field position=0,width=3,type=input
cb: field position=3,width=4,type=input

To complete the example, here are some statements that define wordlines.

ca=1: oneop 1
ca=2: twoop 5,0
cb=3: threeop 0,8,3
ca=4&cb=2: threeop 1,9,2
cb=4: oneop 0
cb=7: twoop 6,1

The first format defined in the text is the default format. All fields without "format" parameters, are assigned to the default format. The default format is used for "word" opcodes and for opcodes that are not explicitly mentioned in a "format" statement.