RussianPatents.com
|
Device for correcting order of a result of summing of floating point numbers |
|||||||||||||||||||||
IPC classes for russian patent Device for correcting order of a result of summing of floating point numbers (RU 2267806):
|
FIELD: computer science. SUBSTANCE: device has order correction adder, block for forming scaling signal, resolution inputs for scaling result, limiting and order correction codes of which are, respectively, first, second, and third inputs of device, and output is connected to first information input of order correction adder, second information input of which is fourth input of device, third input of device is connected to third information input of order correction adder, output of which is device output. EFFECT: higher speed of summing process, registration of scaling constant. 2 cl, 3 dwg
The invention relates to the field of computer technology, in particular to devices adding floating-point numbers, and can be used in the development of arithmetic devices, microprocessors, both universal and specialized. In the operation of addition of floating point numbers pre-order of the result is equal to the order of a larger absolute value of the operand by the RO. If the result requires normalization, then pre-order result is reduced by an amount called the order of correction, is equal to the number of senior non-significant digits of the mantissa SH. According to the standard ANSI/IEEE 754" on binary arithmetic, the order of the result must be an integer, not a smaller one. Thus, the result should not move to the left by the number of digits exceeds the maximum allowable for the data operand value M, which is equal to M=PB-1, i.e. the order of the larger operand minus 1. The value M is called the code restrictions. If M is less than the number of senior non-significant digits of the mantissa is shifted left by M bits, and the result will be denormalizing number, thereby providing a mode of gradual negative overflow. According to the standard when receiving denormalizing result in the case of an open mask interrupts "underflow" is mastalirova is selected. It lies in the fact that the mantissa is normalized without regard to code restrictions. If the result is zero or negative, then it is added to the scaling constant 3·213. The order of the result is positive and generates an interrupt "underflow". A device for correction of the order of the addition of floating point numbers that contain the adder correction order, the first and second inputs which receive respectively the order of a greater number and order of correction (Behrooz Parhami, Computer Arithmetic: Algorithm and Hardware Implementation, str, Oxford University Press, 2000). The disadvantages of this device include the absence of signal scaling, which makes it impossible to consider the scaling constants, when the order of the result is zero or negative, and is not taken into account the fact that the discharge order correction are formed at different points in time, and this significantly slows down the calculation order of the result. The closest in technical essence to the invention is a device for correction of the order of the addition of floating-point numbers, which is part of the system that contains the schema definition code left shift, the schema definition of a right shift by one digit, incrementor, the inverter code left shift, and the adder to the correction order (US No. 6301594, CL G 06 F 7/00, 2001). The disadvantage of this device is the lack of consideration of the scaling constants, when the order of the result is zero or negative, and the long process of summation, due to the fact that the adder is started after the entry of the last digit of the order of correction. The technical result is to accelerate the summation in the correction of the order of the addition of floating-point numbers, as well as the inclusion of the scaling constants in obtaining denormalizing result in the case of an open mask interrupts "underflow" ("underflow"). This is achieved in that the device for the correction of the order of the addition of floating-point numbers includes a processing unit scaling inputs allow scaling of the code, limitations and correction procedures which are respectively the first, second and third inputs of the device, the output is connected to the first information input of the adder correction order, the second information input of which is the fourth input of the third input connected to the third information input of the adder correction procedure whose output is the output device according to the invention contains an adder correction procedure, which contains three in the La, the first of which performs the following functions: X1=PB6And6, P6=And6+PB6, X2=X1+P6And5PB5, P5-6=P6(A5+PB5), X3=X1+P5-6And4PB4, P4-6=P5-6(A4+PB4), X4=X3+P4-6And3PB3 P3-6=P4-6(A3+PB3), X5=X4+P3-6And2PB2, P2-6=P3-6(A2+PB2), Y1=Cin+PB1, Y2=CinPB1, G6=X5+Y2P2-6+P2-6A1Y1, the second node performs the following function: G13=G6+(PB13+PB12+...+PB8+PB7), and the third node performs the following functions: where G6, G13 - signal transfer of six and thirteen least significant bits, respectively, Scale - tone scale, Withinsignal input transfer. A6, A5, A4And3And2, A1values of inversions of the signals SH32l, SH16l, SH8l, SH4l, SH2l, SH1lcode , shift considering the limitation of the magnitude of the shift, respectively"32", "16", "8", "4", "2", "1" discharge, respectively, Xi, Yj- intermediate signals, i, j - a is f number, i ranging from 1 to 5, j ranging from 1 to 2, R2-6, R3-6, R4-6, R5-6, R6signals propagate transfer, respectively, by discharges from the 2 nd to 6-nd, 3-th and 6-th, 4-th and 6-th, 5-th and 6-th and 6-th discharge, PB15, PB14,...,PB2, PB1signals about the larger addend, respectively, 15-th, 14-th,..., 1-th digits, in addition, the processing unit scaling performs the following logical function: Scale=ScaleEN* where Scale - signal scaling, SH64l, SH32l, SH16l, SH8l, SH4l, SH2l, SH1lthe code signals of the shift taking into account the limitations of the shift values, respectively"32", "16", "8", "4", "2", "1" discharge, respectively, M7, M6,..., M1signals code restrictions, respectively, 7-th, 6-th,..., 1-th digits, ScaleEN - permission signal scaling result. The essence of the invention lies in the fact that the implementation of the inventive device as described above using adder correction procedure and the processing unit scaling, allows to provide high performance with a significant simplification of the device. A comparison of the proposed device with the closest analogue suggests the criterion of "novelty", and the lack of in analogically characteristics of the claimed device says about the criterion of "inventive step". Preliminary tests allow to judge about the possibility of widespread industrial use. Figure 1 shows the block diagram of the device for the correction of the order of the addition of floating-point numbers, figure 2 presents the principle of structural breaks adder correction order on separate nodes, figure 3 presents an example implementation of the first node of the adder correction order by the appropriate logical formulas. The device comprises a block 1 signal scaling adder 2 correction order, the first, second, third and fourth inputs 3-1-3-4 and output 3-5. Output 4 unit 1 signal scaling is connected to the first information input of adder 5-1 2 correction order, the second input 5-2 which is the fourth entry 3-4 device, and a third input 5-3 connected to the third input 3-3 device. Inputs 3-1-3-3 are input unit 1, signal scaling, and the output of 3-5 device is the output of the adder 2 correction order. Unit 1 signal scaling performs the following logical function: Scale=Scale EN* where Scale - signal scaling, SH64l, SH32l, SH16l, SH8l, SH4l, SH2l, SH1lthe code signals of the shift considering the limitation of the magnitude of the shift line is the result for "32", "16", "8", "4", "2", "1" discharge, respectively, M7, M6,..., M1signals code restrictions, respectively, 7-th, 6-th,..., 1-th digits, ScaleEN - permission signal scaling result. The adder 2 correction procedure contains three nodes, the first of which performs the following functions: X1=PB6And6, P6=And6+PB6, X2=X1+P6And5PB5, P5-6=P6(A5+PB5), X3=X1+P5-6And4PB4, P4-6=P5-6(A4+PB4), X4=X3+P4-6And3PB3, P3-6=P4-6(A3+PB3), X5=X4+P3-6And2PB2, P2-6=P3-6(A2+PB2), Y1=Cin+PB1, Y2=CinPB1, G6=X5+Y2P2-6+P2-6A1Y1, the second node performs the following function: G13=G6+(PB13+PB12+...+PB8+PB7), and the third node performs the following functions: where G6, G13 - signal transfer of six and thirteen least significant bits, respectively, Scale - tone scale, Withinsignal input transfer, And6And5And4, A3And2, A1- value the inversions of the signals SH32 l, SH16l, SH8l, SH4l, SH2l, SH1lcode , shift considering the limitation of the magnitude of the shift, respectively"32", "16", "8", "4", "2", "1" discharge, respectively, Xi, Yj- intermediate signals, i, j are integers, i ranging from 1 to 5, j ranging from 1 to 2, R2-6, R3-6P4-6, R5-6, R6signals propagate transfer, respectively, by discharges from the 2 nd to 6-nd, 3-th and 6-th, 4-th and 6-th, 5-th and 6-th and 6-th discharge, PB15, PB14,..., PB2, PB1signals about the larger addend, respectively, 15-th, 14-th,..., 1-th digits. An example implementation of the first node of the adder correction order by the appropriate logical formulas presented in figure 3, where the logical block 6 is an element of type OR, and logical blocks 7-11 are elements of type 2-1-AND-OR. The device operates as follows : Consider the Block 1 signal scaling Scale: Scale=ScaleEN* He strobiles signal resolution scaling of the ScaleEN. Next, Scale equal to "1"if SH64l="1", a M7="0" (the first term in brackets). If SH64l=M7then move on to comparing the factors of the second term. If SH32l="1", and the M6="0"Scale produced. If SH64l=M7and SH32l=M6 then go ahead and analyzed discharges SH16land M5. This process ends with a comparison of discharges SH1land Ml. Thus, the signals SHland M bit are compared, beginning with the oldest discharge; if the discharge SHlmore appropriate level M, then the signal scaling, otherwise proceed to the comparison of younger grades. Using several times the Boolean identityyou can convert the expression for the Scale to the following: Scale=ScaleEN* The expression for the signal Scale can be expanded relatively SH1l. Scale=A1+B1*SH1l, where A1and In1are functions that depend on SH2l, SH4l, SH8l, SH16land SH32l. The dependence on M is immaterial from the point of view of the delay, since M is formed in advance. A1and B1you can prepare for the same time as SH1l. Thus, this expression can be obtained for one logical level on the element 1I-2I-ILY. Similarly, you can put A1and B1relatively SH2l. A1=A2a+B2a*SH2l, In1=And2b+2b*SH21, Here a2aIn2aAnd2band In2bare functions that depend on SH4l, SH8 l, SH16land SH32l. These expressions can be implemented in one logic level after receiving SH2lAnd2aIn2a, A2band In2b. Thus, the sequential decomposition of the signal on the decimal Scale SHlgives a chance to implement it through one logical level after the appearance of SH1l. Figure 2 shows the partitioning of the adder 2 correction procedure on three corresponding node: the node with the digits "1" through "6", the node with the digits "7" "13" and the node with two older bits. "15"-bit order more (double extended format) supplied to the adder in the direct phase, "6"-bit shift code is inverted, while the "9" senior ranks of the second term are filled units. In addition, two senior level adder start signal scaling Scale. Addition occurs in the reverse code, as well as the amount according to the standard must be positive (Emin="1"), then there will always be circular migration, therefore, in the adder have to start Within=1. On the other hand, when the number of senior non-significant digits of the mantissa is equal to "64"bits of code shift with SH32lon SH1lequal to "1", that is, in the adder from about greater subtracted code 111111, and it is necessary to take the code 1000000. If in this case to do Within="0"then it will be equivalent to an additional subtract"1" from order more. Thus, we believe The transfer of "6" low G6 can be expanded in series inversions bits of code shift SH1l, SH2l,..., SH32land get it through one logical level after joining SH11. An example implementation figure 3. Transfers in Junior "6" digits of the adder can be calculated not slower than the G6, that is, "1"-"6" discharge order results can be obtained through two logic level after SH1l. The sum in the middle group is determined by the signal G6: - if the transfer is, the amount equal to PB13, PB12,..., PB8, PB7, - if transfer no amount equal {PB13, PB12,..., PB8, PB7}+{11...11) (it can be computed in advance). Thus, the sum of the digits "7" "13" can also be calculated through the "2" logic level after joining SH1l. The transfer of 13 digits G13 is used to calculate the two high-order bits of the sum. Obviously, G13=G6+(PB13+PB12+...+PB8+PB7). The expression can be calculated for the same time as the G6, as it differs only summands in brackets, which do not depend on SHl. For "14"-th and "15"on the digits of the sum can be written: that can be implemented in one logiteck the level after receiving G13. Thus, all the bits about the result, it is possible to form through "2" logic level after receiving minor category code shift SH1l. Thus, the proposed device allows you to speed up the process of summation in the correction of the order of the addition of floating-point numbers, and to consider the scaling constant when receiving denormalizing result in the case of an open mask interrupts "underflow" ("underflow"). 1. A device for correction of the order of the addition of floating-point numbers, characterized in that it comprises a processing unit scaling inputs allow scaling of the code, limitations and correction procedures which are respectively the first, second and third inputs of the device, the output is connected to the first information input of the adder correction order, the second information input of which is the fourth input of the third input connected to the third information input of the adder correction procedure whose output is the output device, and the adder correction procedure contains three nodes, the first of which performs the following functions: X1=PB6And6, P6=And6+PB6, X2=X1+P6And5PB5 , P5-6=P6(A5+PB5), X3=X1+P5-6And4PB4, P4-6=P5-6(A4+PB4), X4=X3+P4-6And3PB3 P3-6=P4-6(A3+PB3), X5=X4+P3-6And2PB2, P2-6=P3-6(A2+PB2), Y1=Cin+PB1, Y2=CinPB1, G6=X5+Y2P2-6+P2-6A1Y1, the second node performs the following function: G13=G6+(PB13+PB12+...+PB8+PB7), and the third node performs the following functions: where G6, G13 - signal transfer of six and thirteen least significant bits, respectively, Scale - signal scaling Cinsignal input transfer And6And5And4And3, A2, A1values of inversions of the signals SH32l, SH16l, SH8l, SH4l, SH2l, SH1lcode , shift considering the limitation of the magnitude of the shift, respectively"32", "16", "8", "4", "2", "1" discharge, respectively, Xi, Yj - intermediate signals, i, j are integers, i ranging from 1 to 5, j ranging from 1 to , P2-6, R3-6, R4-6, R3-6, R6signals propagate transfer, respectively, by discharges from the 2 nd to 6-nd, 3-th and 6-th, 4-th and 6-th, 5-th and 6-th and 6-th digit, PB15PB14,...PB2, PB1signals about the larger addend, respectively, 15-th, 14-th,..., 1-th digits. 2. The device according to claim 1 characterized in that the processing unit scaling performs the following logical function: Scale=ScaleEN* where Scale - signal scaling SH64l, SH32l, SH16l, SH8l, SH4l, SH2lSH1lthe code signals of the shift taking into account the limitations of the shift values, respectively"32", "16", "8", "4", "2", "1" discharge, respectively, M7, M6,...M1signals code restrictions respectively the 7th, 6th,...1-th digits, ScaleEN signal resolution mashtabirovanie result.
|
© 2013-2014 Russian business network RussianPatents.com - Special Russian commercial information project for world wide. Foreign filing in English. |