Information processing system
BACKGROUND OF THE INVENTION 
     This invention relates to an information processing system including plural arithmetic units for implementing a high speed processing of instructions. 
     The implementation of high speed processing in recent years has brought about a system having an arithmetic section divided into a plurality of dedicated arithmetic units in many information processors. For example, there has been proposed a system having an arithmetic section divided into two units, i.e., a general instruction arithmetic unit (GU) for executing a fixed-point instruction, a decimal instruction etc. and a floating-point instruction arithmetic unit (FU) for executing a floating-point instruction at a high speed. A certain system may have an arithmetic unit divided into more sub-arithmetic units. In such an information processing system, if a conditional branch instruction is provided for which a judgement about the success or failure of a branch is determined by a condition code (CC) of a Program Status Word (PSW), and this CC is determined by an operation result, it is required that the CC be created by the corresponding arithmetic unit and be finally transferred to a CC part of a PSW. The transfer time of the CC from each arithmetic unit to branch judgement means influences the performance of the conditional branch instruction. 
     FIG. 1 shows a block diagram of an information processing system having two arithmetic units. In the figure, a main storage unit (MS) 1, a storage control unit (SCU) 2, and an instruction control unit (IU) 3 are usual ones, but an arithmetic unit 4 is characterized by having an general instruction arithmetic unit (GU) 5 and a floating-point instruction arithmetic unit (FU) 6. 
     FIG. 2 shows an example of the conventional construction of GU 5 and FU 6. In the figure, it is assumed that a general instruction arithmetic device 201 in GU 5 performs a fixed-point operation and a decimal operation while a floating-point instruction arithmetic device 210 in FU 6 performs a floating-point operation. CC creation circuits 202 and 211 respectively in GU 5 and FU 6 create CC&#39;s in accordance with the respective forms of instruction by using the results of the above operations. The CC&#39;s thus created are transferred via signal lines 203, 212 and loaded in a CC portion 205 of a PSW through a selector 204. In this example, the CC portion 205 of the PSW is placed in the GU 5, and the CC portion 205 in FU 6 is transferred to GU 5, but the CC portion 205 of the PWS may be placed in either unit. In either case, the CC&#39;s created in a plurality of units must be concentrated where a branch judging circuit 207 is present. The selector 204 acts as a circuit for selecting the CC of GU 5 (GU CC) in response to a fixed point/decimal instruction and for selecting the CC of FU 6 (FU CC) in response to a floating point instruction. 
     Concurrently with the storing of the CC of GU 5 or FU 6 into the CC portion 205 of the PSW, the CC of GU 5 or FU 6 is inputted to a branch judging circuit 207 through a selector 206. The selector 206 serves to select GU CC on signal line 203 when a GU CC change instruction which is executed in the GU 5 to change the previous CC (such as a fixed point addition instruction) exists immediately before a conditional branch instruction (BC instruction: Branch on Condition instruction), to select an FU CC on signal line 212 when an FU CC change instruction which is executed in the FU 6 to change the previous CC, (such as floating point addition instruction) exists and to select a CC of the PSW when another instruction exists. The CC on the signal line 212 or 203 is selected to speed up the branch judgement. The judgement result by a branch judgement circuit 207 is sent out to IU 3 through a branch judgement signal line 208. The IU 3 serves to allocate one instruction buffer (now shown) for each of a main instruction stream and a target instruction stream to speed up the processings upon the generation of a branch instruction. Such control method is known from U.S. Pat. No. 3,614,747.  In the case of success of the branch, instruction fetching and instruction decoding in a main stream of the instruction (a stream including the BC instruction) are stopped, the instructions contained in the instruction buffer for the main stream are cancelled, and instruction decoding of the target stream is also started. Incidentally, it is assumed that instruction fetching from the target instruction has been started at the time of decoding of the BC instruction. On the other hand, in the case of failure of the branch, the instruction fetching from the target stream is stopped and the main stream of instructions is continued. These processings are controlled by a branch control circuit 209. 
     Meanwhile, a problem of the prior art is that since a branch judgement circuit is placed in the GU, a branch judgement is delayed by the time of transferring the CC from FU to GU when an FU CC change instruction exists immediately before a BC instruction, thereby reducing the performance of a BC instruction. This problem also applies in the case where the branch judgement circuit is provided in the FU. 
     SUMMARY OF THE INVENTION 
     An object of this invention is to provide an information processing system having a plurality of arithmetic units in which a high-speed branch judgement of a BC instruction is implemented to early start the decoding of a target instruction in the case of a success of branch, thereby to minimize the branch overhead. 
     In the information processing system having a plurality of arithmetic units, each arithmetic unit produces a condition code on the basis of the corresponding operation result so that the branch judgement of a BC instruction at one place requires the time of transferring the condition code from the arithmetic unit to that place, thereby retarding the branch judgement. Therefore, in accordance with this invention, a branch judgement circuit is provided in each arithmetic unit, a branch judgement unit is decided by means for indicating what arithmetic unit provides the newest condition code, and in compliance with this decision each arithmetic unit performs the branch judgement by using the condition code issued in itself, thereby making unnecessary the transfer time of the condition code and so permitting high speed branch judgement. 
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS 
     The present invention will be apparent from the following detailed description taken in conjunction with the accompanying drawings, in which: 
     FIG. 1 is a block diagram showing, an example of an information processing system having a plurality of arithmetic units; 
     FIG. 2. is a block diagram showing one example of the conventional construction of a plurality of arithmetic units with respect to only CC control; 
     FIG. 3 is a block diagram showing one embodiment according to this invention; 
     FIG. 4 is a circuit diagram of an exemplary concrete construction of the branch judgement circuit as shown in FIG. 3; 
     FIGS. 5A to 5C are timing charts for explaining an operation algorithm of the judgement unit decision circuit as shown in FIG. 3; 
     FIG. 6 is a diagram showing an exemplary concrete construction of the above judgement unit decision circuit; 
     FIGS. 7A and 7B are illustrations showing one example of a stream of instructions; and 
     FIGS. 8A to 8C are timing charts for comparing the prior art with this invention. 
    
    
     DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS 
     FIG. 3 shows one embodiment of this invention and is different from FIG. 2 in that branch judgement circuits 301, 307 are provided in GU 5 and FU 6, respectively, which is accompanied by a judgement unit decision circuit 306 for indicating by which branch judgement circuit the branch judgement should be made, and branch judgement signal lines 302, 308 are sent out from respective GU 5 and FU 6 to IU 3. The operation of FIG. 3 will be explained below. 
     An operation of a fixed point/decimal instruction is performed by a general instruction arithmetic device 201 in GU 5, and on the basis of its result, a CC is generated by a GU CC creation circuit 202. This GU CC is loaded in a CC part 205 of a PSW through a signal line 203 and a selector 204 and also inputted to a branch judgement circuit 301 in GU 5 through a selector 309. On the other hand, an operation of a floating point instruction is performed by a floating point instruction arithmetic device 210 in FU 6, and on the basis of its result, a CC is generated by an FU CC creation circuit 211. This FU CC is inputted to an FU branch judgement circuit 307 through a signal line 212 and also loaded into a CC part 205 of the PSW through the selector 204. 
     Concurrently with the above operation, in the case where a BC instruction comes immediately after a GU CC change instruction, the judgement unit decision circuit 306 sets a CC selection signal line 304, a GU judgement indication signal line 303 and an FU judgement indication signal line 305 to &#34;0&#34;, &#34;1&#34; and &#34;0&#34;, respectively. Accordingly, the CC from the GU CC creation circuit 202 is inputted to the GU branch judgement circuit 301 through the signal line 203 and the selector 309 while the GU branch judgement circuit 301 is activated by the GU judgement indication signal 303, and the result of GU branch judgement is sent to IU 3 through the signal line 302. 
     In the case where the BC instruction comes immediately after an FU CC change instruction, the judgement unit deciding circuit 306 sets the CC selection signal line 304, GU judgement indicating signal 303, and the FU judgement indication signal line 305 to &#34;0&#34;, &#34;0&#34; and &#34;1&#34;, respectively. Thus, the FU branch judgement circuit 307 is activated by the FU indication judgement signal line 305, a branch judgement is made by CC from the signal line 212, and the result of branch judgement is sent to IU 3 through the signal line 308. 
     In the case where GU CC and FU CC change instructions do not exist immediately before the BC instruction, the judgement unit decision circuit 306 sets the CC selection signal line 304, the GU judgement indication signal line 303 and the FU judgement indication signal line 305 to &#34;1&#34;, &#34;1&#34; and &#34;0&#34;, respectively. Thus, the CC part 205 of the PSW is inputted to the GU branch judgement circuit 301 through the selector 309 while the GU branch judgement circuit 301 is activated by the GU judgement indicating signal 303, and a branch judgement is made by PSW CC, and the result of GU branch judgement is sent to IU 3 through the signal line 302. 
     The branch judgement results on the signal lines 302 and 308 are ORed so as to be inputted to the branch control circuit 209. This branch control circuit 209 operates in the same manner as mentioned in the prior art referring to FIG. 2. 
     FIG. 4 shows an exemplary construction of the GU branch judgement circuit 301 and the FU branch judgement circuit 307. In this case, a CC is composed of two bits. In the case of an addition instruction, for example, &#34;00&#34;, &#34;01&#34;, &#34;10&#34; and &#34;11&#34; represent &#34;zero&#34;, &#34;smaller than zero&#34;, &#34;larger than zero&#34; and &#34;overflow&#34;, respectively. This CC is decoded by a decoder 401. The thus decoded signal and a mask part (M 1 ) of a branch instruction 402 which is provided from IU 3 through signal line 309 and ANDed by AND circuits 403-406 thereby makes a judgement of success of the branch when the result is &#34;1&#34;,  and a judgement of failure of the branch when the result is &#34;0&#34;. The judgement results are ORed by an OR circuit 407, are ANDed together with a judgement operation indication signal and a judgement unit indication signal by an AND circuit 408 and sent out. The judgement operation indication signal is generated from IU 3 through signal line 310 during the execution of the BC instruction. As the judgement unit indication signal, in the GU branch judgement circuit 301, the signal on the GU judgement indication signal line 303 of FIG. 3 is applied thereto while in the FU branch judgement circuit 307, the signal on the FU judgement indication signal line 305 is applied thereto. That is, GU branch judgement circuit 301 and FU branch judgement circuit 307 perform a judgement operation only when the judgement operation indication signal is &#34;1&#34; and the judgement unit indication signal is &#34;1&#34;. 
     FIGS. 5A, 5B and 5C and FIG. 6 show diagrams for explaining a judgement unit decision circuit 306. 
     FIGS. 5A-5C show timing charts of an algorithm of deciding a branch judgement unit in the case where the BC instruction and the GU CC change instruction and FU change instruction are adjacent to each other. FIG. 5A shows the case where the GU CC change instruction exists immediately before the BC instruction. In this case, one cycle delay signal indicating the fact that the GU CC change instruction is being executed is &#34;1&#34; at the time of branch judgement, so that the branch judgement can be performed by using the GU CC. FIG. 5B shows the case where the FU CC change instruction exists immediately before the BC instruction. In this case also, as in FIG. 5A, one cycle delay signal indicating the fact that the FU CC change instruction is being executed is &#34;1&#34; at the time of branch judgement, so that the branch judgement can be performed by using the FU CC. FIG. 5C shows the case where neither a GU change instruction nor a FU change instruction exists immediately before the BC instruction. In this case, the branch judgement can be performed by the PSW CC. 
     FIG. 6 shows an exemplary construction of the judgement unit decision circuit 306. On the basis of the algorithm as shown in FIGS. 5A to 5C, the signal on the FU judgement indication signal line 305 can be obtained by delaying the signal representative of the fact that the FU CC change instruction is being executed by a delay latch 601 by one cycle while the signal on the GU judgement indication signal line can be obtained by passing an output from the delay latch 601 through an inverting circuit 603. The signal on the CC selection signal line 304 can be obtained in such a manner that the output from the delay latch 601 and the output, resulting from the signal representative of the fact that the GU CC change instruction is executed being delayed by the delay latch 602 by one cycle, are NORed by a NOR circuit 604. Incidentally, the signal representative of the fact that the GU CC change instruction and FU CC change instruction are being executed may be obtained from the GU 5 and FU 6 through signal lines 311 and 312, respectively. 
     Next, referring to a concrete example, an explanation will be made as the fact that this invention implements a higher speed branch judgement instruction operation of a BC instruction than the prior art. 
     FIGS. 7A and 7B show examples where an CC change instruction exists immediately before the BC instruction. Although it is assumed that in FIGS. 7A and 7B instructions other than the BC instruction and the CC change instruction are load instructions (L), any instruction may be applicable. FIG. 7A shows the case where a fixed point addition instruction (A) as a CC change instruction exists immediately before the BC instruction, and in this case, the branch judgement by be CC in GU 5 must be performed. FIG. 7B shows the case where a floating point addition (AE) as a CC change instruction exists immediately before the BC instruction, and in this case the branch judgement by the CC in FU 6 must be performed. 
     FIG. 8A is a timing chart showing when the stream of instructions are executed and a success of the branch is attained. In the figure, characters D, A, L, and E indicate stages of an instruction pipe line, which are an instruction decode, address calculation, operand load and execution stage. The CC created by an A instruction is defined as the CC in GU 5 at the end of the E stage of the A instruction, and the branch judgement is made after a half cycle, and after a further half cycle the decoding of a fetched target instruction is started. As understood from FIG. 7A, three cycles are required from the completion of execution of the BC instruction to the start of execution of the target instruction. This timing entirely applies to both the prior art and this invention. This is because the branch judgement circuit 207 of FIG. 2 and the branch judgement circuit 301 of FIG. 3 are located at the same portion. 
     FIG. 8B shows a timing chart of the prior art when a stream of instructions of FIG. 7B are executed and a success of the branch is attained. The CC generated by an AE instruction is defined as a CC in FU 6 at the end of the E stage of the AE instruction in FU 6. However, one cycle is required to transfer this FU CC to GU 5 in FIG. 1 so that the branch judgement in GU 5 is performed after a further half cycle and the decoding of the target instruction is performed after a further half cycle. Therefore, four cycles are required from the completion of the BC instruction to the start of execution of the target instruction. That is, an excess of one cycle is required as compared with the case of GU CC. 
     FIG. 8C shows a timing chart of this invention when a stream of instructions are executed and a success of the branch is attained. This is the same as FIG. 8C in which three cycles are required from the completion of execution of the BC instruction to the start of execution of the target instruction, i.e., a reduction of one cycle is made as compared with the prior art of FIG. 8B. That is, the CC of the AE instruction is defined as an FU CC at the end of the E stage of the AE instruction, the branch judgement is made in FU 6 after a half cycle and the decoding of the target instruction is started in IU 3 after a further half cycle. 
     Although one embodiment of this invention has been explained hereinbefore, it is of course apparent that this invention is not limited thereto. For example, in the embodiment the branch judgement by PSW CC is performed in the case of absence of the CC change instruction immediately before the BC instruction. However, with the CC changed lastly in each unit being held, the CC of the unit in which the CC has been lastly changed before the BC instruction may be used for branch judgement. 
     As understood from the above explanation, in accordance with this invention, there is provided a branch judgement circuit for each arithmetic unit in an information processing system including plural arithmetic units so that a high-speed branch judgement of a conditional branch instruction, i.e., an improvement of the performance of the conditional branch instruction can be attained.