Pipelined data processor capable of decoding and executing plural instructions in parallel.
Abstract
A pipelined data processor comprises a circuit (3) for extracting two instructions into a pair of instruction registers (l, 2), a circuit (6) for detecting whether those instructions are a combination of an instruction requesting a use of an operation unit and an instruction requesting the use of other resource, and a circuit (4) to control the execution of the instruction when the decision of the detection circuit is affirmative such that those instructions are executed by the operation unit and the resource in a plurality of stages.

Term
Term ended
Projected expiry passed 24 March 2007, 19.5 years ago.
- Priority
- Filed
- Published
- Projected expiry
- Today
5 claims: 5 independent, 0 dependent
- 1A pipelined data processor for executing a plurality of instructions in parallel, comprising:a main storage (l3);operation means (l2) connected to said main storage for performing a plurality of operations requested by a plurality of instructions of a first kind to be executed by said data processor;at least one resource means for performing an operation other than said plurality of operations, requested by at least one instruction of a second kind;at least one pair of instruction registers (l, 2);set means (3) for setting into said pair of instruction registers the first instruction to be next executed and the second instruction to be executed next to the first instruction, stored in said main storage;detection means (6) for detecting whether one of the first and second instructions set in said pair of instruction registers is one of said instructions of the first kind and the other is said instruction of the second kind;and control means (4) responsive to an affirmative decision of said detection means for controlling the execution of said one instruction such that the operation requested by said one instruction is executed in a executed in a plurality of stages including a stage executed by said operation means, controlling the execution of said other instruction such that said other instruction is executed in a plurality of stages including a stage executed by said resource means, in parallel with the execution of said one instruction, and controlling said set means such that third and fourth instructions following to said first and second instructions are set into said pair of instruction registers in parallel with the execution of said first and second instructions, and responsive to a negative decision of said detection means for controlling the execution of said first instruction such that said first instruction is executed in a plurality of stages including a stage in which the operation requested by said first instruction is executed by said operation means or said resource means and controlling said set means such that said second instruction and said third instruction are held in said pair of instruction registers in parallel with the execution of said first instruction.
- 2A pipelined data processor according to Claim l wherein said detection means detects whether said second instruction does not use a result of execution of said first instruction in the execution of said second instruction, said one instruction is one of said instructions of the first kind, the said other instruction is said instruction of the second kind.
- 3A pipelined data processor according to Claim l wherein said instruction of the second kind is a branch instruction and said resource means fetches a branch-to instruction specified by the branch instruction, from said main storage.
- 4A pipelined data processor according to Claim l further comprising:a first buffer memory (l0) connected to said main storage for holding an operand;a second buffer (ll) memory connected to said main storage for holding an instruction;first and second address generation means (8, 9) connected to said first and second buffer memories, respectively, for generating addresses for accessing said main storage, and accessing said first and second buffer memories, respectively;and a plurality of registers (7) addressable by the instruction;wherein said one instruction requests an operation to an operand is said main storage, and said control means includes means responsive to an affirmative decision of said detection means for sending data in at least one register specified by said one instruction held in said pair of instruction register to said first address generation means and sending data in at least one register specified by said other instruction to said second address generation means.
- 5A pipelined data processor according to Claim l further comprising:a first buffer memory (l0) connected to said main storage and said operation unit for holding an operand;a second buffer memory (ll) connected to said main storage for holding an instruction;a plurality of registers (7) connected to said pair of instruction registers for fetching first data in at least one register specified by said first instruction and second data in at least one register specified by said second instruction;and first and second address generation means (8, 9) for receiving said first and second data, respectively, from said registers and generating addresses to access said main storage;wherein said one instruction requests an operation to an operand in said main storage, and said control means includes means depending on whether said first instruction is said one instruction and said second instruction is said other instruction for sending the output addresses of said first and second address generation means to said first and second buffer memories, respectively, or to said second and first buffer memories, respectively.
Independent claims5
68 paragraphs in 4 sections, as filed
BACKGROUND OF THE INVENTION
0001The present invention relates to a data processor for executing instruction in a pipelined and parallel fashion, and more particularly to a data processor which simultaneously decodes two instructions and executes them in a parallel and pipelined fashion.
0002In a prior art large scale general purpose computer, instructions are executed in a pipelined fashion to execute different instruction in an overlapped manner so that an execution speed of instruction sequence is effectively increased. In order to improve it, various techniques have been proposed. For example, in JP-A-60-l7538, in order to execute an instruction which requests operations for two memory operands, two address adders are provided so that addresses of the two memory operands are simultaneously calculated. In JP-A-58-l7675l, two pipelined instruction execution units simultaneously (or parallelly) decode two instructions in one instruction sequence to parallelly execute them. In JP-A-59-32045 (or corresponding U.S. Patent 4,626,989), in order to improve the above parallel decode technique, if the two instructions cannot be executed in parallel because a result of execution of a first instruction to be executed first is used by a second instruction to be executed later, the second instruction is executed following to the first instruction in the same pipelined instruction execution unit as that for the first instruction.
0003In the prior art parallel decode technique, each of the two pipelined instruction execution units needs an address generator, an operand read memory and an operation unit. When a data processor is constructed, the operation units and other units are provided in deplicate. Thus, investment of hardwares is large and a control configuration is complex. Since the operation unit comprises a plurality of units which perform various operations, a circuit scale thereof is large.
SUMMARY OF THE INVENTION
0004It is an object of the present invention to provide a data processor whose hardware scale is not large to compare with that of a pipelined instruction execution unit in a prior art data processor and which can decode a plurality of instructions in parallel.
0005The above object is achieved by means for extracting two instructions into a pair of instruction registers, means for checking whether those instructions are combination of an instruction which requires use of the operation unit and an instruction which requires use of other resource and means for controlling execution of those instructions so that when the above decision is affirmative, the instructions are executed by using the operation unit and the resource.
0006The instructions to be executed include an instruction which uses the operation unit as well as an instruction which used a resource other than the operation unit. When the detection means detects that those two instructions have been extracted into the pair of registers, those two instructions are executed in parallel by the instruction execution means. As a result, the two instructions which use the operation unit and other resource are executed in parallel. Thus, two instructions can be executed in parallel without providing two operation units.
BRIEF DESCRIPTION OF THE DRAWINGS
0007<ul id="ul0001" list-style="none"><li>Fig. l shows an overall configuration of a processor which embodies the present invention,</li><li>Figs. 2a and 2b show a detail of an instruction extraction circuit 3 of Fig. l,</li><li>Figs. 3a, 3b and 3c show various instruction formats,</li><li>Fig. 4 shows a detail of a selector 4 of Fig. l for selecting a register number used to generate an address,</li><li>Fig. 5 shows a circuit for generating a select signal and a memory read request, of a decode control circuit 6 of Fig. l,</li><li>Fig. 6 shows a detail of an instruction read adder, of the decode control circuit 6 of Fig. l,</li><li>Fig. 7 shows a detail of a conflict detection circuit 5 of Fig. l,</li><li>Figs. 8a, 8b, 8c and 8d show an instruction execution flow by the present invention,</li><li>Fig. 9 shows an overall configuration of another processor which embodies the present invention, and</li><li>Fig. l0 shows a detail of a selector 800 of Fig. 9.</li><li>Fig. ll shows a detail of a decode control circuit 803 of Fig. 9.</li></ul>
DESCRIPTION OF THE PREFERRED EMBODIMENTS
0008Embodiments of the present invention will be explained with reference to the drawings.
0009Fig. l shows an overall configuration of a pipelined data processor which utilizes the present invention. The data processor comprises two instruction registers l and 2, an instruction extract circuit 3 for simultaneously extracting two instructions in an instruction buffer 99 into those instruction registers l and 2, a selector 4 for selecting a general purpose register number in a group of instruction registers and supplying it to a group of general purpose registers 7, two address generation circuits 8 and 9 for generating memory data addresses based on data read from the group of general purpose registers, a main memory l3, an operand buffer memory l0 and instruction buffer memory ll accessed by addresses generated by the address generation circuits 8 and 9, an operation unit l2 for operating an operand read from the buffer memory l0 and storing a result into the buffer memory l0 or the general purpose register 7, a decode control circuit 6 for decoding instructions in the instruction registers l and 2 to control the execution thereof, and a conflict detection circuit 5, a selector 90 for selecting an instruction code and a register number of a register operand from instruction registers which hold instructions utilizing an operation unit l2, among the instructions extracted and set in the instruction registers l and 2, and registers 89 for holding the selected instruction code and the selected register number until the start of operation in timed relation to each pipelined stage. The operation unit l2 comprises a plurality of operation circuits for performing arithmetic or logical operations required by the instructions executed by the processor. The control of operation is performed by supplying via a line l8l to the operation unit l2 an instruction code held in the registers 89 in time relation to each pipelined stage.
0010The present processor sequentially executes the instructions in a pipelined fashion. The instruction buffer memory ll is provided separately from the operand buffer memory l0 so that when the memory l0 is used for the execution of an instruction, a subsequent instruction is fetched in parallel.
0011The length of instruction executable by the present processor is 2, 4 or 6 bytes.
0012Fig. 3a shows an instruction format of a four-byte load instruction. The load instruction reads an operand data in the memory and stores it into the general purpose register. In Fig. 3a, OP represents an operation code, Rl represents a general purpose register number in which data read from the memory is to be stored, X and B represent two general purpose register (index register and base register) numbers for calculating an operand address in the memory, and D represents a displacement. The operand address is calculated by summing a content of the index register (X), a content of the base register (B) and the displacement D.
0013Fig. 3b shows an instruction format of a four-byte branch instruction. The branch instruction compares a mask value (Ml) of the branch instruction and a condition code to determine whether to branch or not. A destination instruction address is determined by X, B and D of the instruction. The meanings of the bits of the instruction are identical to those of the load instruction, except for the mask value (Ml).
0014Fig. 3c shows a six-byte instruction. It holds two operands to be operated in the memory. To start the operation, an address of a first operand is calculated based on Bl and Dl, then an address of a second operand is calculated based on B2 and D2 in order to read the operands.
0015An example of a two-byte instruction is not shown for simplification purpose.
0016Specific specifications of detail of the instructions are described in HITAC manual "M Series Processor (M/EA mode)" (No. 8080-2-083 (l984) pp l2-l4, 94, l79 and l95-l98).
0017An outline of the operation of the present processor is now explained.
0018The instruction registers l and 2 have 6-byte and 4-byte lengths, respectively. Instructions (8 byte length) are sequentially fetched from the instruction buffer memory ll through a signal line l32 and stored into the instruction buffer 99. The instruction extract circuit 3 extracts instructions (8-byte length) including the instruction to be next executed, of the instructions stored in the instruction buffer 99. When the instruction to be next executed is of 2-byte or 4-byte length, two instructions are included in the extracted instructions, and the instruction extract circuit 3 sets the instruction to be next executed (first instruction) and the following instruction (second instruction) into the instruction registers l and 2, respectively. When the instruction to be next executed is of 6-byte length, only the first instruction is set into the instruction register l.
0019The operation when the first and second instructions are set into the first and second instruction registers is explained.
0020In the present invention, when there is no conflict of register between the first and second instructions or conflict between the resources (address generation circuits 8, 9 and buffer memories l0, ll), both instructions are simultaneously executed, and if there is any conflict, only the first instruction is preferentially executed. The necessary processing therefor is carried out by the conflict detection circuit 5 and an instruction combination recognition circuit 96. The former detects a conflict that a general purpose register in which a result of execution of the first instruction is to be written is designated by the second instruction as the index or base register. The latter detects a conflict that the first and second instructions use the same address generation circuit 8 or 9.
0021When the first instruction requires the fetching of the memory operand and the use of the operation unit and the second instruction reguires the fetching of the instruction and there is no register conflict between those instructions, those instructions can be executed in parallel in the present embodiment because the operand buffer l0 and the instruction buffer ll are separately provided. The selector 4 selects an index register number, a base register number and a displacement specified by the first instruction, and reads the contents of the general purpose registers 7 corresponding to those register numbers. The address generation circuit 8 (which is a three-input adder) adds the contents of the registers and the displacement to generate an address for memory accessing. The generated address is sent to the buffer memory l0 and used to fetch the operand specified by the first instruction.
0022The selector 4 selects an index register number, a base register number and a displacement specified by the second instruction, and reads the contents of the general purpose registers 7 corresponding to those register numbers. The address generation circuit 9 (which is also a three-input adder) adds the contents of the general purpose registers and the displacement to generate an address for memory accessing. The generated address is sent to a buffer memory ll and used to fetch the instruction specified by the second instruction.
0023When the first instruction requires the fetching of the instruction and the second instruction requires the fetching of the memory operand and the use of the operation unit, those instructions are executed in parallel. The address generation circuit 8 and the buffer memory l0 are used for the instruction 2, and the address generation circuit 9 and the buffer memory ll are used for the instruction l.
0024When both the first instruction and the second instruction require the fetching of the memory operands, the two instructions cannot be executed in parallel because there is only one operand buffer l0 and only one operation unit l2 in the present embodiment, and only the first instruction is executed. The address generation circuit 8 and the buffer memory l0 are used.
0025When both the first and second instructions require the fetching of the instructions, only the first instruction is executed. The address generation circuit 9 and the buffer memory ll are used for the instruction l.
0026When only the instruction l is executed, the instruction extract circuit 3 extracts a group of instructions (8-byte length) which include the instruction 2 as an instruction to be next executed, from the instruction buffer 99, and the instruction 2 is set into the instruction register l and the instruction to be next executed is set into the instruction register 2. Thus, the instruction 2 is executed one cycle behind the instruction l.
0027The instruction code and register number of an instruction allowed to execute are selected by the selector 90 and delivered to the registers 89. The registers 89 comprise a plurality of registers connected in series. The content of each register is successively delivered to the next register. An instruction is executed by a plurality of pipelined stages, with each stage corresponding to each of registers. The content of each register is used to control the corresponding stage. When an instruction allowed to execute utilizes data in the general purpose registers 7 as an operation operand, the register numbers Rl and R2 specified by the instruction are delivered via a line l80 to the general purpose registers 7. An operand is read out on a line l82 and delivered to the operation unit l2.
0028The decode control circuit 6 includes a selector control circuit 94 which controls the selector 4, a request generation circuit 94 which issues a fetch request to the buffer memory l0 or ll, and an end of decode detection circuit 99 which controls the entire circuit.
0029Detail of the processor of Fig. l is now explained. Detail of the instruction extract circuit 3 is shown in Figs. 2a and 2b, in which Fig. 2a shows a hardware configuration and Fig. 2b illustrates an operation thereof. A signal line l99 denotes 8-byte instructions fetched from the instruction buffer 99, and a signal line l50 denotes first two bits of the eight bytes. The instructions handled in the present processor have an instruction format of the HITAC-M Series computer, and the length of the instruction is specified by the first two bits of the instruction. When the first two bits of the instruction are "00", the instruction is of 2-byte length, when they are "ll", it is of 6-byte length, and when they are neither "00" nor "ll", it is of 4-byte length. (Detail of the M Series instruction specification is described in HITAC manual "M Series Processor (M/EA mode)" (No. 8080-2-083 (l984) pp 63-64).) The decoder l58 decodes the first two bits to control the selector l59, and produces first and second valid signals Vl and V2 indicating whether valid instructions have been sent to the first and second instruction registers l and 2. For example, when the first two bits of the instruction is "00", the instruction is of 2-byte length and the selector l59 extracts the first and second bytes of the eight bytes on the signal line l99 onto the signal line l0l and sends them to the first instruction register. On the other hand, in order to extract the instruction next to the instruction extracted onto the signal line l0l from the eight bytes on the signal line l99, the selector l59 extracts the third to sixth (four) bytes onto the signal line l02 and sends them to the second instruction register. When the first two bits of the instruction indicate the four-byte length of the instruction, the bytes l - 4 on the signal line l99 are extracted onto the first instruction register l, and the next instruction, that is, the bytes 5 - 8 are extracted from the signal line l99 into the second instruction register 2. When the first instruction is of 6-byte length, the bytes l - 6 on the signal line l99 are extracted and sent to the first instruction register l, and nothing is sent to the second instruction register 2. Namely, when the 6-byte length instruction is extracted into the first instruction register, the immediately following instruction is not executed in parallel.
0030The decoder generates "l" on Vl and V2 when the first two bits on the line l99 is "00", "0l" or "l0", and generates "0" on V2 when the first two bits are "ll" to indicate that a valid instruction has not been sent to the second instruction register 2. It should be noted that when the instruction set in the second instruction register 2 is of 6-byte length, all bytes are not aligned even if the signal V2 is set on the line l54.
0031The instructions fetched from the instruction buffer 99 are extracted by the instruction extract circuit 3 into the instruction registers l and 2 as the first and second instructions. Let us assume that a load instruction is extracted into the instruction register l and a branch instruction is extracted into the instruction register 2.
0032When the load instruction and the branch instruction are extracted into the instruction registers l and 2, respectively, the load instruction refers the operand buffer memory l0 to fetch the operand, and the branch instruction refers the instruction buffer memory ll to fetch a branch-to instruction. This operation is explained below.
0033When the instructions are extracted into the instruction registers l and 2, the operation codes of the first and second instructions are decoded by the decoder 98 in the decode control circuit 6, possibility of parallel execution of the two instructions is checked by the instruction combination recognition circuit 96, a request signal to the memory is generated by the request generation circuit 94, and a control signal to the selector 4 is generated by the selector control circuit 95. When the end of instruction decoding is detected by the end of decode detection circuit 97, the address in the instruction fetch address generation circuit 93 is incremented by the instruction length to fetch the next instruction.
0034Detail of the selector 4 is shown in Fig. 4. Numerals l90, l93 - l95 denote two-input, one-output selectors, and numerals l9l and l92 denote three-input, one-output selectors. The selectors l90 - l95 select the register numbers of the index register and the base register or the displacements and supply them to the general purpose register 7 and the address generation circuits 8 and 9. The select operation is controlled by the signal line ll7 as follows. For example, the index register numbers of the first instruction and the second instruction are supplied to the selector l90. When the control line 269 is not set, the index register number l06 of the first instruction is selected and supplied to the signal line ll9. The data read by using this register number is supplied to the address generation circuit 8 through the signal line l24. If the decode control circuit 6 determines that the address calculation of the second instruction be conducted by the address generation circuit 8, the signal line 269 is set, and the index register number ll2 of the second instruction is selected and supplied to the signal line ll9.
0035In the selector l9l, when the control signals 270 and 265 are not set, the base register number l07 of the first instruction is selected and supplied to the signal line l20, and if the decode control circuit 6 determines that the address calculation of the second instruction be conducted by the address generation circuit 8, the control line 270 is set and the base register number ll3 of the second instruction is selected. If the decode control circuit 6 determines that the address calculation of the 6-byte length (SS format) second instruction be conducted, the signal line l09 is selected. Since the 6-byte instruction has two memory operands, two times of memory reference are required in the present processor, and the signal line l09 if selected for the memory reference of the second operand. Other selectors control in a similar manner. The selector l92 selects the displacement ll4 if the signal line 27l is set, and selects the displacement ll0 if the signal line 265 is set. The selector l93 selects the index register number ll2 if the signal line 266 is set, the selector l94 selects the base register number ll3 if the signal line 267 is set, and the selector l95 selects the displacement ll4 if the signal line 268 is set.
0036The register numbers on the signal lines ll9 - l22 of the outputs of the selector 4 are supplied to the general purpose register 7 and used for fetching data. The content of the register specified by the signal line ll9 is read onto the signal line l24. Similarly, the contents of the registers specified by the signal lines l20, l2l and l22 are read onto the signal lines l25, l26 and l27, respectively. It is now assumed that the load instruction is set in the instruction register l and the branch instruction is set in the instruction register 2. Thus, the content of the index register specified by the load instruction is read onto the signal line l24, the content of the base register specified by the load instruction is read onto the signal line l25, the content of the index register specified by the branch instruction is read onto the signal line l26, and the content of the base register specified by the branch instruction is read onto the signal line l27, through the selector 4 and the general purpose register 7. None of signal lines ll7 is not set at this time. The address generation circuit 8 receives the data on the signal lines l24 and l25 and the displacement on the signal line ll8 and adds them, and transfers the resulting address to the operand buffer memory l0 through the signal line l28, transfers the operand data fetched therefrom to the signal line l29 and the operation unit l2 and to the general purpose register 7 through the signal line l30 without any operation in the operation unit l2 and stores it in the general purpose register specified by the first instruction. On the other hand, the address generation circuit 9 receives the data on the signal lines l26 and l27 and the displacement on the signal line l23 and adds them to calculate a branch-to address of the branch instruction. The sum is transferred to the instruction buffer memory ll through the signal line l3l to fetch the branch-to instruction. The branch-to instruction is required when the branch instruction successes the branch. In this case, the branch-to instruction fetched from the buffer memory ll is supplied to the instruction buffer 99 through the signal line l32 and extracted to the instruction registers l and 2.
0037The decode control circuit 6 comprises the instruction combination recognition circuit 96 which controls the selector 4 depending on the combination of the instructions extracted into the instruction registers l and 2, the selector control circuit 95, the request generation circuit 94 for issuing a memory reference request to the buffer memory l0 or ll, the end of decode detection circuit 97 for detecting the end of decoding of the instruction, and the instruction fetch address generation circuit for updating the instruction fetch address.
0038Figs. 5 and 6 show details of the decode control circuit 6. In Fig. 5, numeral 98 denotes a decoder which decodes the operation codes OPl and OP2 of the first and second instructions and reflects the results to the signal lines 254 - 263. Numeral 203 denotes a flip-flop which has a function to delay the input signal one cycle. Numerals 200 and 209 denote inverter gates which logically invert the input signals. Others are AND or OR gates.
0039A signal DS on a signal line 25l indicates the end of decoding of the instruction. It is set when the signal Vl indicating that the first instruction is valid is set on the signal line l53, or when the signal V2 indicating that the second instruction is valid is set on the signal line l54 and a conflict signal CONF is not set on the signal line ll5. This circuit utilizes the fact that if the second instruction is valid, the first instruction is always valid. When the coding of the first and second instructions is completed by the signal line 25l, the instruction fetch address is incremented by an instruction fetch address generation circuit 93 (Fig. 6) so that the succeeding instructions are extracted into the instruction registers l and 2. In Fig. 6, a signal line l33 denotes a fetch address of the instruction to be fetched from the instruction buffer memory ll. When the decoding of the instruction is completed, the address of the previous instruction in the register 232 is incremented by the instruction length 284 of the decoded instruction by the adder 23l and the result is held in the register 232 for use in fetching the next instruction from the buffer memory ll. The end of instruction decode signal line 25l of Fig. 5 is used to set the register 232.
0040The instruction length of the decoded instruction is supplied to the signal line 284. The signal line 259 is set when the first instruction uses the address generation circuit 8, and the signal line 260 is set when the second instruction uses the address generation circuit 8. The signal line 255 is set when the first instruction uses the address generation circuit 9, and the signal line 274 is set when the second instruction uses the address generation circuit 9. The signal lines l53 and l54 indicate the validity of the first and second instructions, respectively. The signal line 28l is set when the first and second instructions cannot be simultaneously decoded by the conflict of the address generation circuits 8 and 9. The signal line 254 is set when the first instruction is of 6-byte length, and the signal line 280 is set when the second instruction is of 6-byte length. As described above, when the first instruction is of 6-byte length, the second instruction is not decoded, and when the second instruction is of 6-byte length, the second instruction is not decoded in parallel. As a result, the signal line 286 is set only when the decoding of only the first instruction is completed and the succeeding instruction is to be decoded in the next decode cycle. Thus, in this case, the instruction fetch address is incremented by the instruction length ILl of the first instruction. When the signal line 286 is not set, the first and second instructions can be decoded in parallel. In this case, the address is incremented by a sum of the instruction length of the first instruction and the instruction length of the second instruction (ILl + IL2). Thus, the instruction length ILl of the first instruction is set in the signal line 282, and the sum ILl + IL2 of the instruction length ILl of the first instruction and the instruction length IL2 of the second instruction is set in the signal line 283 so that the instruction length of the decoded instruction is set in the signal line 284 and the next instruction fetch address is produced on the line 285 by adding the original instruction address in the register 32 and the instruction length on the line 284 by the adder 23l. The next instruction fetch address is set in the register 232.
0041If the decoded instruction is the branch instruction, not the original instruction address in the register 232 but the branch-to instruction address l3l generated by the address generation circuit 9 of Fig. l is selected by the selector 290 and added to the instruction length on the line 284.
0042In Fig. 5, the signal line 265 is set when the first instruction is of 6-byte length and the second operand of the instruction is to be fetched. It is set in the second cycle from the extraction of the 6-byte instruction into the instruction register l. The signal line 253 indicates one-cycle delay of the end of decode signal, and the signal line 254 is set when the first instruction is of 6-byte length and meets the condition for the signal line 265.
0043The signal line SELlXAA9 266 is set when the first instruction uses the address generation circuit 9 and requires to read the index register. The signal line 255 is set when the first instruction uses the address generation circuit 9, and the signal line 256 is set when the first instruction requires to read the index register. Since the signal line 257 is set when the first instruction requires to read the base register, the signal line SELlBAA9 267 is set when the first instruction uses the address generation circuit 9 and requires to read the base register. Similarly, the signal line SELlDAA9 268 is set when the first instruction uses the address generation circuit 9 and requires the addition of the displacement.
0044Since the signal line 26l is set when the second instruction requires to read the index register, the signal line SEL2XAA8 269 is set when the second instruction uses the address generation circuit 8 and requires to read the index register. Similarly, since the signal line 262 is set when the second instruction requires to read the base register, the signal line SEL2BAA8 270 is set when the second instruction uses the address generation circuit 8 and requires to read the base register. Since the signal line 263 is set when the second instruction requires the addition of the displacement, the signal line SEL2DAA8 27l is set when the second instruction uses the address generation circuit 8 and requires the addition of the displacement. The address calculation by the second instruction cannot always be performed and the possibility of execution is examined by the instruction combination recognition circuit 96. In this circuit, the signal line 259 is set when the first instruction uses the address generation circuit 8, and the signal line 260 is set when the first instruction uses the address generation circuit 8. Thus, the signal 264 indicates the condition to permit the use of the address generation circuit 8 by the second instruction. The signal lines 265 - 27l have been explained in connection with Fig. 4.
0045As seen from the above description, the signal line 259 is set when the first instruction uses the address generation circuit 8, the signal line 264 is set when the second instruction uses the address generation circuit 8, and the signal line 265 is set when the first instruction is of 6-byte length and the address calculation of the second operand of the instruction is to be carried out by the address generation circuit 8. The operand fetch request REQ l0 on line 272 for the operand memory l0 may be set in the above three cases. On the other hand, since the signal line 255 is set when the first instruction uses the address generation circuit 9 and the signal line 274 is set when the second instruction uses the address generation circuit 9, the instruction fetch request REQ ll to the instruction buffer memory ll may be set in the above two cases.
0046In this manner, the decode control circuit 6 decodes the operation codes of the first and second instructions to effect control necessary to the memory reference of the first instruction (load instruction), that is, issues input data select control of the address generation circuit 8 and memory read request to the buffer memory l0, and effects control necessary to memory reference of the second instruction (branch instruction), that is, issues input data select control of the address generation circuit 9 and memory read request to the buffer memory ll. It also detects the end of decoding of the first and second instructions to exactly calculate the addresses of the instructions to be next extracted into the instruction registers l and 2 by using the instruction address adder 23l so that the instructions are sequentially fetched.
0047In the above description, it has been assumed that the load instruction and the branch instruction extracted into the instruction registers l and 2 can always refer the memory in parallel and the decoded in parallel. However, in the following case, the second instruction (branch instruction) cannot refer the memory in parallel with the load instruction. Namely, when the register number specified by the index register or the base register of the branch instruction is specified by an Rl part of the first instruction (load instruction) for updating the content thereof, it is necessary to generate the branch-to instruction address of the second instruction (branch instruction) after the operand is fetched from the buffer memory l0 by the first instruction (load instruction).
0048Detail of the conflict detection circuit 5 which detect whether the first instruction changes the register used in the address generation of the second instruction when the instructions are extracted into the instruction registers l and 2 is shown in Fig. 7. The signal line l05 indicates a register number GRl to be updated by the first instruction, and the signal lines ll2 and ll3 indicate the index register number 2X and the base register number 2B used in the address generation by the second instruction. They are compared by comparators 300 and 30l, and if they match, the signal lines 3l3 and 3l4 are set. Those signals are logically ANDed by gates 302 and 303 with the signal line CHGl 3l0 which indicates that the first instruction changes the content of the general purpose register specified by Rl and the signal line NEED2X 3l2 which indicates that the second instruction requires the readout of the index register or the signal line NEED2B which indicates that the second instruction requires the readout of the base register. If the register number to be changed by the first instruction is equal to the register number to be read by the second instruction, the signal line CONF ll5 is set.
0049The signal line ll5 is connected to the decode control circuit 6. In Fig. 5, if the signal line ll5 is set, the AND gate 20l is not conditioned and the AND gates 2l0 and 2l7 which use the output signal 250 of the AND gate 20l are also not conditioned so that the read request to the memory by the second instruction is suppressed. In Fig. 6, when the signal line ll5 is set, the output 286 of the OR gate 226 is set and the instruction length 282 of the first instruction is selected and it is supplied to the next instruction fetch address calculation adder 23l through the signal line 284 as an increment.
0050If the conflict detection circuit 5 detects that the register to be updated by the first instruction is to be read as the index or base register of the second instruction, the end of decode detection circuit 99 controls only the execution of the first instruction, and the second instruction is again extracted into the instruction register l by the instruction fetch address generation circuit after the first instruction has been decoded. It is necessary to suppress the decoding of the branch instruction until the preceding load instruction operand is fetched. This may be done by a conventional logic and is not explained here.
0051The operation performed when the branch instruction and the load instruction are extracted into the instruction register l and the instruction register 2, respectively, is now explained. In Fig. 5, since the first instruction uses the address generation circuit 9, the signal line 255 is set, and the select signals 266 - 268 are set. Since the second instruction uses the address generation circuit 8, the signal line 260 is set and the signal line 259 is not set. Accordingly, the signal line 264 is set and the select signals 269 - 27l are set. As a result, the data ll2 - ll4 of the second instruction (load instruction are selected by the selectors l90 - l92 of Fig. 4 and supplied to the signal lines ll8 - l20. On the other hand, the data l06 - l08 of the first instruction (branch instruction) are selected by the selectors l93 - l95 and supplied to the signal lines l2l - l23. In this manner, the address generation circuit 8 calculates the operand address of the second instruction (load instruction), and the address generation circuit 9 calculates the branch-to address of the first instruction (branch instruction).
0052A read request 272 to the buffer memory l0 and a read request to the buffer memory ll are set, and the memories are referred by using the addresses calculated above.
0053In Fig. 6, since none of the signal lines ll5, 254, 255, 259, 260, 274 and 280 is set, the output of the OR gate 226 is not set and the sum (ILl + IL2) of the first instruction length ILl and the second instruction length IL2 is selected by the AND gate 228 and supplied to the adder 23l. As a result, the instruction fetch address is incremented by the length of the two instructions, the branch instruction and the load instruction.
0054In this manner, whichever of the instruction registers l and 2 the instruction which uses the address generation circuit 8 or 9 is extracted to, the exact corresponding address generation circuit is selected and the address calculation and the memory reference are performed.
0055As described above, when the two instructions which do not cause conflict between the address generation circuits 8 and 9 are extracted into the instruction registers l and 2, only the conflict between the registers need be detected. However, depending on the combination of the two instructions, it is necessary to suppress parallel decoding of the two instructions in the address generation stage. This is a feature of the present invention and will be specifically described below.
0056An operation performed when load instructions are extracted into both the instruction registers l and 2 is first explained, and then an operation performed when branch instructions are extracted into both the instruction registers l and 2 is explained.
0057When the load instructions are extracted into the instruction registers l and 2, the instruction combination recognition circuit 96 of Fig. 5 sets the signal line 259 to indicate that the first instruction uses the address generation circuit 8, and the output signal of the inverter gate 209 assumes logical "0". Accordingly, even if the signal 260 is set to indicate that the second instruction uses the address generation circuit 8, the AND gate 2l0 is not conditioned and a use permission signal 264 for the use of the address adder 8 by the second instruction is not set. Accordingly, the output signals of the AND gates 2ll - 2l3 are not set. Therefore, in the selectors l90 - l92 of Fig. 4, the data lines l06 - l08 of the first instruction are selected and supplied to the signal lines ll8 - l20. As a result, the address generation circuit 8 can calculate the operand address of the load instruction in the instruction register l. In Fig. 5, when the signal line 259 is set, the operand fetch request signal 272 to the buffer memory l0 is set and the operand is fetched from the buffer memory l0. On the other hand, since none of the first and second instructions uses the address generation circuit 9, the signal lines 255 and 274 are not set and the signal line 273 is not set. As a result, the buffer memory ll is not read. In the instruction combination recognition circuit 96II of Fig. 6, since the signal lines 259 and 260 which indicate that the first and second instructions use the address generation circuit 8 are set, the output of the AND gate 220 is set and the signal line 286 is set through the signal line 28l. As a result, the instruction length ILl 282 of the first instruction is selected and supplied to the adder 23l. The instruction fetch address is incremented by the length of the load instruction in the instruction register l and the load instruction in the second instruction register 2 is extracted into the instruction register l.
0058In this manner, when the load instructions are extracted into the instruction registers l and 2, the instruction combination recognition circuit 96I and 96II controls such that only the load instruction in the instruction register l is executed and the load instruction in the instruction register 2 is executed one cycle later.
0059The operation performed when the branch instructions are extracted into the instruction registers l and 2 is now explained. Since both the first and second instructions use the address generation circuit 9, the decode signals 255 and 274 of Fig. 5 are set. Since the branch instruction does not use the address generation circuit 8, the instruction combination recognition circuit 96I is not activated. As a result, the select signals 266 - 268 and the read request 273 to the buffer memory ll are set. In the selectors l93 - l95 of Fig. 4, the data l06 - l08 of the first instruction (branch instruction) are selected and supplied to the signal lines l2l - l23. Thus, the branch-to instruction address of the first instruction is calculated in the address generation circuit 9. Since the signal line 273 has been set, the branch instruction can be fetched from the buffer memory ll. Since none of the first and second instructions uses the address generation circuit 8, the read request 272 to the buffer memory l0 is not set. In the instruction combination recognition circuit 96II of Fig. 6, since the AND gate 22l is comditioned, the instruction length 282 of the first instruction is selected and supplied to the adder 23l. The instruction fetch address is incremented by the length of the branch instruction in the instruction register l, and the branch instruction in the instruction register 2 is again extracted into the instruction register l.
0060As explained above, in the processor shown in Fig. l, the two instructions which are consecutive on the main memory l3 are fetched from the buffer memory ll in parallel and extracted into the instruction registers l and 2. The conflict detection circuit 5 detects the conflict between the registers that the general purpose register to be updated by the first instruction is to be read by the second instruction during the address generation, and the instruction combination recognition circuit 96 detects the conflict that the first and second instructions use the same address generation circuit or buffer memory. In this manner, the parallel execution of the first and second instructions is enabled and the execution time is shortened.
0061An effect of the high speed operation in the present processor is explained with reference to Fig 8, in which D, A, L, E and P denote instruction execution cycles in a pipeline system. In the cycle D, an instruction is decoded and an address is generated, in the cycle A, the buffer memory is referred, in the cycle L, the data read from the memory is transferred, in the cycle E, the data is operated, and in the cycle P, the result is stored. A branch instruction does not require the operation in the cycle E and the storing in the cycle P.
0062In Figs. 8a and 8b, (i) is a load instruction, (ii) is a branch instruction, and (iii) is a branch-to instruction of the branch instruction. In a prior art processor in which plural instructions are not decoded in parallel, the load instruction and the branch instruction are decoded serially in each cycle as shown in Fig. 8a. Thus, the decoding of the branch-to instruction can be started two cycles after the end of the decoding (cycle D) of the branch instruction (ii). On the other hand, in the present invention, since the load instruction and the branch instruction can be decoded in parallel, the branch instruction (ii) can be decoded in parallel with the load instruction (i) as shown in Fig. 8b, and the operand fetching of the load instruction and the fetching of the branch-to instruction of the branch instruction can be executed in parallel. Thus, the decoding of the branch-to instruction is attained one cycle earlier than that in Fig. 8a. In Fig. 8b, the execution cycles for the branch instruction (ii) are designated by Dʹ, Aʹ, Lʹ, Eʹ, and Pʹ. In Fig. 8b, the operation cycle E of the load instruction and the operation cycle Eʹ of the branch instruction are performed in parallel, but only one operation unit is required because the branch instruction does not need operation.
0063In Figs. 8c and 8d, (i) is a branch instruction, (ii) is an add instruction, and (iii) is an instruction which uses in the address calculation a general purpose register modified by the add instruction. An instruction format of the add instruction is same as that shown in Fig. 3a. Let us assume that the branch instruction (i) fails to branch. In the prior art processor in which plural instructions are not decoded in parallel, the decoding of the instruction (iii) is started after the operand of the add instruction (ii) on the buffer memory l0 has been fetched and the operation result has been stored as shown in Fig. 8c. Thus, there is a 4-cycle overhead. On the other hand, in the present invention, since the branch instruction (i) and the add instruction (ii) can be decoded in parallel as shown in Fig. 8d, the overhead to the instruction (iii) can be shortened to three cycles.
0064As seen from Figs. 8a - 8d, the instruction execution speed is increased depending only on the combination of the instructions extracted into the instruction registers l and 2 in parallel without regard to the sequence of the two instructions. In addition, there is no need to increase the hardware of the operation unit.
0065In order to parallelly decode the instructions only by the combination of the instructions, it is necessary that the instruction registers l and 2 and the address generation circuits 8 and 9 or the buffer memories l0 and ll can be interconnected in any way. In the processor shown in Fig. l, the selector 4 attains this function. The address generation circuits 8 and 9 and the buffer memories l0 and ll are correlated, respectively, the output of the address generation circuit 8 is sent only to the buffer memory l0, and the output of the address generation circuit 9 is sent only to the buffer memory ll. When the instruction extracted into the instruction register l refers the buffer memory l0, the selector 4 controls such that the address is calculated by the address generation circuit 8, and when the instruction refers the buffer memory ll, the selector 4 controls such that the address is calculated by the address generation circuit 9. The same is true for the instruction extracted into the instruction register 2. Another processor for attaining the above function is shown in Fig. 9, in which the instruction registers l and 2 are permanently correlated to the address generation circuits 8 and 9, respectively. The address of the instruction extracted into the instruction register l is always calculated by the address generation circuit 8, and the address of the instruction extracted into the instruction register 2 is always calculated by the address generation circuit 9. When the buffer memory ll is to be referred by the address calculated by the address generation circuit 8, the signal line l28 is selected by the selector 802 and the instruction is fetched. When the buffer memory l0 is to be referred by the address calculated by the address generation circuit 9, the signal line l3l is selected by the selector 80l and the operand is fetched. The overall configuration of the processor is substantially same as that of Fig. l, and only the different functions are explained below.
0066When a 6-byte length instruction is extracted into the instruction register l, the selector 800 switches the address calculation of the first operand and the address calculation of the second operand. Detail of the selector 800 is shown in Fig. l0. The input signal line 265 is same as that shown in Fig. 5. When the signal line 265 is set, the signal lines l09 and ll0 are selected to calculate the address of the second operand. The signal line 265 is set only when the second operand of the 6-byte length instruction is to be operated. When the signal line 265 is not set, the signal lines l07 and l08 are selected. The selectors 80l and 802 select the addresses to be used for the memories. When the instruction in the instruction register 2 refers the buffer memory l0, the signal line 264 is set, and the signal line l3l is selected by the selector 80l. When the instruction in the instruction register l refers the buffer memory ll, the signal line 804 is selected, and the signal line l28 is set by the selector 802. When the signal lines 264 and 804 are not set, the selector 80l selects the signal line l28 and the selector 802 selects the signal line l3l. As shown in Fig. 5, when the first instruction does not refer the buffer memory l0 and the second instruction refers the buffer memory l0 and the second instruction is valid (the signal line 250 is set), the signal line 264 is set. As shown in Fig. ll, when the first instruction refers the buffer memory ll and the first instruction is valid (the signal line l53 is set), the signal line 804 is set.
0067As seen from the above description, the processor shown in Fig. 9 can parallelly decode the instructions depending on the combination of the instructions extracted into the instruction registers l and 2 and parallelly refer the buffer memories l0 and ll. As a result, the same effect as that shown in Fig. 8 is attained.
0068In accordance with the present invention, two instructions can be parallelly extracted and they can be parallelly decoded depending on the combination of the instruction. The fetching of the operand of the succeeding instruction and the fetching of the branch-to instruction of the branch instruction can be performed one cycle faster than a case where the parallel decoding is not effected. As a result, the instruction execution time is shortened by one cycle, and the execution time of the succeeding instruction which utilizes the result of the preceding instruction and the execution time of the branch-to instruction are shortened.
Contents4
10 sheets
Sheet 1 Sheet 2 Sheet 3 Sheet 4 Sheet 5 Sheet 6 Sheet 7 Sheet 8 Sheet 9 Sheet 10
Every citation, both ways
| Document | Relation | Office | Cited during |
|---|---|---|---|
| EP0407911A3 | Cited by | European Patent Office (EPO) | Search report |
| US6742110B2 | Cited by | United States of America | Applicant |
| EP0399762A2 | Cited by | European Patent Office (EPO) | Search report |
| US5202967A | Cited by | United States of America | Search report |
| US6092177A | Cited by | United States of America | Search report |
| EP0939364A3 | Cited by | European Patent Office (EPO) | Search report |
| EP0481031A1 | Cited by | European Patent Office (EPO) | Search report |
| US6256726B1 | Cited by | United States of America | Applicant |
| WO9742567A1 | Cited by | World Intellectual Property Organization (WIPO) | International search |
| US6330664B1 | Cited by | United States of America | Applicant |
| EP0625746A1 | Cited by | European Patent Office (EPO) | Search report |
| EP0473420A3 | Cited by | European Patent Office (EPO) | Search report |
| EP0625746A1 | Cited by | European Patent Office (EPO) | Search report |
| US5561775A | Cited by | United States of America | Search report |
| EP0992893A1 | Cited by | European Patent Office (EPO) | Applicant |
| EP0399760A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0496928A3 | Cited by | European Patent Office (EPO) | Search report |
| EP0473420A2 | Cited by | European Patent Office (EPO) | Search report |
| US5752064A | Cited by | United States of America | Search report |
| EP0463299A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0939364A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0407911A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0463299A3 | Cited by | European Patent Office (EPO) | Search report |
| EP0399762A3 | Cited by | European Patent Office (EPO) | Search report |
| US6009506A | Cited by | United States of America | Search report |
| US5574941A | Cited by | United States of America | Search report |
| EP0902362A2 | Cited by | European Patent Office (EPO) | Search report |
| US5287465A | Cited by | United States of America | Search report |
| EP0354740A3 | Cited by | European Patent Office (EPO) | Search report |
| US5475824A | Cited by | United States of America | Search report |
| EP0481031A4 | Cited by | European Patent Office (EPO) | Search report |
| EP0354740A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0496928A2 | Cited by | European Patent Office (EPO) | Search report |
| EP0399760A3 | Cited by | European Patent Office (EPO) | Search report |
| US7424598B2 | Cited by | United States of America | Applicant |
| EP0902362A3 | Cited by | European Patent Office (EPO) | Search report |
| FR2686717A1 | Cited by | France | Search report |
| EP0992893A1 | Cited by | European Patent Office (EPO) | Search report |
| US5628024A | Cited by | United States of America | Search report |
| EP0021399A1 | Cites | European Patent Office (EPO) | Search report |
4 priority claims, no other members on record
Priority claims4
| Document | Office | Kind | Date |
|---|---|---|---|
| 6565186 | Japan | A | |
| 6565186 | Japan | – | |
| JP19860065651 | – | – | – |
| 6565186 | – | – | – |
22 legal events, as 3 offices reported them to INPADOC
Over the term
Point at a mark for the eventEvents
| Event | Code | Office | |
|---|---|---|---|
| Notification of lapseLapsedST | ST | FR | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Gb: european patent ceased through non-payment of renewal feeCeasedGBPC | GBPC | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| Lapsed in a contracting state [announced via postgrant information from national office to epo]LapsedPG25 | PG25 | EP | |
| European patent in force as of 2002-01-01IF02 | IF02 | GB | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| Annual fee paid to national office [announced via postgrant information from national office to epo]GrantedPGFP | PGFP | EP | |
| No opposition filedOpposition26N | 26N | EP | |
| No opposition filed within time limitOppositionORIGINAL CODE: 0009261PLBE | PLBE | EP | |
| Information on the status of an ep patent application or granted ep patentGrantedSTATUS: NO OPPOSITION FILED WITHIN TIME LIMITSTAA | STAA | EP | |
| Fr: translation filedET | ET | EP | |
| Corresponds to:REF | REF | EP | |
| Designated contracting statesAK | AK | EP | |
| (expected) grantORIGINAL CODE: 0009210GRAA | GRAA | EP | |
| First examination report despatched17Q | 17Q | EP | |
| Request for examination filed17P | 17P | EP | |
| Designated contracting statesAK | AK | EP | |
| Search report despatchedORIGINAL CODE: 0009013PUAL | PUAL | EP | |
| Designated contracting statesAK | AK | EP | |
| Public reference made under article 153(3) epc to a published international application that has entered the european phaseORIGINAL CODE: 0009012PUAI | PUAI | EP |
Numbers
- Publication
- 0239081
- Publication, DOCDB
- 0239081
- Publication, EPODOC
- EP0239081
- Application
- 87104345
- Application, DOCDB
- 87104345
- Application, EPODOC
- EP19870104345
Titles6
- German
- Datenprozessor in Pipelinestruktur mit der Fähigkeit mehrere Befehle parallel zu dekodieren und auszuführen.
- English
- Pipelined data processor capable of decoding and executing plural instructions in parallel.
- French
- Processeur de données en pipeline capable de décoder et exécuter plusieurs instructions en parallèle.
- German
- Datenprozessor in Pipelinestruktur mit der Fähigkeit mehrere Befehle parallel zu dekodieren und auszuführen
- English
- Pipelined data processor capable of decoding and executing plural instructions in parallel
- French
- Processeur de données en pipeline capable de décoder et exécuter plusieurs instructions en parallèle
Classification
- CPC, 5
- G06F9/3816
- G06F9/30149
- G06F9/3822
- G06F9/3836
- G06F9/3889
- IPC, 3
- G06F9 30
- G06F9 32
- G06F9 38
Designated states3
- Contracting states, 3
- Germany
- France
- United Kingdom