WO2011161859A1 - 半導体集積回路及び指数算出方法 - Google Patents

半導体集積回路及び指数算出方法 Download PDF

Info

Publication number
WO2011161859A1
WO2011161859A1 PCT/JP2011/002148 JP2011002148W WO2011161859A1 WO 2011161859 A1 WO2011161859 A1 WO 2011161859A1 JP 2011002148 W JP2011002148 W JP 2011002148W WO 2011161859 A1 WO2011161859 A1 WO 2011161859A1
Authority
WO
WIPO (PCT)
Prior art keywords
bit
circuit
data
value
bit string
Prior art date
Application number
PCT/JP2011/002148
Other languages
English (en)
French (fr)
Inventor
充文 柴山
Original Assignee
日本電気株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 日本電気株式会社 filed Critical 日本電気株式会社
Priority to EP11760675.6A priority Critical patent/EP2431865B1/en
Priority to CN201180001677.1A priority patent/CN102378960B/zh
Priority to JP2011539841A priority patent/JP4883251B1/ja
Priority to US13/262,748 priority patent/US8862647B2/en
Publication of WO2011161859A1 publication Critical patent/WO2011161859A1/ja

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03MCODING; DECODING; CODE CONVERSION IN GENERAL
    • H03M7/00Conversion of a code where information is represented by a given sequence or number of digits to a code where the same, similar or subset of information is represented by a different sequence or number of digits
    • H03M7/14Conversion to or from non-weighted codes
    • H03M7/24Conversion to or from floating-point codes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/38Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
    • G06F7/48Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation using non-contact-making devices, e.g. tube, solid state device; using unspecified devices
    • G06F7/499Denomination or exception handling, e.g. rounding or overflow
    • G06F7/49905Exception handling
    • G06F7/4991Overflow or underflow
    • G06F7/49915Mantissa overflow or underflow in handling floating-point numbers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F7/00Methods or arrangements for processing data by operating upon the order or content of the data handled
    • G06F7/38Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
    • G06F7/48Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation using non-contact-making devices, e.g. tube, solid state device; using unspecified devices
    • G06F7/499Denomination or exception handling, e.g. rounding or overflow
    • G06F7/49942Significance control

Definitions

  • the present invention relates to a semiconductor integrated circuit and an index calculation method, and more particularly to an arithmetic processing technique in digital signal processing.
  • floating-point arithmetic In digital signal processing, floating-point arithmetic has the advantage of being able to calculate with high accuracy even when the range of signal data to be handled is wide, but it requires a complicated circuit, so the circuit scale and power consumption are large. There's a problem.
  • fixed point arithmetic has the advantage that the circuit is simple and the circuit scale and power consumption are small, but there is a problem that the arithmetic accuracy is low.
  • block floating point normalization processing is performed in the next step.
  • the maximum index of all data in the block is obtained.
  • the entire block is shifted (normalized) by the determined maximum exponent.
  • the maximum exponent indicates the maximum exponent that does not cause overflow of all data in the block.
  • the maximum exponent is equal to the exponent value of the data having the maximum absolute value among all data in the block.
  • the following method is known as a method for efficiently obtaining the maximum index (for example, Patent Document 1).
  • (1) The absolute value of each data in the block is calculated.
  • (2) The logical sum of the absolute values of the calculated data is calculated.
  • (3) The bit position on the MSB (Most Significant Bit) side of the calculated logical sum is detected, and the maximum exponent is obtained.
  • a block to be normalized a block composed of eight data of input data 1 to input data 8 which are the following 8-bit input data is considered.
  • each data value is shown in two's complement notation.
  • the leftmost bit is the MSB and the rightmost bit is the LSB.
  • MSB is a sign bit.
  • Input data 1 00001111 Input data 2: 00110001 Input data 3: 00000100 Input data 4: 11110011 Input data 5: 11111000 Input data 6: 00000100 Input data 7: 00001011 Input data 8: 00011011
  • the absolute value of each data (input data 1 to 8) in the block is calculated.
  • absolute values of the input data 1 to 8 are shown as absolute values 1 to 8.
  • the absolute value of the input data k is shown as an absolute value k (k is a positive integer from 1 to 8).
  • the fifth bit is detected as the bit position where the bit value first becomes 1 when viewed from the MSB (Most Significant Bit) side of the calculated logical sum.
  • the MSB is the 7th bit
  • the LSB Large (Significant Bit) is the 0th bit.
  • the maximum exponent is -1.
  • normalized data 1 to 8 all data in the group (input data 1 to 8) is normalized based on the maximum index obtained to obtain normalized data (normalized data 1 to 8). Specifically, when the maximum exponent is -1, the bit is shifted to the left by 1 bit. The data after normalization of the input data 1 to 8 is shown as normalized data 1 to 8 below. Data after normalization of the input data k is indicated as normalized data k (k is a positive integer from 1 to 8).
  • the maximum exponent is -1
  • the actual values of the normalized data 1 to 8 are values obtained by multiplying each data by 2 to the power of -1.
  • Normalized data 1 00101110 Normalized data 2: 01100010 Normalized data 3: 00001100 Normalized data 4: 11100110 Normalized data 5: 11110000 Normalized data 6: 00001100 Normalized data 7: 00010110 Normalized data 8: 00110110
  • the normalization process as described above it is necessary to calculate the absolute value by repeating a plurality of times as many as the number of data constituting the block. Therefore, in the normalization process as described above, the processing time for repeating the calculation of the absolute value, which takes time, is drastically increased. As described above, the normalization process as described above has a problem that the maximum exponent cannot be calculated at high speed, and the circuit scale and power consumption are large.
  • Patent Document 2 one-position detection for obtaining the value of each bit in order using mask data for extracting data for determining the value per bit of the data indicating the position where the bit is 1 in the input data A method is disclosed.
  • Patent Document 2 in order to determine the value per bit of the data at the position where the bit is 1, only one mask process and one comparison are required. It is described that the processing time for detecting the position where the bit becomes 1 can be shortened.
  • Patent Document 3 detects the bit position where the first bit of the input data and a bit having a different logical state first appear, and based on the information indicating the distance from the position of the decimal point of the input data to the detected bit position, A normalized data generation circuit for shifting input data is disclosed. Patent Document 3 describes that, according to the normalized data generation circuit, most of the shift operation can be performed in hardware, so that the generation time of normalized data can be shortened.
  • Patent Documents 2 and 3 as in the present invention, a bit indicating whether or not the values of adjacent bits are different from each other for each set of adjacent bits from a bit string constituting data to be normalized It does not disclose a technique for generating a bit string including.
  • the present invention is to solve such a problem, and when normalizing a plurality of data with a common index, the calculation of the index can be speeded up, and the circuit scale and consumption for that purpose can be increased.
  • An object of the present invention is to provide a semiconductor integrated circuit and an index calculation method capable of reducing power.
  • a semiconductor integrated circuit is a semiconductor integrated circuit that calculates an index of a plurality of data when the plurality of data is normalized by a common index, and is a first circuit that constitutes the data. For each pair of adjacent bits in one bit string, a bit having a transition value indicating that the values of the adjacent bits are different or a non-transition value indicating that the values of the adjacent bits are not different And a bit string generation circuit that generates a second bit string including the bits of the transition values of the plurality of second bit strings generated from the plurality of first bit strings that constitute each of the plurality of data by the bit string generation circuit And an exponent calculation circuit for calculating the exponents of the plurality of data based on the positions.
  • An index calculation method is an index calculation method for calculating an index of a plurality of data when the plurality of data is normalized by a common index, and includes a first index that configures the data. For each pair of adjacent bits in one bit string, a bit having a transition value indicating that the values of the adjacent bits are different or a non-transition value indicating that the values of the adjacent bits are not different And a plurality of second bit strings generated from a plurality of first bit strings that constitute each of the plurality of data, based on the bit positions of the transition values. Calculating an index of data.
  • the index calculation can be speeded up, and the circuit scale and power consumption can be reduced. It is possible to provide a semiconductor integrated circuit and an index calculation method that can be used.
  • FIG. 1 is a block diagram showing a configuration of a semiconductor integrated circuit according to a first exemplary embodiment of the present invention. It is a block diagram which shows the structure of the maximum index calculation circuit concerning Embodiment 1 of this invention. It is a block diagram which shows the structure of the edge detection circuit concerning Embodiment 1 of this invention.
  • FIG. 5 is a timing diagram showing an operation of the maximum exponent calculation circuit according to the first exemplary embodiment of the present invention. It is a block diagram which shows the structure of the normalization circuit concerning Embodiment 2 of this invention. It is a timing diagram which shows operation
  • FIG. 1 is a block diagram showing a configuration of a semiconductor integrated circuit according to the first embodiment of the present invention.
  • the semiconductor integrated circuit 50 includes a bit string generation circuit 51 and an exponent calculation circuit 52.
  • the semiconductor integrated circuit 50 calculates an index of a plurality of data when normalizing the plurality of data by a common index.
  • the bit string generation circuit 51 does not change the transition value indicating that the values of the bits adjacent to each other in the pair of bits adjacent to each other in the first bit string constituting the data or the values of the bits adjacent to each other.
  • the exponent calculation circuit 52 generates a plurality of pieces of data based on the positions of the bits of the transition values of the plurality of second bit strings generated from the plurality of first bit strings constituting each of the plurality of data by the bit string generation circuit 51. Calculate the index.
  • the bit string generation circuit 51 receives a plurality of data to be normalized by a common index.
  • the bit string generation circuit 51 does not change the transition value indicating that the values of the bits adjacent to each other in the set of adjacent bits of the first bit string constituting the data are different, or the values of the bits adjacent to each other.
  • the bit string generation circuit 51 outputs a plurality of second bit strings generated from a plurality of first bit strings constituting each of the plurality of data to the exponent calculation circuit 52.
  • the exponent calculation circuit 52 calculates the exponents of the plurality of data based on the bit positions of the transition values of the plurality of second bit strings output from the bit string generation circuit 51.
  • the exponent calculation circuit 52 outputs the calculated exponent.
  • the values of the bits adjacent to each other for each set of bits adjacent to each other in the first bit string constituting the data to be normalized are as follows.
  • a second bit string including bits indicating whether or not they are different is generated.
  • the second bit string it can be determined whether or not the values of the bits adjacent to each other are different for each set of bits adjacent to each other in the first bit string. Therefore, it is possible to specify the shift amount in which the normalized value is correctly expressed without any change in the data sign. That is, the maximum index can be calculated.
  • the semiconductor integrated circuit 50 According to the semiconductor integrated circuit 50 according to the first embodiment, it is possible only to perform a logical operation on whether or not the values of adjacent bits are different from each other. And the circuit scale and power consumption for that purpose can be reduced.
  • FIG. 2 is a block diagram showing a configuration of the maximum exponent calculation circuit 100 according to the first embodiment of the present invention.
  • the maximum exponent calculation circuit 100 is a circuit that calculates the maximum exponent of all data in a block with respect to a block composed of a plurality of input data.
  • the maximum exponent calculation circuit 100 sequentially inputs all the data in the block based on the input clock signal, and calculates the maximum exponent of all the data in the block.
  • the maximum exponent calculation circuit 100 outputs the maximum exponent calculated for each block.
  • the maximum exponent calculation circuit 100 identifies the end of the block with reference to the input block end signal.
  • the input data is input to the maximum exponent calculation circuit 100 from an external circuit (not shown), for example.
  • the external circuit outputs the asserted block end signal to the maximum exponent calculation circuit 100 in a cycle in which the last input data in the block is output to the maximum exponent calculation circuit 100.
  • the maximum exponent calculation circuit 100 includes an edge detection circuit 101, a logical sum circuit 102, a register 103, and an MSB side bit position detection circuit 104 as main circuits.
  • the edge detection circuit 101 is a circuit that detects a transition (edge) of a value of a bit string that constitutes input data.
  • the edge detection circuit 101 detects a transition (edge) of the value of the bit string constituting the input data.
  • the edge detection circuit 101 outputs the detection result as an edge detection result 105 to the logical sum circuit 102.
  • the edge detection circuit 101 calculates a value indicating whether or not the values of the nth bit and the (n + 1) th bit are different from the MSB of the bit string constituting the input data (n is an integer of 0 or more). .
  • the edge detection circuit 101 arranges the calculated values at the nth bit from the MSB.
  • the edge detection circuit 101 generates a bit string in which the values calculated in this way are arranged as a detection result.
  • the 0th bit is said from the MSB, it is assumed to be the MSB.
  • the value indicating whether or not the bit value is different is 1 (transition value) when the bit value is different, and is 0 (non-transition value) when the bit value is not different.
  • Embodiment 1 exemplifies a case where the value indicating whether or not the bit values are different is 0 when the bit values are equal.
  • the edge detection circuit 101 functions as the bit string generation circuit 51.
  • the OR circuit 102 calculates a logical sum of the edge detection result 105 output from the edge detection circuit 101 and the register value 107 output from the register 103.
  • the logical sum circuit 102 outputs the calculated logical sum to the register 103 as the logical sum value 106.
  • the register 103 is a circuit that holds the logical sum value 106 output from the logical sum circuit 102 for each operation cycle based on the input clock signal.
  • the register 103 outputs the held logical sum value to the logical sum circuit 102 and the MSB side bit position detection circuit 104 as a register value 107 for each operation cycle. Further, the register 103 recognizes the last operation cycle in which the final logical sum value 106 based on the last input data of the block is input from the logical sum circuit 102 with reference to the block end signal.
  • the register 103 resets the logical sum value held for each block to 0, which is an initial value, in the cycle following the last operation cycle of each block.
  • the register 103 outputs the final logical sum value 106 to the MSB side bit position detection circuit 104 and then resets the held logical sum value.
  • the MSB side bit position detection circuit 104 detects the bit position of the transition value on the MSB side of the bit string constituting the register value 107 for the register value 107 output from the register 103.
  • the MSB side bit position detection circuit 104 is a circuit that calculates and outputs the maximum exponent from the detected bit position. Specifically, the MSB side bit position detection circuit 104 is the case where the position where the bit value of the register value 107 output from the register 103 is 1 is the Mth bit from the MSB side (M is 0 or more). Integer), and outputs ⁇ 1 ⁇ M as the maximum exponent.
  • the register 103 outputs the register value 107 for each operation cycle, but the MSB side bit position detection circuit 104 calculates the maximum exponent based on the register value 107 indicating the final logical sum value as a block.
  • the MSB side bit position detection circuit 104 refers to the block end signal and recognizes a cycle in which the register value 107 indicating the final logical sum value as a block is output from the register 103.
  • the MSB side bit position detection circuit 104 detects the bit position on the MSB side of the bit string constituting the register value 107 indicating the final logical sum value.
  • the MSB side bit position detection circuit 104 calculates the maximum exponent from the detected bit position.
  • the MSB side bit position detection circuit 104 outputs the calculated maximum exponent.
  • the OR circuit 102, the register 103, and the MSB side bit position detection circuit 104 function as the exponent calculation circuit 52.
  • the edge detection circuit 101 includes a plurality of exclusive OR (XOR) circuits 110.
  • the edge detection circuit 101 calculates and outputs an exclusive OR between adjacent bits of a bit string constituting input data. That is, when the input data is composed of a bit string of Y bits, the edge detection circuit 101 is composed of Y ⁇ 1 XOR circuits 110 (Y is a positive integer).
  • FIG. 3 shows a configuration example of the edge detection circuit 101 when the input data is composed of an 8-bit bit string of b7 to b0.
  • the edge detection circuit 101 calculates an exclusive OR between adjacent bits of a bit string constituting input data.
  • the edge detection circuit 101 outputs the calculated exclusive OR as the edge detection results e7 to e1 to the OR circuit 102.
  • bit b7 of the input data and bit e7 of the edge detection result are the MSB.
  • FIG. 4 is a timing diagram showing an operation of the maximum exponent calculation circuit 100 according to the first exemplary embodiment of the present invention.
  • the maximum exponent calculation circuit 100 operates based on the input clock signal.
  • a block to be normalized As an example of a block to be normalized, consider a block consisting of the following eight data of input data 1 to input data 8. Each input data is 8 bits. In the following, each data value is shown in two's complement notation. In the following data bit strings, the leftmost bit is the MSB and the rightmost bit is the LSB. MSB is a sign bit.
  • Input data 1 00001111 Input data 2: 00110001 Input data 3: 00000100 Input data 4: 11110011 Input data 5: 11111000 Input data 6: 00000100 Input data 7: 00001011 Input data 8: 00011011
  • the edge detection circuit 101 detects the transition (edge) of the value of the bit string constituting the input data 1.
  • the edge detection circuit 101 outputs the detection result as the edge detection result 1 to the logical sum circuit 102. More specifically, the edge detection circuit 101 calculates and outputs an exclusive OR between adjacent bits of the bit string constituting the input data 1.
  • the logical sum circuit 102 calculates the logical sum of the edge detection result 1 output from the edge detection circuit 101 and the register value 1 output from the register 103.
  • the logical sum circuit 102 outputs the calculated logical sum as a logical sum value 1 to the register 103.
  • the value of the register value 1 in the cycle 1 is the initial value 0.
  • the register 103 holds the logical sum value 1 output from the logical sum circuit 102 in cycle 1.
  • the register 103 outputs the held logical sum value 1 as the register value 2 in cycle 2 which is the next operation cycle.
  • the input data 2 is input to the maximum exponent calculation circuit 100.
  • the edge detection circuit 101 detects a transition (edge) of the value of the bit string constituting the input data 2.
  • the edge detection circuit 101 outputs the detected result as the edge detection result 2 to the logical sum circuit 102. More specifically, the edge detection circuit 101 calculates and outputs an exclusive OR between adjacent bits of the bit string constituting the input data of the input data 2.
  • the logical sum circuit 102 calculates the logical sum of the edge detection result 2 output from the edge detection circuit 101 and the register value 2 output from the register 103.
  • the logical sum circuit 102 outputs the calculated logical sum as a logical sum value 2 to the register 103.
  • the value of the register value 2 which is the output of the register 103 in the cycle 2 is the logical sum value 1 held in the cycle 1.
  • the register 103 holds the logical sum value 2 output from the logical sum circuit 102 in cycle 2.
  • the register 103 outputs the held logical sum value 2 as the register value 3 in cycle 3 which is the next operation cycle.
  • maximum exponent calculation circuit 100 inputs input data 3 to 8 in each operation cycle.
  • the edge detection circuit 101 detects transitions (edges) of the values of the bit strings constituting the input data 3 to 8, respectively.
  • the edge detection circuit 101 outputs each of the detection results as edge detection results 3 to 8.
  • Edge detection result 3 0000101
  • Edge detection result 4 0101010
  • Edge detection result 5 0000100
  • Edge detection result 6 0000101
  • Edge detection result 7 0001110
  • Edge detection result 8 0010110
  • the logical sum circuit 102 calculates the logical sum of each of the edge detection results 3 to 8 output from the edge detection circuit 101 and each of the register values output from the register 103 in each cycle.
  • the logical sum circuit 102 outputs each of the calculated logical sums to the register 103 as logical sum values 3 to 8.
  • the values of the register values 3 to 8, which are the outputs of the register 103 in each of the cycles 3 to 8, are the logical sum values 2 to 7 held in the cycles 2 to 7, respectively.
  • the MSB side bit position detection circuit 104 changes the MSB side transition of the bit string constituting the logical sum 8 with respect to the final logical sum 8 as the block. Detect the bit position of the value.
  • the MSB side bit position detection circuit 104 calculates the maximum exponent from the detected bit position.
  • the register 103 resets the logical sum value held for the block to 0, which is the initial value. As a result, the register 103 outputs an initial value 0 in the next cycle.
  • the MSB side bit position detection circuit 104 and the register 103 identify the last operation cycle of each block as a cycle in which the value of the input block end signal becomes 1. In FIG. 4, since the value of the block end signal is 1 in cycle 8, it indicates that cycle 8 is the last operation cycle of the block.
  • the edge detection result of this input data is 1000000. Accordingly, since the MSB of the final logical sum value as a block becomes the value 1, the maximum exponent of the block whose input data includes the negative maximum value is calculated as 0. That is, according to the first embodiment, the correct maximum exponent can be calculated even when the negative value is included in the input data.
  • the first embodiment is characterized in that the maximum exponent is calculated using the edge detection circuit 101 in the block floating point normalization process. Since the edge detection circuit 101 only needs to calculate the exclusive OR between adjacent bits of the bit string constituting the input data, the edge detection circuit 101 is realized by a circuit having a simple configuration in which the number of logical stages including a plurality of XOR circuits is one. can do.
  • the maximum exponent calculation circuit can calculate the maximum exponent at a high speed as compared with the normalization process that calculates the absolute value of the input data.
  • the circuit scale and power consumption can be reduced.
  • the maximum exponent calculation circuit according to the first embodiment can correctly process even when the negative value is included in the input data. Therefore, according to the maximum exponent calculation circuit according to the first embodiment, even when the data value is the negative maximum value, it is necessary to specially process the data, or to avoid using the negative maximum value. There is a feature that there is no need to do.
  • FIG. 5 is a block diagram showing a configuration of a block floating point normalization circuit (hereinafter referred to as a normalization circuit) according to the second exemplary embodiment of the present invention.
  • a normalization circuit a block floating point normalization circuit
  • the normalization circuit performs normalization processing in block floating point for each input data constituting the block.
  • the normalization circuit outputs data obtained by normalizing input data as normalized data.
  • the normalization circuit according to the second embodiment includes a memory 120, a maximum exponent calculation circuit 100 according to the first embodiment, and a shift circuit 130.
  • the maximum exponent calculation circuit 100 calculates the maximum exponent for the input data that has been input.
  • the maximum exponent calculation circuit 100 outputs the calculated maximum exponent as the maximum exponent 108 to the shift circuit 130.
  • the memory 120 holds the input data while the maximum exponent calculation circuit 100 calculates the maximum exponent of the input data.
  • the input data is sequentially input from the external device (not shown) to the memory 120 and the maximum exponent calculation circuit 100, for example.
  • the memory 120 sequentially holds input data input from an external device.
  • the memory 120 sequentially outputs the held input data as the input data 121 to the shift circuit 130 after the maximum exponent calculation circuit 100 completes the calculation of the maximum exponent.
  • the shift circuit 130 performs normalization processing by shifting the input data output from the memory 120 based on the maximum exponent 108 calculated by the maximum exponent calculation circuit 100.
  • FIG. 6 is a timing diagram showing the operation of the normalization circuit according to the second exemplary embodiment of the present invention.
  • the normalization circuit according to the second exemplary embodiment of the present invention operates based on the input clock signal.
  • a block composed of the following eight data of input data 1 to input data 8 is considered as in the first embodiment.
  • Each input data is 8 bits.
  • each data value is shown in two's complement notation.
  • Input data 1 00001111 Input data 2: 00110001 Input data 3: 00000100 Input data 4: 11110011 Input data 5: 11111000 Input data 6: 00000100 Input data 7: 00001011 Input data 8: 00011011
  • FIG. 6 shows operations in cycle 1 ′ to cycle 8 ′ after the maximum exponent calculation circuit 100 calculates the maximum exponent of input data in cycles 1 to 8 shown in FIG.
  • the operations in cycles 1 to 7 are the same as those shown in FIG. 4, and the illustration is omitted.
  • cycle 9 and cycle 1 ′ indicate the same operation cycle.
  • the memory 120 holds the input data while the maximum exponent calculation circuit 100 calculates the maximum exponent of the input data in cycles 1 to 8. Next, after the maximum exponent calculation circuit 100 completes the calculation of the maximum exponent, the memory 120 sequentially outputs the held input data to the shift circuit 130 in cycles 1 ′ to 8 ′.
  • the memory 120 identifies the timing at which the maximum exponent calculation circuit 100 completes the calculation of the maximum exponent with reference to the block end signal. Specifically, the memory 120 starts outputting the input data 1 to 8 held from the cycle 9 following the cycle 8 in which the value of the block end signal becomes 1.
  • the memory 120 refers to the block end signal and identifies the timing to end the output of input data. Specifically, the memory 120 ends the output of the input data at cycle 8 ′ when the value of the block end signal becomes 1 again.
  • the external device outputs a block end signal having a value of 1 in cycle 8 ′ when a cycle corresponding to the number of data of input data 1 to 8 has passed since cycle 8 in which output of input data has been completed.
  • the maximum exponent calculation circuit 100 calculates the maximum exponent of the input data input in cycles 1 to 8. Next, the maximum exponent calculation circuit 100 outputs ⁇ 1 as the calculated maximum exponent to the shift circuit 130 in cycle 9. The maximum exponent calculation circuit 100 continues the output of ⁇ 1 which is the maximum exponent until cycle 8 ′, which completes the output of the input data held in the memory 120.
  • the maximum exponent calculation circuit 100 refers to the block end signal and identifies the timing to end the output of the maximum exponent. Specifically, the maximum exponent calculation circuit 100 ends the output of the maximum exponent at cycle 8 ′ when the value of the block end signal becomes 1 again.
  • the shift circuit 130 sequentially shifts the input data 1 to 8 output from the memory 120 based on ⁇ 1 which is the maximum index calculated and output by the maximum index calculation circuit 100 in cycles 1 ′ to 8 ′. Perform normalization.
  • the shift circuit 130 outputs data obtained by normalizing the input data 1 to 8 as normalized data 1 to 8.
  • the shift circuit 130 normalizes the input data 1 to 8 by shifting the input data 1 to 8 to the left by m bits. (M is an integer of 0 or more).
  • the normalized data 1 to 8 output from the shift circuit 130 have the following values, and the normalization process is completed correctly.
  • Data after normalization of the input data k is indicated as normalized data k (k is a positive integer from 1 to 8).
  • Normalized data 1 00101110 Normalized data 2: 01100010 Normalized data 3: 00001100 Normalized data 4: 11100110 Normalized data 5: 11110000 Normalized data 6: 00001100 Normalized data 7: 00010110 Normalized data 8: 00110110
  • the normalization circuit 100 according to the first embodiment since the maximum exponent calculation circuit 100 according to the first embodiment is used to calculate the maximum exponent with a large calculation processing amount in the normalization processing of the block floating point, it is necessary for the calculation processing of the maximum exponent. The circuit scale and power consumption can be reduced. Furthermore, the normalization circuit according to the second embodiment includes the maximum exponent calculation circuit 100 that can calculate the maximum exponent at high speed and can reduce the circuit scale and power consumption. Then, the normalization circuit performs block floating point normalization processing based on the maximum exponent calculated by the maximum exponent calculation circuit 100. As a result, according to the second embodiment, block floating point normalization processing can be executed at high speed, and the circuit scale and power consumption can be reduced.
  • FIG. 7 is a block diagram showing the configuration of the maximum exponent calculation circuit 150 according to the third embodiment of the present invention.
  • the maximum exponent calculation circuit 150 is a circuit that calculates the maximum exponent of all data in a block with respect to a block composed of a plurality of input data.
  • the maximum exponent calculation circuit 150 calculates the maximum exponent at high speed by performing edge detection in parallel.
  • the same components as those in the maximum exponent calculation circuit 100 according to the first embodiment of the present invention are denoted by the same reference numerals.
  • the maximum exponent calculation circuit 150 sequentially inputs all four data in the block based on the input clock signal, and calculates the maximum exponent of all the data in the block.
  • the maximum exponent calculation circuit 150 outputs the maximum exponent calculated for each block. At this time, the maximum exponent calculation circuit 150 identifies the end of the block with reference to the input block end signal.
  • the maximum exponent calculation circuit 150 includes four edge detection circuits 101, a logical sum circuit 152, a register 103, and an MSB side bit position detection circuit 104 as main circuits.
  • the edge detection circuit 101 is a circuit that detects a transition (edge) of a value of a bit string that constitutes input data.
  • the four edge detection circuits 101 receive input data a to d, respectively.
  • the four edge detection circuits 101 detect transitions (edges) of the values of the bit strings constituting the respective input data.
  • the four edge detection circuits 101 output the detection results to the OR circuit 152 as edge detection results 155a to 155d, respectively.
  • the OR circuit 152 is a five-input circuit, to which the edge detection results 155a to 155d output from the four edge detection circuits 101 and the register value 107 output from the register 103 are input.
  • the logical sum circuit 152 calculates the logical sum of the input edge detection results 155a to 155d and the register value 107.
  • the logical sum circuit 152 outputs the calculated logical sum as a logical sum value 156 to the register 103.
  • the register 103 is a circuit that holds the logical sum value 156 output from the logical sum circuit 152 for each operation cycle based on the input clock signal.
  • the register 103 outputs the held logical sum value to the logical sum circuit 152 and the MSB side bit position detection circuit 104 as the register value 107 for each operation cycle.
  • the register 103 recognizes the last operation cycle with reference to the block end signal.
  • the register 103 resets the logical sum value held for the block to 0, which is the initial value, in the last operation cycle of the block.
  • the MSB side bit position detection circuit 104 detects the bit position of the transition value on the MSB side of the bit string constituting the register value 107 for the register value 107 output from the register 103.
  • the MSB side bit position detection circuit 104 is a circuit that calculates and outputs the maximum exponent from the detected bit position. Specifically, the MSB side bit position detection circuit 104 is the case where the position where the bit value of the register value 107 output from the register 103 is 1 is the Mth bit from the MSB side (M is 0 or more). Integer), and outputs ⁇ 1 ⁇ M as the maximum exponent.
  • the register 103 outputs the register value 107 for each operation cycle, but the MSB side bit position detection circuit 104 calculates the maximum exponent based on the final register value 107 as a block.
  • the MSB side bit position detection circuit 104 refers to the block end signal and recognizes a cycle in which the register value 107 indicating the final logical sum value as a block is output from the register 103.
  • the MSB side bit position detection circuit 104 detects the bit position of the transition value on the MSB side of the bit string constituting the register value 107 indicating the final logical sum value, and calculates the maximum exponent.
  • the MSB side bit position detection circuit 104 outputs the maximum exponent.
  • FIG. 8 is a timing chart showing the operation of the maximum exponent calculation circuit 150 according to the third embodiment of the present invention.
  • the maximum exponent calculation circuit 150 operates based on the input clock signal.
  • Input data 1 00001111 Input data 2: 00110001 Input data 3: 00000100 Input data 4: 11110011 Input data 5: 11111000 Input data 6: 00000100 Input data 7: 00001011 Input data 8: 00011011
  • the maximum exponent calculation circuit 150 receives four pieces of input data 1 to 4.
  • Each of the four edge detection circuits 101 detects each transition (edge) of the value of the bit string constituting the input data 1 to 4.
  • the four edge detection circuits 101 output the detection results as edge detection results 1a to 1d to the OR circuit 152. More specifically, each of the edge detection circuits 101 calculates and outputs an exclusive OR between adjacent bits for each of the bit strings constituting the input data 1a to 1d.
  • the detection result of the input data 1 is the edge detection result 1a
  • the detection result of the input data 2 is the edge detection result 1b
  • the detection result of the input data 3 is the edge detection result 1c
  • the detection of the input data 4 is detected.
  • the result is the edge detection result 1d.
  • Edge detection result 1a 0011100
  • Edge detection result 1b 0101001
  • Edge detection result 1c 0000101
  • Edge detection result 1d 0101010
  • the logical sum circuit 152 calculates the logical sum of the edge detection results 1a to 1d output from the four edge detection circuits 101 and the register value 1 output from the register 103, respectively.
  • the logical sum circuit 152 outputs the calculated logical sum as the logical sum value 1 to the register 103.
  • the value of the register value 1 in the cycle 1 is the initial value 0.
  • the register 103 holds the logical sum value 1 output from the logical sum circuit 152 in cycle 1.
  • the register 103 outputs the held logical sum value 1 as the register value 2 in cycle 2 which is the next operation cycle.
  • the maximum exponent calculation circuit 150 receives four pieces of input data 5-8.
  • Each of the four edge detection circuits 101 detects each transition (edge) of the value of the bit string constituting the input data 5 to 8.
  • the edge detection circuit 101 outputs each detection result to the OR circuit 152 as edge detection results 2a to 2d. More specifically, each of the edge detection circuits 101 calculates and outputs an exclusive OR between adjacent bits for each of the bit strings constituting the input data 2a to 2d.
  • the detection result of the input data 5 is the edge detection result 2a
  • the detection result of the input data 6 is the edge detection result 2b
  • the detection result of the input data 7 is the edge detection result 2c
  • the detection of the input data 8 is detected.
  • the result is the edge detection result 2d.
  • Edge detection result 2a 0000100
  • Edge detection result 2b 0000101
  • Edge detection result 2c 0001110
  • Edge detection result 2d 0010110
  • the logical sum circuit 152 calculates the logical sum of the edge detection results 2a to 2d output from the four edge detection circuits 101 and the register value 2 output from the register 103, respectively.
  • the logical sum circuit 102 outputs the calculated logical sum as a logical sum value 2 to the register 103.
  • the value of the register value 2 which is the output of the register 103 in the cycle 2 is the logical sum value 1 held in the cycle 1.
  • the MSB side bit position detection circuit 104 Since cycle 3 is the cycle following the last operation cycle of the block, the MSB side bit position detection circuit 104 performs transition on the MSB side of the bit string constituting the logical sum value for the final logical sum value 2 as the block. Detect the bit position of the value. The MSB side bit position detection circuit 104 calculates the maximum exponent from the detected bit position. The MSB side bit position detection circuit 104 outputs the calculated maximum exponent. Specifically, since the bit position where the bit value of the logical sum value 2 is 1 is the second bit counted from the MSB side, the MSB side bit position detection circuit 104 outputs ⁇ 1 as the maximum exponent. .
  • cycle 3 is the cycle following the last operation cycle of the block
  • the register 103 resets the logical sum held for the block to 0, which is the initial value.
  • the register 103 outputs an initial value 0 in the next cycle.
  • the MSB side bit position detection circuit 104 and the register 103 identify the last operation cycle of each block as a cycle in which the value of the input block end signal becomes 1. In FIG. 8, since the value of the block end signal is 1 in cycle 2, it indicates that cycle 2 is the last operation cycle of the block.
  • the edge detection result of this input data is 1000000. Therefore, since the MSB of the final logical sum value as a block becomes the value 1, the maximum exponent of the block whose input data includes the negative maximum value is calculated as 0. That is, also in the third embodiment, the correct maximum exponent can be calculated even when the negative maximum value is included in the input data.
  • the third embodiment is characterized in that the maximum exponent is calculated using the edge detection circuit 101 in the block floating point normalization process. Since the edge detection circuit 101 only needs to calculate the exclusive OR between adjacent bits of the bit string constituting the input data, the edge detection circuit 101 is realized by a circuit having a simple configuration in which the number of logical stages including a plurality of XOR circuits is one. can do.
  • the maximum exponent calculation circuit calculates the maximum exponent at a higher speed than the normalization process that requires the absolute value circuit for calculating the absolute value of the input data.
  • the circuit scale and power consumption can be reduced.
  • the maximum exponent calculation circuit according to the third embodiment can correctly process even when the negative maximum value is included in the input data. Therefore, according to the maximum exponent calculation circuit according to the third embodiment, even when the data value is the negative maximum value, it is necessary to specially process the data, or to avoid using the negative maximum value. There is a feature that there is no need to do.
  • the maximum exponent calculation circuit according to the third embodiment includes the four edge detection circuits 101 and executes the edge detection processing in parallel, so that the maximum exponent can be calculated at high speed. .
  • FIG. 9 shows a configuration example of a maximum exponent calculation circuit 160 that includes N edge detection circuits 101 and executes edge detection processing in N parallel (where N is an integer of 2 or more).
  • N is an integer of 2 or more.
  • the N + 1 input OR circuit 162 included in the maximum exponent calculation circuit 160 calculates the logical sum of the N edge detection results output from the N edge detection circuits 101 and the register value 107 output from the register 103. calculate.
  • FIG. 10 is a block diagram showing a configuration of a block floating point normalization circuit (hereinafter referred to as a normalization circuit) according to the fourth embodiment of the present invention.
  • the normalization circuit according to the fourth embodiment performs normalization processing in block floating point for each input data constituting the block.
  • the normalization circuit outputs data obtained by normalizing input data as normalized data.
  • the normalization circuit according to the fourth embodiment receives four input data at the same time, and simultaneously outputs four normalized data obtained by normalizing the four input data inputted at the same time.
  • the normalization circuit according to the fourth embodiment includes four memories 120, a maximum exponent calculation circuit 150 according to the third embodiment, and four shift circuits 130.
  • the maximum exponent calculation circuit 150 calculates the maximum exponent for the input data “a” to “d”.
  • the maximum exponent calculation circuit 150 outputs the calculated maximum exponent as the maximum exponent 158 to the four shift circuits 130.
  • Each of the four memories 120 holds the input data a to d while the maximum exponent calculation circuit 150 calculates the maximum exponent of the input data. For example, four pieces of input data are sequentially input from an external device (not shown) to each of the four memories 120 and the maximum exponent calculation circuit 100. Each of the four memories 120 sequentially holds input data input from an external device. Each of the four memories 120 sequentially outputs the stored input data a to d as input data 121a to d to the shift circuit 130 after the maximum exponent calculation circuit 150 completes the calculation of the maximum exponent. To do.
  • Each of the four shift circuits 130 shifts each of the input data 121a to 121d output from the four memories 120 based on the maximum index 158 calculated by the maximum index calculation circuit 150 with respect to the input data. Perform normalization processing with.
  • FIG. 11 is a timing chart showing the operation of the normalization circuit according to the fourth exemplary embodiment of the present invention.
  • the normalization circuit according to the fourth exemplary embodiment of the present invention operates based on the input clock signal.
  • a block composed of the following eight data of input data 1 to input data 8 is considered as in the third embodiment.
  • Each input data is 8 bits.
  • each data value is shown in two's complement notation.
  • Input data 1 00001111 Input data 2: 00110001 Input data 3: 00000100 Input data 4: 11110011 Input data 5: 11111000 Input data 6: 00000100 Input data 7: 00001011 Input data 8: 00011011
  • FIG. 11 shows operations in cycle 1 ′ to cycle 2 ′ after the maximum exponent calculation circuit 150 calculates the maximum exponent of input data in cycles 1 to 2 shown in FIG.
  • cycle 1 since the operation of cycle 1 is the same as that shown in FIG. 8, illustration thereof is omitted.
  • Cycle 3 and cycle 1 ′ indicate the same operation cycle.
  • Each of the four memories 120 holds the input data while calculating the maximum exponent of the input data input by the maximum exponent calculation circuit 150 in cycles 1 and 2. Next, each of the four memories 120 sequentially outputs the held input data to the shift circuit 130 in cycles 1 ′ to 2 ′ after the maximum exponent calculation circuit 150 completes the calculation of the maximum exponent.
  • the memory 120 identifies the timing at which the maximum exponent calculation circuit 150 completes the calculation of the maximum exponent with reference to the block end signal.
  • the maximum exponent calculation circuit 150 calculates the maximum exponent of input data that is input four times per cycle in cycles 1 and 2. Next, the maximum exponent calculation circuit 150 outputs ⁇ 1 as the calculated maximum exponent to the shift circuit 130 in cycle 3. The maximum exponent calculation circuit 150 continues the output of ⁇ 1 which is the maximum exponent until cycle 2 ′ where the output of the input data held in the memory 120 is completed.
  • the four shift circuits 130 in cycles 1 ′ to 3 ′, input data 1 to 8 output from the memory 120 into one cycle based on ⁇ 1, which is the maximum exponent calculated and output by the maximum exponent calculation circuit 150. Normalization processing is performed by sequentially shifting four by four.
  • the shift circuit 130 outputs data obtained by normalizing the input data 1 to 8 as normalized data 1 to 8.
  • the normalized data 1 to 8 output from the shift circuit 130 have the following values, and the normalization process is completed correctly.
  • Data after normalization of the input data k is indicated as normalized data k (k is a positive integer from 1 to 8).
  • Normalized data 1 00101110 Normalized data 2: 01100010 Normalized data 3: 00001100 Normalized data 4: 11100110 Normalized data 5: 11110000 Normalized data 6: 00001100 Normalized data 7: 00010110 Normalized data 8: 00110110
  • the normalization circuit 150 according to the third embodiment since the maximum exponent calculation circuit 150 according to the third embodiment is used to calculate the maximum exponent with a large calculation processing amount in the block floating point normalization processing, it is necessary for the calculation processing of the maximum exponent. The circuit scale and power consumption can be reduced. Furthermore, the normalization circuit according to the fourth embodiment includes a maximum exponent calculation circuit 150 that can calculate the maximum exponent at high speed and can reduce the circuit scale and power consumption. Then, the normalization circuit performs block floating point normalization processing based on the maximum exponent calculated by the maximum exponent calculation circuit 150. As a result, according to the fourth embodiment, block floating point normalization processing can be executed at high speed, and the circuit scale and power consumption can be reduced.
  • the block floating point normalization circuit according to the fourth embodiment includes four memories 120 and four shift circuits 130, and includes a maximum exponent calculation circuit 150 that calculates a maximum exponent in four parallel, the block The floating point maximum exponent calculation process and the normalization process can be executed in parallel. As a result, the block floating point normalization process can be executed at high speed.
  • the edge detection circuit sets a value (transition value) indicating that the values of adjacent bits are different from each other in the bit string constituting the input data to 1 so that the values of the adjacent bits are not different.
  • a value indicating that the values of adjacent bits are different from each other is set to 0 and a value indicating that the values of adjacent bits are not different from each other is set to 1. That is, the edge detection circuit may have an XNOR circuit instead of an XOR circuit, for example.
  • a logical product circuit that calculates the logical product of the data output from the edge detection circuit is provided. Then, the MSB side bit position detection circuit calculates the maximum exponent based on the bit position where the bit value of the logical product value output from the logical product circuit is 0.
  • the bit string generated by the edge detection circuit and the OR circuit is arranged by arranging the XOR result of the nth bit and n + 1th bit from the MSB of the bit string constituting the input data as the nth bit from the MSB.
  • n is an integer of 0 or more.
  • the edge detection circuit and the OR circuit calculate the XOR result of the nth bit and the (n + 1) th bit from the MSB of the bit string constituting the input data from the MSB (7 ⁇ n ) You may make it arrange as a bit.
  • the edge detection circuit and the logical sum circuit may arrange the XOR result of the n-th bit and the (n + 1) -th bit from the MSB of the bit string constituting the input data as the n-th bit from the LSB.
  • the edge detection circuit and the logical sum circuit may arrange the XOR result of the n-th bit and the (n + 1) -th bit from the MSB of the bit string constituting the input data as the n-th bit from the LSB.
  • the edge detection circuit and the logical sum circuit may arrange the XOR result of the n-th bit and the (n + 1) -th bit from the MSB of the bit string constituting the input data as the n-th bit from the LSB.
  • the logical sum of the bit strings generated by the edge detection circuit is calculated, and the maximum exponent is calculated based on the calculated logical sum.
  • the bit string generated by the edge detection circuit may be output directly to the MSB side bit position detection circuit without providing the OR circuit and the register.
  • the MSB side bit position detection circuit calculates an index for each bit string sequentially output from the edge detection circuit. Then, the MSB side bit position detection circuit may set the index having the largest value among all the data in the block as the maximum index.
  • the absolute value of each input data in the block is calculated sequentially, the index is calculated for each of the calculated absolute values, and the index with the largest value among all the data in the block is set as the maximum index. It is possible to calculate the maximum exponent at a higher speed than in the case of doing so.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Physics & Mathematics (AREA)
  • Mathematical Analysis (AREA)
  • Computing Systems (AREA)
  • Computational Mathematics (AREA)
  • Mathematical Optimization (AREA)
  • Pure & Applied Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Manipulation Of Pulses (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)
  • Design And Manufacture Of Integrated Circuits (AREA)

Abstract

 複数のデータを共通の指数によって正規化する場合に、指数の算出の高速化を図ることができ、かつ、そのための回路規模及び消費電力の低減を図ることができる半導体集積回路及び指数算出方法を提供する。本発明にかかる半導体集積回路50は、複数のデータを共通の指数によって正規化する場合に、複数のデータの指数を算出する半導体集積回路50である。データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なることを示す遷移値、又は、互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成するビット列生成回路51と、複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の遷移値のビットの位置に基づいて、複数のデータの指数を算出する指数算出回路52と、を備える。

Description

半導体集積回路及び指数算出方法
 本発明は、半導体集積回路及び指数算出方法に関し、特にディジタル信号処理における演算処理技術に関する。
 ディジタル信号処理において、浮動小数点による演算は、扱う信号データの値の範囲が広い場合でも高い精度で演算できるという利点があるが、複雑な回路が必要になるため、回路規模や消費電力が大きいという問題がある。また、固定小数点による演算は、回路が単純で、回路規模や消費電力が小さいという利点があるが、演算精度が低いという問題がある。
 一方、浮動小数点と固定小数点の双方の利点を兼ね備えた演算方法として、ブロック浮動小数点による演算がある。ブロック浮動小数点による演算では、複数の信号データを1つのブロックとしてまとめ、各ブロック単位で共通の指数をもつように、ブロック全体で正規化する。
 より詳細には、ブロック浮動小数点処理において、次のステップでブロック浮動小数点の正規化処理を行う。
(1)ブロック内の全データの最大指数を求める。
(2)求めた最大指数によりブロック全体をシフト(正規化)する。
 ここで最大指数とは、ブロック内の全てのデータが桁あふれを起こさない最大の指数を示す。最大指数はブロック内の全データのうち、絶対値が最大のデータの指数値に等しい。
 この最大指数を効率よく求める方法として、次の方法が知られている(例えば、特許文献1)。
(1)ブロック内の各データの絶対値を算出する。
(2)算出した各データの絶対値の論理和を算出する。
(3)算出した論理和のMSB(Most Significant Bit)側のビット位置を検出し、最大指数を求める。
 以下に、上述した最大指数の算出方法を用いたブロック浮動小数点の正規化処理の具体例を説明する。
 まず、正規化対象のブロックとして、次に示す8ビットの入力データである入力データ1~入力データ8の8つのデータからなるブロックを考える。下記では各データの値を2の補数表現で示している。なお、以降に示すデータのビット列は、最も左のビットがMSBであり、最も右のビットがLSBであるものとして示す。なお、MSBは、符号ビットとなる。
入力データ1: 00010111
入力データ2: 00110001
入力データ3: 00000110
入力データ4: 11110011
入力データ5: 11111000
入力データ6: 00000110
入力データ7: 00001011
入力データ8: 00011011
 次に、ブロック内の各データ(入力データ1~8)の絶対値を算出する。以下に、入力データ1~8の絶対値を、絶対値1~8として示す。具体的には、入力データkの絶対値は、絶対値kとして示している(kは、1~8のいずれかの正の整数)。
絶対値1: 00010111
絶対値2: 00110001
絶対値3: 00000110
絶対値4: 00001101
絶対値5: 00001000
絶対値6: 00000110
絶対値7: 00001011
絶対値8: 00011011
 次に、算出した各絶対値の論理和を算出する。以下に、絶対値1~8の論理和を示す。
論理和 : 00111111
 次に、算出した論理和のMSB(Most Significant Bit)側から見て最初にビットの値が1となるビット位置として、5ビット目を検出する。ここで、MSBを7ビット目、LSB(Least Significant Bit)を0ビット目とする。入力データ1~8を共通の指数で正規化するために、入力データ1~8を同一のシフト量で左にビットシフトする場合、シフト量が1ビットであれば、入力データ1~8の符号はいずれも変化せずに正規化後の値が正しく表現されることになる。したがって、最大指数は-1になる。
 最後に、求めた最大指数に基づいて、グループ内の全データ(入力データ1~8)を正規化して、正規化後のデータ(正規化データ1~8)を求める。具体的には、最大指数が-1の場合、左に1ビットシフトする。以下に、入力データ1~8の正規化後のデータを、正規化データ1~8として示す。入力データkの正規化後のデータは、正規化データkとして示している(kは、1~8のいずれかの正整数)。ここで、最大指数が-1であるため、正規化データ1~8の実際の値は、それぞれのデータに2の-1乗を乗じた値となる。
正規化データ1: 00101110
正規化データ2: 01100010
正規化データ3: 00001100
正規化データ4: 11100110
正規化データ5: 11110000
正規化データ6: 00001100
正規化データ7: 00010110
正規化データ8: 00110110
 上述したような正規化処理は、最大指数を算出するステップにおいて、ブロック内の各データの絶対値を算出する必要がある。ここで、絶対値を算出において、負のデータを正のデータに変換するためには、ビットの反転、1の加算、及び、1を加算した場合における桁上がり等の処理を実行する必要がある。そのため、絶対値を算出するための処理は、時間がかかってしまうという問題がある。また、それらの処理を実行するための回路が必要となるため、回路規模及び消費電力が大きくなってしまうという問題もある。
 さらに、ブロック浮動小数点処理では、ブロックを構成するデータの数だけ複数回繰り返して絶対値を算出する必要がある。そのため、上述したような正規化処理では、時間がかかる絶対値の算出を繰り返すための処理時間が飛躍的に増大してしまうことになる。
 以上に説明したように、上述したような正規化処理では、最大指数の算出を高速に行えず、また回路規模及び消費電力が大きいという問題がある。
 さらに、上述したような正規化処理では、負側の最大値のデータを特別に処理するか、あるいは負側の最大値を使用しないようにする必要がある、という問題がある。なぜなら、Xビットのデータの場合、そのデータの負側の最大値は-1x(2のX-1乗)であるが、その絶対値である+1x(2のX-1乗)はXビットでは表現できないからである(Xは、正の整数)。なお、xは、乗算記号を示す。
 具体的には、例えば、8ビットのデータの場合、そのデータの負側の最大値は-1x(2の7乗)=-128であるが、その絶対値である+1x(2の7乗)=+128は8ビットでは表現することができず、9ビット必要である。したがって、データの値が-128の場合は、その絶対値+128を+127に飽和させるなど、-128を特別に処理するか、あるいは-128を使用しないようにする必要がある、という問題がある。
 なお、特許文献2には、入力データにおいてビットが1となる位置を示すデータの1ビット当たりの値を決めるためのデータを抽出するマスクデータを用いて順に各々のビットの値を求める1位置検出方法が開示されている。特許文献2には、この1位置検出方法によれば、ビットが1となる位置のデータの1ビット当たりの値を決めるために、1回のマスク処理と1回の比較を行うだけでよいので、ビットが1となる位置を検出するための処理時間が短くすることができると記載されている。
 また、特許文献3には、入力データの先頭ビットと論理状態の異なるビットが最初に現れるビット位置を検出し、入力データの小数点の位置から検出したビット位置までの距離を表す情報に基づいて、入力データをシフトする正規化データ生成回路が開示されている。特許文献3には、この正規化データ生成回路によれば、シフト操作のほとんどをハード的に行うことができるため、正規化データの生成時間を短縮することができると記載されている。
 しかし、特許文献2及び3は、本願発明のように、正規化対象のデータを構成するビット列から、互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なるか否かを示すビットを含むビット列を生成する技術を開示したものではない。
特開平9-128213号公報 特開平6-75746号公報 特開平8-212052号公報
 背景技術として説明したように、複数のデータを共通の指数によって正規化する場合に、指数の算出を高速に行うことができず、かつ、回路規模及び消費電力が大きくなってしまっているという問題がある。
 本発明はこのような課題を解決するためのものであり、複数のデータを共通の指数によって正規化する場合に、指数の算出の高速化を図ることができ、かつ、そのための回路規模及び消費電力の低減を図ることができる半導体集積回路及び指数算出方法を提供することを目的としている。
 本発明の第1の態様にかかる半導体集積回路は、複数のデータを共通の指数によって正規化する場合に、当該複数のデータの指数を算出する半導体集積回路であって、前記データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、当該互いに隣接するビットの値が異なることを示す遷移値、又は、当該互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成するビット列生成回路と、前記ビット列生成回路によって前記複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の前記遷移値のビットの位置に基づいて、前記複数のデータの指数を算出する指数算出回路と、を備えたことを特徴とするものである。
 本発明の第2の態様にかかる指数算出方法は、複数のデータを共通の指数によって正規化する場合に、当該複数のデータの指数を算出する指数算出方法であって、前記データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、当該互いに隣接するビットの値が異なることを示す遷移値、又は、当該互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成し、前記複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の前記遷移値のビットの位置に基づいて、前記複数のデータの指数を算出する、を備えたことを特徴とするものである。
 上述した本発明の各態様によれば、複数のデータを共通の指数によって正規化する場合に、指数の算出の高速化を図ることができ、かつ、そのための回路規模及び消費電力の低減を図ることができる半導体集積回路及び指数算出方法を提供することができる。
本発明の実施の形態1にかかる半導体集積回路の構成を示すブロック図である。 本発明の実施の形態1にかかる最大指数算出回路の構成を示すブロック図である。 本発明の実施の形態1にかかるエッジ検出回路の構成を示すブロック図である。 本発明の実施の形態1にかかる最大指数算出回路の動作を示すタイミング図である。 本発明の実施の形態2にかかる正規化回路の構成を示すブロック図である。 本発明の実施の形態2にかかる正規化回路の動作を示すタイミング図である。 本発明の実施の形態3にかかる最大指数算出回路の構成を示すブロック図である。 本発明の実施の形態3にかかる最大指数算出回路の動作を示すタイミング図である。 本発明の実施の形態3にかかる最大指数算出回路の他の構成例を示すブロック図である。 本発明の実施の形態4にかかる正規化回路の構成を示すブロック図である。 本発明の実施の形態4にかかる正規化回路の動作を示すタイミング図である。 本発明の実施の形態4にかかる正規化回路の他の構成例を示すブロック図である。
 次に、本発明の実施の形態について図面を参照して説明する。
[第1の実施の形態]
 まず、図1を参照して、本発明の実施の形態1にかかる最大指数算出回路の概要となる半導体集積回路50について説明する。図1は、本発明の実施の形態1にかかる半導体集積回路の構成を示すブロック図である。
 半導体集積回路50は、ビット列生成回路51及び指数算出回路52を有する。半導体集積回路50は、複数のデータを共通の指数によって正規化する場合に、複数のデータの指数を算出する。
 ビット列生成回路51は、データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なることを示す遷移値、又は、互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成する。
 指数算出回路52は、ビット列生成回路51によって複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の遷移値のビットの位置に基づいて、複数のデータの指数を算出する。
 ビット列生成回路51は、共通の指数によって正規化する複数のデータが入力される。ビット列生成回路51は、データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なることを示す遷移値、又は、互いに隣接するビットの値が異ならないことを示す非遷移値としたビットを含む第2のビット列を生成する。ビット列生成回路51は、複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列を指数算出回路52に出力する。
 指数算出回路52は、ビット列生成回路51から出力された複数の第2のビット列の遷移値のビットの位置に基づいて、複数のデータの指数を算出する。指数算出回路52は、算出した指数を出力する。
 以上に説明したように、本実施の形態1にかかる半導体集積回路50は、正規化対象のデータを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なるか否かを示すビットを含む第2のビット列を生成している。この第2のビット列によれば、第1のビット列の互いに隣接するビットの組のそれぞれについて、互いに隣接するビットの値が異なるか否かが分かる。そのため、データの符号がいずれも変化せずに正規化後の値が正しく表現されるシフト量を特定することができる。つまり、最大指数を算出することができる。
 そして、本実施の形態1にかかる半導体集積回路50によれば、単純に互いに隣接するビットの値が異なるか否かを論理演算するだけであるため、指数の算出の高速化を図ることができ、かつ、そのための回路規模及び消費電力の低減を図ることができる。
 以下、図面を参照して本発明の実施の形態1について詳細に説明する。
 図2は、本発明の第1の実施の形態にかかる最大指数算出回路100の構成を示すブロック図である。最大指数算出回路100は、複数の入力データからなるブロックに関して、ブロック内の全データの最大指数を算出する回路である。
 具体的には、最大指数算出回路100は、入力されるクロック信号に基づいて、ブロック内の全データを順次入力して、ブロック内の全データの最大指数を算出する。最大指数算出回路100は、ブロックごとに算出した最大指数を出力する。このとき、最大指数算出回路100は、入力されたブロックエンド信号を参照して、ブロックの終端を識別する。入力データは、例えば、外部回路(図示せず)から最大指数算出回路100に入力される。そして、外部回路は、ブロックにおける最後の入力データを最大指数算出回路100に出力するサイクルで、アサートしたブロックエンド信号を最大指数算出回路100に出力する。
 最大指数算出回路100は、主な回路として、エッジ検出回路101、論理和回路102、レジスタ103、MSB側ビット位置検出回路104、を含んでいる。
 エッジ検出回路101は、入力された入力データを構成するビット列の値の遷移(エッジ)を検出する回路である。エッジ検出回路101は、入力された入力データを構成するビット列の値の遷移(エッジ)を検出する。エッジ検出回路101は、検出結果をエッジ検出結果105として論理和回路102に出力する。
 具体的には、エッジ検出回路101は、入力データを構成するビット列のMSBからnビット目とn+1ビット目との値が異なるか否かを示す値を算出する(nは、0以上の整数)。エッジ検出回路101は、算出した値をMSBからnビット目に配列する。エッジ検出回路101は、このように算出した値を配列したビット列を検出結果として生成する。なお、MSBから0ビット目と言った場合は、MSBであるものとする。本実施の形態1では、ビットの値が異なるか否かを示す値が、ビットの値が異なる場合は1(遷移値)となり、ビットの値が異ならない場合は0(非遷移値)となる場合について例示する。言い換えると、本実施の形態1では、ビットの値が異なるか否かを示す値が、ビットの値が等しい場合は0となる場合について例示する。エッジ検出回路101は、ビット列生成回路51として機能する。
 論理和回路102は、前記エッジ検出回路101が出力するエッジ検出結果105と、レジスタ103が出力するレジスタ値107の論理和を算出する。論理和回路102は、算出した論理和を論理和値106としてレジスタ103に出力する。
 レジスタ103は、論理和回路102が出力する論理和値106を、入力されたクロック信号に基づいた動作サイクルごとに保持する回路である。レジスタ103は、保持した論理和値を動作サイクルごとにレジスタ値107として、論理和回路102およびMSB側ビット位置検出回路104に出力する。また、レジスタ103は、ブロックエンド信号を参照して、ブロックの最後の入力データに基づいた最終的な論理和値106が論理和回路102から入力される最後の動作サイクルを認識する。レジスタ103は、各ブロックの最後の動作サイクルの次のサイクルにおいて、ブロックごとに保持している論理和値を初期値である0にリセットする。レジスタ103は、最終的な論理和値106をMSB側ビット位置検出回路104に出力してから、保持している論理和値をリセットする。
 MSB側ビット位置検出回路104は、レジスタ103が出力するレジスタ値107について、レジスタ値107を構成するビット列のMSB側の遷移値のビット位置を検出する。MSB側ビット位置検出回路104は、検出したビット位置から最大指数を算出して出力する回路である。具体的には、MSB側ビット位置検出回路104は、レジスタ103が出力するレジスタ値107のビットの値が1である位置が、MSB側から数えてMビット目である場合(Mは0以上の整数)、最大指数として-1xMを出力する。
 例えば、レジスタ値107のビットの値が1である位置が、MSB側から数えて1ビット目である場合、入力データの全てで、MSB側から0ビット目と1ビット目の値が同じことになる。逆に、この場合は、入力データのいずれかが、MSB側から1ビット目と2ビット目の値が異なることになる。したがって、上述した計算式(-1xM)によれば、入力データの符号がいずれも変化せずに正規化後の値が正しく表現されるシフト量に対応する最大指数として、-1x1=-1を算出することができる。
 ここで、レジスタ103は動作サイクルごとにレジスタ値107を出力するが、MSB側ビット位置検出回路104は、ブロックとしての最終的な論理和値を示すレジスタ値107に基づいて、最大指数を算出する。MSB側ビット位置検出回路104は、ブロックエンド信号を参照して、ブロックとしての最終的な論理和値を示すレジスタ値107がレジスタ103から出力されるサイクルを認識する。MSB側ビット位置検出回路104は、最終的な論理和値を示すレジスタ値107を構成するビット列のMSB側のビット位置を検出する。MSB側ビット位置検出回路104は、検出したビット位置から最大指数を算出する。MSB側ビット位置検出回路104は、算出した最大指数を出力する。
 論理和回路102、レジスタ103及びMSB側ビット位置検出回路104は、指数算出回路52として機能する。
 つぎに、図3を参照して、エッジ検出回路101の構成を説明する。エッジ検出回路101は、複数の排他的論理和(XOR)回路110を有する。エッジ検出回路101は、入力データを構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出して出力する。すなわち、入力データがYビットのビット列から構成される場合、エッジ検出回路101は、Y-1個のXOR回路110から構成される(Yは、正の整数)。
 図3は、入力データがb7~b0の8ビットのビット列から構成される場合の、エッジ検出回路101の構成例を示している。エッジ検出回路101は、入力データを構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出する。エッジ検出回路101は、算出した排他的論理和をエッジ検出結果e7~e1として論理和回路102に出力する。ここで、入力データのビットb7およびエッジ検出結果のビットe7がMSBである。
[第1の実施の形態の動作]
 次に、図4を参照して、本発明の実施の形態1にかかる最大指数算出回路の動作について説明する。図4は、本発明の実施の形態1にかかる最大指数算出回路100の動作を示すタイミング図である。最大指数算出回路100は、入力されたクロック信号に基づいて動作を行う。
 正規化対象のブロックの例として、次に示す入力データ1~入力データ8の8つのデータからなるブロックを考える。各入力データは、8ビットである。下記では各データの値を2の補数表現で示している。なお、以降に示すデータのビット列は、最も左のビットがMSBであり、最も右のビットがLSBであるものとして示す。なお、MSBは、符号ビットとなる。
入力データ1: 00010111
入力データ2: 00110001
入力データ3: 00000110
入力データ4: 11110011
入力データ5: 11111000
入力データ6: 00000110
入力データ7: 00001011
入力データ8: 00011011
(サイクル1)
 まず、動作サイクルの1サイクル目(サイクル1)で、最大指数算出回路100は、入力データ1が入力される。エッジ検出回路101は、入力データ1を構成するビット列の値の遷移(エッジ)を検出する。エッジ検出回路101は、検出した結果をエッジ検出結果1として論理和回路102に出力する。より詳細には、エッジ検出回路101は、入力データ1を構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出して出力する。
エッジ検出結果1: 0011100
 つぎに、論理和回路102は、エッジ検出回路101が出力するエッジ検出結果1と、レジスタ103が出力するレジスタ値1との論理和を算出する。論理和回路102は、算出した論理和を論理和値1としてレジスタ103に出力する。ここで、サイクル1におけるレジスタ値1の値は初期値の0である。
論理和値1: 0011100
 レジスタ103は、サイクル1において論理和回路102が出力する論理和値1を保持する。レジスタ103は、つぎの動作サイクルであるサイクル2において、保持した論理和値1をレジスタ値2として出力する。
(サイクル2)
 つぎに、動作サイクルの2サイクル目(サイクル2)では、最大指数算出回路100は、入力データ2が入力される。エッジ検出回路101は、入力データ2を構成するビット列の値の遷移(エッジ)を検出する。エッジ検出回路101は、検出した結果をエッジ検出結果2として論理和回路102に出力する。より詳細には、エッジ検出回路101は、入力データ2の入力データを構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出して出力する。
エッジ検出結果2: 0101001
 つぎに、論理和回路102は、エッジ検出回路101が出力するエッジ検出結果2と、レジスタ103が出力するレジスタ値2との論理和を算出する。論理和回路102は、算出した論理和を論理和値2としてレジスタ103に出力する。ここで、サイクル2におけるレジスタ103の出力であるレジスタ値2の値は、サイクル1で保持した論理和値1である。
論理和値2: 0111101
 レジスタ103は、サイクル2において論理和回路102が出力する論理和値2を保持する。レジスタ103は、つぎの動作サイクルであるサイクル3において、保持した論理和値2をレジスタ値3として出力する。
(サイクル3~8)
 サイクル3~8においても同様にして、最大指数算出回路100は、入力データ3~8を各動作サイクルにおいて入力する。エッジ検出回路101は、入力データ3~8を構成するビット列の値の遷移(エッジ)をそれぞれ検出する。エッジ検出回路101は、検出した結果のそれぞれをエッジ検出結果3~8として出力する。
エッジ検出結果3: 0000101
エッジ検出結果4: 0001010
エッジ検出結果5: 0000100
エッジ検出結果6: 0000101
エッジ検出結果7: 0001110
エッジ検出結果8: 0010110
 論理和回路102は、各サイクルにおいて、エッジ検出回路101が出力するエッジ検出結果3~8のそれぞれと、レジスタ103が出力するレジスタ値のそれぞれとの論理和を算出する。論理和回路102は、算出した論理和のそれぞれを論理和値3~8としてレジスタ103に出力する。ここで、サイクル3~8のそれぞれにおけるレジスタ103の出力であるレジスタ値3~8の値はそれぞれ、サイクル2~7で保持した論理和値2~7である。
論理和値3: 0111101
論理和値4: 0111111
論理和値5: 0111111
論理和値6: 0111111
論理和値7: 0111111
論理和値8: 0111111
 ブロックの最後の動作サイクルの次のサイクルであるサイクル9では、MSB側ビット位置検出回路104は、ブロックとしての最終的な論理和値8について、論理和値8を構成するビット列のMSB側の遷移値のビット位置を検出する。MSB側ビット位置検出回路104は、検出したビット位置から最大指数を算出する。MSB側ビット位置検出回路104は、算出した最大指数を出力する。具体的には、論理和値8のビットの値が1となるビット位置は、MSB側から数えて1ビット目であるので、上述した計算式(-1xM)によれば最大指数は、-1x1=-1となる。したがって、MSB側ビット位置検出回路104は、最大指数として-1を出力する。
 また、ブロックの最後の動作サイクルの次のサイクルであるサイクル9では、レジスタ103は、ブロックに対して保持している論理和値を初期値である0にリセットする。その結果、レジスタ103は、次のサイクルで初期値0を出力する。
 ここで、MSB側ビット位置検出回路104及びレジスタ103は、各ブロックの最後の動作サイクルを、入力されたブロックエンド信号の値が1になるサイクルとして識別する。図4においては、サイクル8でブロックエンド信号の値が1となっているため、サイクル8がブロックの最後の動作サイクルであることを示している。
 つぎに、入力データに負側の最大値が含まれる場合について説明する。8ビットの入力データの場合、そのデータの負側の最大値は-1x(2の7乗)=-128であり、2の補数表現では、10000000である。この入力データのエッジ検出結果は1000000になる。したがって、ブロックとしての最終的な論理和値のMSBは値1になるので、入力データに負側の最大値が含まれるブロックの最大指数は0と算出される。すなわち、本実施の形態1によれば、入力データに負側の最大値が含まれる場合であっても、正しい最大指数を算出することができる。
[第1の実施の形態の効果]
 本実施の形態1では、ブロック浮動小数点の正規化処理において、エッジ検出回路101を使用して最大指数を算出する、ことを特徴としている。エッジ検出回路101は、入力データを構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出するだけでよいので、複数のXOR回路からなる論理段数が1段の単純な構成の回路で実現することができる。
 したがって、背景技術として説明したように入力データの絶対値を算出する正規化処理と比較して、本実施の形態1による最大指数算出回路は、最大指数を高速に算出することが可能であり、かつ回路規模や消費電力を小さくすることができる。
 さらに、本実施の形態1による最大指数算出回路は、入力データに負側の最大値が含まれる場合であっても正しく処理することが可能である。したがって、本実施の形態1にかかる最大指数算出回路によれば、データの値が負側の最大値の場合でも、そのデータを特別に処理する必要や、負側の最大値を使用しないようにする必要がない、という特徴がある。
[第2の実施の形態]
 次に、図5を参照して、本発明の実施の形態2にかかるブロック浮動小数点正規化回路について説明する。本発明の実施の形態2では、実施の形態1にかかる最大指数算出回路を使用したブロック浮動小数点正規化回路の具体例について説明する。
 図5は、本発明の実施の形態2にかかるブロック浮動小数点正規化回路(以下では正規化回路と表記する)の構成を示すブロック図である。
 図5において、本実施の形態2による正規化回路は、ブロックを構成する各入力データに対してブロック浮動小数点における正規化処理を行う。正規化回路は、入力データを正規化したデータを正規化データとして出力する。
 図5において、本実施の形態2による正規化回路は、メモリ120と、実施の形態1による最大指数算出回路100と、シフト回路130とを有する。
 実施の形態1による最大指数算出回路100は、入力された入力データに対して、最大指数を算出する。最大指数算出回路100は、算出した最大指数を最大指数108としてシフト回路130に出力する。
 メモリ120は、最大指数算出回路100が入力された入力データの最大指数を算出している間、入力データを保持する。入力データは、例えば、外部装置(図示せず)からメモリ120と最大指数算出回路100のそれぞれに順次入力される。メモリ120は、外部装置から入力される入力データを順次保持していく。また、メモリ120は、最大指数算出回路100が最大指数の算出を完了した後、保持していた入力データを、入力データ121として順次シフト回路130に出力する。
 シフト回路130は、最大指数算出回路100が算出した最大指数108に基づいて、メモリ120が出力する入力データをシフトすることで正規化処理を行う。
[第2の実施の形態の動作]
 次に、図6を参照して、本発明の実施の形態2にかかる正規化回路の動作について説明する。図6は、本発明の実施の形態2にかかる正規化回路の動作を示すタイミング図である。本発明の実施の形態2にかかる正規化回路は、入力されたクロック信号に基づいて動作を行う。
 正規化対象のブロックの例として、実施の形態1と同様に、次に示す入力データ1~入力データ8の8つのデータからなるブロックを考える。各入力データは、8ビットである。下記では各データの値を2の補数表現で示している。
入力データ1: 00010111
入力データ2: 00110001
入力データ3: 00000110
入力データ4: 11110011
入力データ5: 11111000
入力データ6: 00000110
入力データ7: 00001011
入力データ8: 00011011
 図6は、図4に示すサイクル1~サイクル8において、最大指数算出回路100が、入力された入力データの最大指数を算出した後の、サイクル1'~サイクル8'における動作を示している。ここで、サイクル1~7の動作は、図4で示したものと同様であるとして、図示を省略している。また、サイクル9とサイクル1'は同一の動作サイクルを示している。
 メモリ120は、サイクル1~8において、最大指数算出回路100が入力された入力データの最大指数を算出している間、入力データを保持している。つぎに、メモリ120は、最大指数算出回路100が最大指数の算出を完了した後、サイクル1'~8'において、保持していた入力データを順次シフト回路130に出力する。ここで、メモリ120は、ブロックエンド信号を参照して、最大指数算出回路100が最大指数の算出を完了するタイミングを識別する。具体的には、メモリ120は、ブロックエンド信号の値が1となったサイクル8の次のサイクル9から保持していた入力データ1~8の出力を開始する。
 また、メモリ120は、ブロックエンド信号を参照して、入力データの出力を終了するタイミングを識別する。具体的には、メモリ120は、ブロックエンド信号の値が再度1となったサイクル8'で入力データの出力を終了する。例えば、外部装置は、入力データの出力を完了したサイクル8から、入力データ1~8のデータ数分のサイクルが経過したサイクル8'で値を1としたブロックエンド信号を出力するようにする。
 最大指数算出回路100は、サイクル1~8において、入力された入力データの最大指数を算出する。つぎに、最大指数算出回路100は、サイクル9において、算出した最大指数として-1をシフト回路130に出力する。最大指数算出回路100は、メモリ120が保持していた入力データの出力を完了するサイクル8'まで、最大指数である-1の出力を継続する。
 ここで、最大指数算出回路100は、ブロックエンド信号を参照して、最大指数の出力を終了するタイミングを識別する。具体的には、最大指数算出回路100は、ブロックエンド信号の値が再度1となったサイクル8'で最大指数の出力を終了する。
 シフト回路130は、サイクル1'~8'において、最大指数算出回路100が算出して出力する最大指数である-1に基づいて、メモリ120が出力する入力データ1~8を順次シフトすることで正規化処理を行う。そして、シフト回路130は、入力データ1~8を正規化したデータを正規化データ1~8として出力する。ここで、シフト回路130は、最大指数算出回路100から出力された最大指数が-mである場合、入力データ1~8を左にmビットシフトすることによって、入力データ1~8の正規化を行う(mは、0以上の整数)。
 その結果、シフト回路130が出力する正規化データ1~8は以下に示す値になり、正しく正規化処理が完了する。入力データkの正規化後のデータは、正規化データkとして示している(kは、1~8のいずれかの正整数)。
正規化データ1: 00101110
正規化データ2: 01100010
正規化データ3: 00001100
正規化データ4: 11100110
正規化データ5: 11110000
正規化データ6: 00001100
正規化データ7: 00010110
正規化データ8: 00110110
[第2の実施の形態の効果]
 本実施の形態2では、ブロック浮動小数点の正規化処理において、演算処理量の大きい最大指数の算出に、実施の形態1による最大指数算出回路100を使用するので、最大指数の算出処理に必要な回路規模や消費電力を小さくすることができる。さらに、本実施の形態2にかかる正規化回路は、最大指数を高速に算出することが可能であり、かつ回路規模や消費電力を小さくすることができる最大指数算出回路100を有する。そして、正規化回路は、最大指数算出回路100が算出した最大指数に基づいて、ブロック浮動小数点の正規化処理を実行している。その結果、本実施の形態2によれば、ブロック浮動小数点の正規化処理を高速に実行することが可能であり、かつ、回路規模や消費電力を小さくすることができる。
[第3の実施の形態]
 つぎに、図面を参照して本発明の実施の形態3について説明する。
 図7は、本発明の第3の実施の形態にかかる最大指数算出回路150の構成を示すブロック図である。最大指数算出回路150は、複数の入力データからなるブロックに関して、ブロック内の全データの最大指数を算出する回路である。最大指数算出回路150は、エッジ検出を並列に実行することで、最大指数を高速に算出することを特徴とする。図7において、本発明の第1の実施形態による最大指数算出回路100と同一の構成要素には同一の符号を付してある。
 具体的には、最大指数算出回路150は、入力されるクロック信号に基づいて、ブロック内の全データを4つ同時に順次入力して、ブロック内の全データの最大指数を算出する。最大指数算出回路150は、ブロックごとに算出した最大指数を出力する。このとき、最大指数算出回路150は、入力するブロックエンド信号を参照して、ブロックの終端を識別する。
 最大指数算出回路150は、主な回路として、4つのエッジ検出回路101、論理和回路152、レジスタ103、MSB側ビット位置検出回路104、を含んでいる。
 エッジ検出回路101は、入力された入力データを構成するビット列の値の遷移(エッジ)を検出する回路である。4つのエッジ検出回路101は、入力データa~dがそれぞれ入力される。4つのエッジ検出回路101は、それぞれの入力データを構成するビット列の値の遷移(エッジ)を検出する。4つのエッジ検出回路101は、検出した結果をエッジ検出結果155a~155dとして論理和回路152にそれぞれ出力する。
 論理和回路152は、5入力の回路であり、4つのエッジ検出回路101が出力するエッジ検出結果155a~155dと、レジスタ103が出力するレジスタ値107が入力される。論理和回路152は、入力されたエッジ検出結果155a~155d及びレジスタ値107の論理和を算出する。論理和回路152は、算出した論理和を論理和値156としてレジスタ103に出力する。
 レジスタ103は、論理和回路152が出力する論理和値156を、入力されたクロック信号に基づいた動作サイクルごとに保持する回路である。レジスタ103は、保持した論理和値を動作サイクルごとにレジスタ値107として、論理和回路152およびMSB側ビット位置検出回路104に出力する。また、レジスタ103は、ブロックエンド信号を参照して、最後の動作サイクルを認識する。レジスタ103は、ブロックの最後の動作サイクルにおいて、ブロックに対して保持している論理和値を初期値である0にリセットする。
 MSB側ビット位置検出回路104は、レジスタ103が出力するレジスタ値107について、レジスタ値107を構成するビット列のMSB側の遷移値のビット位置を検出する。MSB側ビット位置検出回路104は、検出したビット位置から最大指数を算出して出力する回路である。具体的には、MSB側ビット位置検出回路104は、レジスタ103が出力するレジスタ値107のビットの値が1である位置が、MSB側から数えてMビット目である場合(Mは0以上の整数)、最大指数として-1xMを出力する。
 ここで、レジスタ103は動作サイクルごとにレジスタ値107を出力するが、MSB側ビット位置検出回路104は、ブロックとしての最終的なレジスタ値107に基づいて、最大指数を算出する。MSB側ビット位置検出回路104は、ブロックエンド信号を参照して、ブロックとしての最終的な論理和値を示すレジスタ値107がレジスタ103から出力されるサイクルを認識する。MSB側ビット位置検出回路104は、最終的な論理和値を示すレジスタ値107を構成するビット列のMSB側の遷移値のビット位置を検出して、最大指数を算出する。MSB側ビット位置検出回路104は、最大指数として出力する。
[第3の実施の形態の動作]
 次に、図8を参照して、本発明の実施の形態3にかかる最大指数算出回路の動作について説明する。図8は、本発明の実施の形態3にかかる最大指数算出回路150の動作を示すタイミング図である。最大指数算出回路150は、入力されたクロック信号に基づいて動作を行う。
 まず、正規化対象のブロックの例として、次に示す入力データ1~入力データ8の8つのデータからなるブロックを考える。各入力データは、8ビットである。下記では各データの値を2の補数表現で示している。
入力データ1: 00010111
入力データ2: 00110001
入力データ3: 00000110
入力データ4: 11110011
入力データ5: 11111000
入力データ6: 00000110
入力データ7: 00001011
入力データ8: 00011011
(サイクル1)
 まず、動作サイクルの1サイクル目(サイクル1)で、最大指数算出回路150は、4つの入力データ1~4が入力される。4つのエッジ検出回路101のそれぞれは、入力データ1~4を構成するビット列の値のそれぞれの遷移(エッジ)を検出する。4つのエッジ検出回路101は、検出結果のそれぞれをエッジ検出結果1a~1dとして論理和回路152に出力する。より詳細には、エッジ検出回路101のそれぞれは、入力データ1a~1dを構成するビット列のそれぞれについて、隣接するビット間の排他的論理和を算出して出力する。ここで、入力データ1の検出結果はエッジ検出結果1aであり、入力データ2の検出結果はエッジ検出結果1bであり、入力データ3の検出結果はエッジ検出結果1cであり、入力データ4の検出結果はエッジ検出結果1dである。
エッジ検出結果1a: 0011100
エッジ検出結果1b: 0101001
エッジ検出結果1c: 0000101
エッジ検出結果1d: 0001010
 つぎに、論理和回路152は、4つのエッジ検出回路101がそれぞれ出力するエッジ検出結果1a~1dと、レジスタ103が出力するレジスタ値1との論理和を算出する。論理和回路152は、算出した論理和を論理和値1としてレジスタ103に出力する。ここで、サイクル1におけるレジスタ値1の値は初期値の0である。
論理和値1: 0111111
 レジスタ103は、サイクル1において論理和回路152が出力する論理和値1を保持する。レジスタ103は、つぎの動作サイクルであるサイクル2において、保持した論理和値1をレジスタ値2として出力する。
(サイクル2)
 つぎに、動作サイクルの2サイクル目(サイクル2)では、最大指数算出回路150は、4つの入力データ5~8が入力される。4つのエッジ検出回路101のそれぞれは、入力データ5~8を構成するビット列の値のそれぞれの遷移(エッジ)を検出する。エッジ検出回路101は、検出結果のそれぞれをエッジ検出結果2a~2dとして論理和回路152に出力する。より詳細には、エッジ検出回路101のそれぞれは、入力データ2a~2dを構成するビット列のそれぞれについて、隣接するビット間の排他的論理和を算出して出力する。ここで、入力データ5の検出結果はエッジ検出結果2aであり、入力データ6の検出結果はエッジ検出結果2bであり、入力データ7の検出結果はエッジ検出結果2cであり、入力データ8の検出結果はエッジ検出結果2dである。
エッジ検出結果2a: 0000100
エッジ検出結果2b: 0000101
エッジ検出結果2c: 0001110
エッジ検出結果2d: 0010110
 つぎに、論理和回路152は、4つのエッジ検出回路101がそれぞれ出力するエッジ検出結果2a~2dと、レジスタ103が出力するレジスタ値2との論理和を算出する。論理和回路102は、算出した論理和を論理和値2としてレジスタ103に出力する。ここで、サイクル2におけるレジスタ103の出力であるレジスタ値2の値は、サイクル1で保持した論理和値1である。
論理和値2: 0111111
 サイクル3はブロックの最後の動作サイクルの次のサイクルであるので、MSB側ビット位置検出回路104は、ブロックとしての最終的な論理和値2について、論理和値を構成するビット列のMSB側の遷移値のビット位置を検出する。MSB側ビット位置検出回路104は、検出したビット位置から最大指数を算出する。MSB側ビット位置検出回路104は、算出した最大指数を出力する。具体的には、論理和値2のビットの値が1となるビット位置は、MSB側から数えて2ビット目であるので、MSB側ビット位置検出回路104は、最大指数として-1を出力する。
 また、サイクル3はブロックの最後の動作サイクルの次のサイクルであるので、レジスタ103は、ブロックに対して保持している論理和値を初期値である0にリセットする。その結果、レジスタ103は、次のサイクルで初期値0を出力する。
 ここで、MSB側ビット位置検出回路104及びレジスタ103は、各ブロックの最後の動作サイクルを、入力されたブロックエンド信号の値が1になるサイクルとして識別する。図8においては、サイクル2でブロックエンド信号の値が1となっているため、サイクル2がブロックの最後の動作サイクルであることを示している。
 つぎに、入力データに負側の最大値が含まれる場合について説明する。8ビットの入力データの場合、そのデータの負側の最大値は-1x(2の7乗)=-128であり、2の補数表現では、10000000である。この入力データのエッジ検出結果は1000000になる。したがって、ブロックとしての最終的な論理和値のMSBは値1になるので、入力データに負側の最大値が含まれるブロックの最大指数は0と算出される。すなわち、本実施の形態3においても、入力データに負側の最大値が含まれる場合であっても、正しい最大指数を算出することができる。
[第3の実施の形態の効果]
 本実施の形態3では、ブロック浮動小数点の正規化処理において、エッジ検出回路101を使用して最大指数を算出する、ことを特徴としている。エッジ検出回路101は、入力データを構成するビット列の隣接するビット間の排他的論理和をそれぞれ算出するだけでよいので、複数のXOR回路からなる論理段数が1段の単純な構成の回路で実現することができる。
 したがって、背景技術として説明したように入力データの絶対値を算出する絶対値回路が必要な正規化処理と比較して、本実施の形態3による最大指数算出回路は、最大指数を高速に算出することが可能であり、かつ回路規模や消費電力を小さくすることができる。
 さらに、本実施の形態3による最大指数算出回路は、入力データに負側の最大値が含まれる場合であっても正しく処理することが可能である。したがって、本実施の形態3にかかる最大指数算出回路によれば、データの値が負側の最大値の場合でも、そのデータを特別に処理する必要や、負側の最大値を使用しないようにする必要がない、という特徴がある。
 さらに、本実施の形態3による最大指数算出回路は、4つのエッジ検出回路101を備え、エッジ検出処理を並列に実行するので、最大指数を高速に算出することが可能である、という特徴がある。
 ここで、本実施の形態3では、4つのエッジ検出回路101を備え、エッジ検出処理を4並列で実行する場合について説明したが、エッジ検出回路101の数は任意であっても良い。例えば、N個のエッジ検出回路101を備え、エッジ検出処理をN並列で実行する最大指数算出回路160の構成例を図9に示す(ここでNは2以上の整数)。
 図9において、最大指数算出回路160が備えるN+1入力の論理和回路162は、 N個のエッジ検出回路101が出力するN個のエッジ検出結果と、レジスタ103が出力するレジスタ値107の論理和を算出する。
[第4の実施の形態]
 次に、図10を参照して、本発明の実施の形態4にかかるブロック浮動小数点正規化回路について説明する。本発明の実施の形態4では、実施の形態3にかかる最大指数算出回路を使用したブロック浮動小数点正規化回路の具体例について説明する。
 図10は、本発明の実施の形態4にかかるブロック浮動小数点正規化回路(以下では正規化回路と表記する)の構成を示すブロック図である。
 図10において、本実施の形態4による正規化回路は、ブロックを構成する各入力データに対してブロック浮動小数点における正規化処理を行う。正規化回路は、入力データを正規化したデータを正規化データとして出力する。ここで、本実施の形態4による正規化回路は、4つの入力データが同時に入力され、同時に入力された4つの入力データを正規化した4つの正規化データを同時に出力する。
 図11において、本実施の形態4による正規化回路は、4つのメモリ120と、実施の形態3による最大指数算出回路150と、4つのシフト回路130とを有する。
 実施の形態3による最大指数算出回路150は、入力された入力データa~dに対して、最大指数を算出する。最大指数算出回路150は、算出した最大指数を最大指数158として4つのシフト回路130に出力する。
 4つのメモリ120はそれぞれ、最大指数算出回路150が入力された入力データの最大指数を算出している間、入力データa~dを保持する。入力データは、例えば、外部装置(図示せず)から4つのメモリ120と最大指数算出回路100のそれぞれに、4つずつ順次入力される。4つのメモリ120のそれぞれは、外部装置から入力される入力データを順次保持していく。また、4つのメモリ120のそれぞれは、最大指数算出回路150が最大指数の算出を完了した後、保持していた入力データa~dを、入力データ121a~dとして順次シフト回路130に対して出力する。
 4つのシフト回路130のそれぞれは、入力された入力データに対して最大指数算出回路150が算出した最大指数158に基づいて、4つのメモリ120が出力する入力データ121a~dのそれぞれをシフトすることで正規化処理を行う。
[第4の実施の形態の動作]
 次に、図11を参照して、本発明の実施の形態4にかかる正規化回路の動作について説明する。図11は、本発明の実施の形態4にかかる正規化回路の動作を示すタイミングチャートである。本発明の実施の形態4にかかる正規化回路は、入力されたクロック信号に基づいて動作を行う。
 正規化対象のブロックの例として、実施の形態3と同様に、次に示す入力データ1~入力データ8の8つのデータからなるブロックを考える。各入力データは、8ビットである。下記では各データの値を2の補数表現で示している。
入力データ1: 00010111
入力データ2: 00110001
入力データ3: 00000110
入力データ4: 11110011
入力データ5: 11111000
入力データ6: 00000110
入力データ7: 00001011
入力データ8: 00011011
 図11は、図8に示すサイクル1~サイクル2において、最大指数算出回路150が、入力された入力データの最大指数を算出した後の、サイクル1'~サイクル2'における動作を示している。ここで、サイクル1の動作は、図8で示したものと同様であるとして、図示を省略している。また、サイクル3とサイクル1'は同一の動作サイクルを示している。
 4つのメモリ120のそれぞれは、サイクル1~2において、最大指数算出回路150が入力する入力データの最大指数を算出している間、入力データを保持している。つぎに、4つのメモリ120のそれぞれは、最大指数算出回路150が最大指数の算出を完了した後、サイクル1'~2'において、保持していた入力データを順次シフト回路130に出力する。ここで、メモリ120は、ブロックエンド信号を参照して、最大指数算出回路150が最大指数の算出を完了するタイミングを識別する。
 最大指数算出回路150は、サイクル1~2において、1サイクルに4つずつ入力された入力データの最大指数を算出する。つぎに、最大指数算出回路150は、サイクル3において、算出した最大指数として-1をシフト回路130に出力する。最大指数算出回路150は、メモリ120が保持していた入力データの出力を完了するサイクル2'まで、最大指数である-1の出力を継続する。
 4つのシフト回路130は、サイクル1'~3'において、最大指数算出回路150が算出して出力する最大指数である-1に基づいて、メモリ120が出力する入力データ1~8を1サイクルに4つずつ順次シフトすることで正規化処理を行う。そして、シフト回路130は、入力データ1~8を正規化したデータを正規化データ1~8として出力する。
 その結果、シフト回路130が出力する正規化データ1~8は以下に示す値になり、正しく正規化処理が完了する。入力データkの正規化後のデータは、正規化データkとして示している(kは、1~8のいずれかの正整数)。
正規化データ1: 00101110
正規化データ2: 01100010
正規化データ3: 00001100
正規化データ4: 11100110
正規化データ5: 11110000
正規化データ6: 00001100
正規化データ7: 00010110
正規化データ8: 00110110
[第4の実施の形態の効果]
 本実施の形態4では、ブロック浮動小数点の正規化処理において、演算処理量の大きい最大指数の算出に、実施の形態3による最大指数算出回路150を使用するので、最大指数の算出処理に必要な回路規模や消費電力を小さくすることができる。さらに、本実施の形態4にかかる正規化回路は、最大指数を高速に算出することが可能であり、かつ回路規模や消費電力を小さくすることができる最大指数算出回路150を有する。そして、正規化回路は、最大指数算出回路150が算出した最大指数に基づいて、ブロック浮動小数点の正規化処理を実行している。その結果、本実施の形態4によれば、ブロック浮動小数点の正規化処理を高速に実行することが可能であり、かつ、回路規模や消費電力を小さくすることができる。
 さらに、本実施の形態4にかかるブロック浮動小数点正規化回路は、メモリ120やシフト回路130をそれぞれ4つずつ備え、かつ、4並列で最大指数を算出する最大指数算出回路150を備えるので、ブロック浮動小数点の最大指数算出処理及び正規化処理を4並列で実行することができる。その結果、ブロック浮動小数点の正規化処理を高速に実行することができる、という特徴がある。
 ここで、本実施の形態4では、正規化処理を4並列で実行する場合について説明したが、並列数は任意であっても良い。例えば、N個のメモリ120と4つのシフト回路130を備え、かつ、N並列で最大指数を算出する最大指数算出回路160を備えることで、正規化処理をN並列で実行するブロック浮動小数点正規化回路の構成例を図12に示す(ここでNは2以上の整数)。
 なお、本発明は上記実施の形態に限られたものではなく、趣旨を逸脱しない範囲で適宜変更することが可能である。
 本実施の形態では、エッジ検出回路は、入力データを構成するビット列について、互いに隣接するビットの値が異なることを示す値(遷移値)を1とし、互いに隣接するビットの値が異ならないことを示す値(非遷移値)を0としたビット列を生成するようにしているが、これに限られない。エッジ検出回路は、互いに隣接するビットの値が異なることを示す値を0とし、互いに隣接するビットの値が異ならないことを示す値を1としたビット列を生成するようにしてもよい。つまり、エッジ検出回路が、例えば、XOR回路ではなく、XNOR回路を有するようにしてもよい。この場合、例えば、論理和回路に代えて、エッジ検出回路から出力されたデータの論理積を算出する論理積回路を備えるようにする。そして、MSB側ビット位置検出回路は、論理積回路が出力した論理積値のビットの値が0となるビット位置に基づいて、最大指数を算出するようにする。
 本実施の形態では、エッジ検出回路及び論理和回路が生成するビット列は、入力データを構成するビット列のMSBからnビット目及びn+1ビット目の組のXOR結果を、MSBからnビット目として配列しているが、これに限られない(nは、0以上の整数)。例えば、入力データのビット列が8ビットの場合、エッジ検出回路及び論理和回路は、入力データを構成するビット列のMSBからnビット目及びn+1ビット目の組のXOR結果を、MSBから(7-n)ビット目として配列するようにしてもよい。言い換えると、エッジ検出回路及び論理和回路は、入力データを構成するビット列のMSBからnビット目及びn+1ビット目の組のXOR結果を、LSBからnビット目として配列するようにしてもよい。この場合、例えば、MSB側ビット位置検出回路に代えて、レジスタが出力する論理和値のビットの値が1である位置が、LSB側から数えてLビット目であるときに、LSB側から最大指数として-1xLを算出するビット位置検出回路を備えるようにする(Lは、0以上の整数)。なお、LSBから0ビット目と言った場合は、LSBであるものとする。
 本実施の形態では、エッジ検出回路が生成したビット列の論理和を算出して、算出した論理和に基づいて、最大指数を算出するようにしているが、これに限られない。例えば、論理和回路及びレジスタを備えずに、エッジ検出回路が生成したビット列を順次MSB側ビット位置検出回路に直接出力するようにしてもよい。この場合、MSB側ビット位置検出回路は、エッジ検出回路から順次出力されるビット列のそれぞれについて指数を算出する。そして、MSB側ビット位置検出回路は、ブロック内の全データのうち、最も値が大きい指数を最大指数とするようにしてもよい。これによれば、ブロック内の各入力データの絶対値を順次算出して、算出した絶対値のそれぞれについて指数を算出して、ブロック内の全データのうち、最も値が大きい指数を最大指数とする場合と比較して、最大指数を高速に算出することが可能である。
 この出願は、2010年6月22日に出願された日本出願特願2010-141765を基礎とする優先権を主張し、その開示の全てをここに取り込む。
50  半導体集積回路
51  ビット列生成回路
52  指数算出回路
100  最大指数算出回路
101  エッジ検出回路
102  論理和回路
103  レジスタ
104  MSB側ビット位置検出回路
105  エッジ検出結果
106  論理和値
107  レジスタ値
110  排他的論理和回路
120  メモリ
130  シフト回路
150  最大指数算出回路
152  論理和回路
160  最大指数算出回路
162  論理和回路

Claims (10)

  1.  複数のデータを共通の指数によって正規化する場合に、当該複数のデータの指数を算出する半導体集積回路であって、
     前記データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、当該互いに隣接するビットの値が異なることを示す遷移値、又は、当該互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成するビット列生成回路と、
     前記ビット列生成回路によって前記複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の前記遷移値のビットの位置に基づいて、前記複数のデータの指数を算出する指数算出回路と、
     を備えたことを特徴とする半導体集積回路。
  2.  前記指数算出回路は、
     前記複数の第2のビット列に基づいて、前記複数の第2のビット列の少なくとも1つで、同一位置におけるビットが前記遷移値である場合、当該位置に対応するビットを第1の値とし、前記複数の第2のビット列の全てで、同一位置におけるビットが前記非遷移値である場合、当該位置に対応するビットを第2の値とした第3のビット列を生成するビット列合成回路と、
     前記ビット列合成回路が生成した第3のビット列における前記第1の値のビットの位置に基づいて、前記指数を算出するビット位置検出回路と、を有することを特徴とする請求項1に記載の半導体集積回路。
  3.  前記第2のビット列は、前記第1のビット列の最上位ビットからn(nは、0以上の整数)ビット目及びn+1ビット目の組に対応するビットを、最上位ビットからnビット目として配列し、
     前記第3のビット列は、前記第2のビット列の最上位ビットからnビット目に対応するビットを、最上位ビットからnビット目として配列し、
     前記ビット位置検出回路は、前記第3のビット列のうち、前記第1の値のビットの最上位ビットからの位置に基づいて、前記指数を算出することを特徴とする請求項2に記載の半導体集積回路。
  4.  前記ビット列合成回路は、前記複数の第2のビット列の論理和となる第3のビット列を生成することを特徴とする請求項2又は3に記載の半導体集積回路。
  5.  前記ビット列生成回路は、前記データを構成する第1のビット列に含まれ、互いに隣接するビットの排他的論理和を示すビットを含む第2のビット列を生成することを特徴とする請求項4に記載の半導体集積回路。
  6.  前記半導体集積回路は、前記第3のビット列を格納するビット列記憶手段をさらに備え、
     前記半導体集積回路は、前記ビット列生成回路を複数備え、
     前記複数のビット列生成回路は、前記複数のデータから当該複数のビット列生成回路の数ずつ前記第2のビット列を生成し、
     前記ビット列合成回路は、前記複数のビット列生成回路によって複数の第2のビット列が生成される毎に、当該複数の第2のビット列と前記ビット列記憶手段に格納された第3のビット列とに基づいて、前記第3のビット列を生成して前記ビット列記憶手段に格納された第3のビット列を更新するとともに、前記複数の第2のビット列及び前記第3のビット列の少なくとも1つで、同一位置におけるビットが前記遷移値である場合、当該位置に対応するビットを前記第1の値とし、前記複数の第2のビット列及び前記第3のビット列の全てで、同一位置におけるビット列が前記非遷移値である場合、当該位置に対応するビットを前記第2の値とした第3のビット列を生成することを特徴とする請求項2乃至5のいずれか1項に記載の半導体集積回路。
  7.  前記半導体集積回路は、前記指数算出回路が算出した指数に基づいて、前記第1のビット列をシフトすることによって前記データを正規化するシフト回路をさらに備えたことを特徴とする請求項1乃至6のいずれか1項に記載の半導体集積回路。
  8.  前記半導体集積回路は、前記シフト回路を複数備え、
     前記複数のシフト回路は、前記複数のデータを当該複数のシフト回路の数ずつ正規化することを特徴とする請求項7に記載の半導体集積回路。
  9.  前記複数のデータは、ブロック浮動小数点において同一のブロックに含まれるデータであり、
     前記指数算出回路は、前記ブロックにおける最大指数を算出することを特徴とする請求項1乃至8のいずれか1項に記載の半導体集積回路。
  10.  複数のデータを共通の指数によって正規化する場合に、当該複数のデータの指数を算出する指数算出方法であって、
     前記データを構成する第1のビット列の互いに隣接するビットの組のそれぞれについて、当該互いに隣接するビットの値が異なることを示す遷移値、又は、当該互いに隣接するビットの値が異ならないことを示す非遷移値をとるビットを含む第2のビット列を生成し、
     前記複数のデータのそれぞれを構成する複数の第1のビット列から生成された複数の第2のビット列の前記遷移値のビットの位置に基づいて、前記複数のデータの指数を算出する、
     指数算出方法。
PCT/JP2011/002148 2010-06-22 2011-04-12 半導体集積回路及び指数算出方法 WO2011161859A1 (ja)

Priority Applications (4)

Application Number Priority Date Filing Date Title
EP11760675.6A EP2431865B1 (en) 2010-06-22 2011-04-12 Semiconductor integrated circuit and index calculation method
CN201180001677.1A CN102378960B (zh) 2010-06-22 2011-04-12 半导体集成电路和指数计算方法
JP2011539841A JP4883251B1 (ja) 2010-06-22 2011-04-12 半導体集積回路及び指数算出方法
US13/262,748 US8862647B2 (en) 2010-06-22 2011-04-12 Semiconductor integrated circuit and exponent calculation method

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2010-141765 2010-06-22
JP2010141765 2010-06-22

Publications (1)

Publication Number Publication Date
WO2011161859A1 true WO2011161859A1 (ja) 2011-12-29

Family

ID=45371067

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2011/002148 WO2011161859A1 (ja) 2010-06-22 2011-04-12 半導体集積回路及び指数算出方法

Country Status (5)

Country Link
US (1) US8862647B2 (ja)
EP (1) EP2431865B1 (ja)
JP (1) JP4883251B1 (ja)
CN (1) CN102378960B (ja)
WO (1) WO2011161859A1 (ja)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2431865B1 (en) * 2010-06-22 2018-05-23 Nec Corporation Semiconductor integrated circuit and index calculation method
JP6216123B2 (ja) * 2013-01-30 2017-10-18 ブラザー工業株式会社 画像形成装置
US9577672B2 (en) * 2014-07-18 2017-02-21 Storart Technology Co., Ltd. Low density parity-check code decoder and decoding method thereof
US10528321B2 (en) * 2016-12-07 2020-01-07 Microsoft Technology Licensing, Llc Block floating point for neural network implementations
DE102020104594B4 (de) * 2020-02-21 2024-01-25 Infineon Technologies Ag Verarbeitung von Radarsignalen

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0675746A (ja) 1992-08-27 1994-03-18 Matsushita Electric Ind Co Ltd 1位置検出方法及び演算器
JPH08212052A (ja) 1995-02-03 1996-08-20 Fujitsu Ltd 正規化データ生成回路
JPH09128213A (ja) 1995-10-31 1997-05-16 Hitachi Ltd ブロックフローティング処理システムおよび方法
JPH1040073A (ja) * 1996-07-24 1998-02-13 Matsushita Electric Ind Co Ltd ディジタル信号処理装置
JP2002318792A (ja) * 2001-04-24 2002-10-31 Asahi Kasei Corp データ演算処理装置及びデータ演算処理プログラム

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3127600B2 (ja) * 1992-09-11 2001-01-29 ソニー株式会社 ディジタル信号復号化装置及び方法
JP3313560B2 (ja) * 1996-01-31 2002-08-12 株式会社日立製作所 浮動小数点演算処理装置
JP3642053B2 (ja) * 2002-02-25 2005-04-27 日本電気株式会社 シンボルデータ変換回路
JP4413198B2 (ja) * 2006-03-23 2010-02-10 富士通株式会社 浮動小数点データの総和演算処理方法及びコンピュータシステム
US7917567B1 (en) * 2007-06-07 2011-03-29 Xilinx, Inc. Floating-point processing unit for successive floating-point operations
US8631056B2 (en) * 2008-01-09 2014-01-14 Qualcomm Incorporated Processor and method of determining a normalization count
EP2431865B1 (en) * 2010-06-22 2018-05-23 Nec Corporation Semiconductor integrated circuit and index calculation method
WO2012157132A1 (ja) * 2011-05-16 2012-11-22 日本電気株式会社 演算処理装置及び演算処理方法

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0675746A (ja) 1992-08-27 1994-03-18 Matsushita Electric Ind Co Ltd 1位置検出方法及び演算器
JPH08212052A (ja) 1995-02-03 1996-08-20 Fujitsu Ltd 正規化データ生成回路
JPH09128213A (ja) 1995-10-31 1997-05-16 Hitachi Ltd ブロックフローティング処理システムおよび方法
JPH1040073A (ja) * 1996-07-24 1998-02-13 Matsushita Electric Ind Co Ltd ディジタル信号処理装置
JP2002318792A (ja) * 2001-04-24 2002-10-31 Asahi Kasei Corp データ演算処理装置及びデータ演算処理プログラム

Also Published As

Publication number Publication date
US20120117337A1 (en) 2012-05-10
US8862647B2 (en) 2014-10-14
EP2431865A4 (en) 2017-04-19
EP2431865B1 (en) 2018-05-23
JPWO2011161859A1 (ja) 2013-08-19
EP2431865A1 (en) 2012-03-21
CN102378960B (zh) 2014-07-30
JP4883251B1 (ja) 2012-02-22
CN102378960A (zh) 2012-03-14

Similar Documents

Publication Publication Date Title
Tenca et al. High-radix design of a scalable modular multiplier
CN105468331B (zh) 独立的浮点转换单元
JP4883251B1 (ja) 半導体集積回路及び指数算出方法
JP5640081B2 (ja) 飽和を伴う整数乗算および乗算加算演算
US9519457B2 (en) Arithmetic processing apparatus and an arithmetic processing method
JP2585649B2 (ja) 除算回路
CN111936965A (zh) 随机舍入逻辑
WO2016119547A1 (en) Method and apparatus for converting from integer to floating point representation
JP2013210838A (ja) 演算回路及び演算方法
Zarandi et al. An Efficient Component for Designing Signed Reverse Converters for a Class of RNS Moduli Sets of Composite Form $\{2^{k}, 2^{P}-1\} $
RU2696223C1 (ru) Арифметико-логическое устройство для формирования остатка по произвольному модулю от числа
US7401107B2 (en) Data processing apparatus and method for converting a fixed point number to a floating point number
JP7044528B2 (ja) リーディングゼロ予想
CN113672196B (zh) 一种基于单数字信号处理单元的双乘法计算装置和方法
CN115268832A (zh) 浮点数取整的方法、装置以及电子设备
JP4290203B2 (ja) リダクションアレイの装置および方法
RU2562411C1 (ru) Устройство для вычисления модуля комплексного числа
JP4109181B2 (ja) 論理回路、および、それを使用した浮動小数点演算回路とマイクロプロセッサ
US20080307032A1 (en) Divider Circuit
JP2009245407A (ja) 複素数の積和演算装置および積和演算方法
JP2009267606A (ja) 演算器
JP3613466B2 (ja) データ演算処理装置及びデータ演算処理プログラム
EP3289445B1 (en) Floating point computation apparatus and method
JP3198868B2 (ja) 乗算処理装置
KR20230015844A (ko) 극소 검출

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201180001677.1

Country of ref document: CN

WWE Wipo information: entry into national phase

Ref document number: 2011539841

Country of ref document: JP

WWE Wipo information: entry into national phase

Ref document number: 2011760675

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 13262748

Country of ref document: US

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11760675

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE