摘要:
In floating point opertaions, it is necessary to align the fractions of the exponents before addition or subtraction operations can be executed. This fraction alignment is performed by a shifting operation, typically using dedicated apparatus such as a barrel shifter. While the dedicated apparatus provides high performance in the execution of the shifting operation, this performance is accomplished by reserving a portion of the substrate area to apparatus implementation. To avoid the use of dedicated apparatus, the shifting operation is performed in a multiplier unit, according to the present invention, by entering the number to be shifted in the multiplicand register of the multiplier unit while entering appropriate control signals in the multiplier register. In this manner, a shifting operation can be performed without dedicated apparatus and with minor impact on performance.
摘要:
A shift control circuit comprising an arithmetic circuit (20) for producing a string of a predetermined number of data bits, a logic circuit (22) for detecting the positive or negative sign of the bit string and producing a first switch signal responsive to the positive sign of the bit string or a second switch signal responsive to the negative sign of the bit string, a ones complement generator circuit (24) for producing a signal representative of the ones complement of the bit string, a first selective signal transfer circuit (26) such as a multiplexer which is transparent directly to the bit string in response to the first switch signal or to the signal from the ones complement generator circuit in response to the second switch signal, a decoder circuit (28) for decording the bit string or the signal passed through the first selective signal transfer circuit for producing a decoded output signal, a single-bit shifter circuit (30) for shifting the bit of the decoded output signal by a single bit in a predetermined direction for producing a single-bit shifted output signal, and a second selective signal transfer circuit (32) such as a multiplexer which is transparent directly to the decoded output signal in response to the first switch signal or to the signal from the single-bit shifter circuit (30) in response to the second switch signal.
摘要:
In a digital signal processor comprising interface means for data input output with an external device; data buses (21, 22); data memories (5, 6); floating point multiplier (14) for adding exponent parts and multiplying mantissa parts of a pair of data applied; a floating adder/subtracter (15); an accumulator (16); a switching circuit (17) and a control circuit (4), the floating adder/subtracter comprising adjusting means (67 to 69, 63 to 65) for adjusting two floating point data; an adder (75) for adding the two adjusted mantissa parts of the two floating point data; a leftwards shift circuit (76) for shifting output data from the adder; a zero detector (79) to provide a first shift data signal; a correction circuit (85) and a control circuit (89) to generate an underflow signal and provide a normalized exponent part of the sum of the two data; a constant adder circuit (77) and a selector (81) for providing the shift circuit with a second shift data signal, or the first shift data signal depending on whether or not the underflow signal is generated.
摘要:
A digital signal processor comprising interface means for data inputoutput with an external device; a first data bus (21) which has a predetermined number of bits and which is connected to the interface means; data memories (5, 6) connected to the data bus; a second data bus (22) onto which a data from the data memories is read out; a floating point multiplier (14) connected with the first and second data buses and for adding exponent parts and multiplying mantissa parts of a pair of data applied, to deliver an operated result having a number of bits larger than that of the first data bus; a floating adder-subtracter (15) including an input selection portion selecting a pair of data appointed by a program instruction from amongst a plurality of data containing the output of the multiplier, and for adding subtracting said pair of data; an accumulator (16) for holding a data delivered from the adder subtracter and having a number of bits larger than that of the first data bus; a third data bus (27) which has a number of bits larger than that of the first data bus and which supplies an output of said accumulator to said input selection portion of said adder subtracter; a switching circuit (17) connected between said accumulator and the first data bus and for reducing the number of bits of the output data of the accumulator and then supplying the resultant data to the first data bus; and a control circuit (4) for controlling the operations of the respective means in accordance with program instructions.
摘要:
An integrated circuit is provided that performs floating-point addition or subtraction operations involving at least three floating-point numbers. The floating-point numbers are pre-processed by dynamically extending the number of mantissa bits, determining the floating-point number with the biggest exponent, and shifting the mantissa of the other floating-point numbers to the right. Each extended mantissa has at least twice the number of bits of the mantissa entering the floating-point operation. The exact bit extension is dependent on the number of floating-point numbers to be added. The mantissas of all floating-point numbers with an exponent smaller than the biggest exponent are shifted to the right. The number of right shift bits is dependent on the difference between the biggest exponent and the respective floating-point exponent.
摘要:
A floating point unit includes a floating point adder to perform a floating point addition operation between first and second floating point numbers each having an exponent and a mantissa. The floating point unit also includes an alignment shifter that may calculate a shift value corresponding to a number of bit positions to shift the second mantissa such that the second exponent value is the same as the first exponent value. The alignment shifter may detect an overshift condition, in which the shift value is greater than or equal to a selected overshift threshold value. The selected overshift threshold value comprises a base 2 number in a range of overshift values including a minimum overshift threshold value and a maximum overshift threshold value, and which has a largest number of a consecutive of bits that are zero beginning at a least significant bit.
摘要:
An arithmetic operation unit, which generates shift information representing whether or not an arithmetic operation result has been shifted when the arithmetic operation result is normalized, has an arithmetic logical unit for outputting the arithmetic operation result, a normalizer (30) having a plurality of shifters for normalizing the arithmetic operation result, a shift amount calculator for calculating a plurality of shift amounts for the plural shifters, and a predictor (51) for generating interim information that is a result of prediction of whether or not the arithmetic operation result is to be shifted when the arithmetic operation result is normalized, by using the plural shift amounts, and a generator (52) for generating the shift information by using the interim information. The cycle time required to generate the interim information (a sticky bit) is shortened to efficiently generate the sticky bit, and the hardware resources for generating the sticky bit are reduced.
摘要:
To provide a compiler apparatus which makes it easy to describe arithmetic operations in source programs, makes it simple to write source programs, and reduces bugs, when performing block floating-point operations in software. When the compiler apparatus is fed a source program containing computing expressions written using block floating variables, it detects computing expressions for addition in the source program, expands that part of the detected computing expressions which involves addition into instruction codes which specify addition for data blocks corresponding to a plurality of block floating variables to be subjected to addition, embeds the instruction codes in the object program to be generated, and outputs the object program.
摘要:
A method and system for processing instructions in a floating point unit for executing denormalized numbers in floating point pipeline via serializing uses an instruction unit and having a control unit and a pipelined data flow unit, a shifter and a rounding unit. The floating point unit has an external feedback path for providing intermediate result data from said rounding unit to an input of the pipelined data flow unit to reuse the pipeline for denormalization by passing intermediate results in the pipeline which have a denormalized condition computed after the exponent calculation of the shifting circuit directly from the rounding unit to the top of the dataflow in the pipeline via an external feedback path. The pipelined has two paths which are selected based on the presence of other instructions in the pipeline. If no other instructions are in the pipeline a first path is taken which uses the external feedback path from the rounding unit back into the top of the dataflow. When there are instructions in the pipeline a shifter unit performing normalization of the fraction indicates possible underflow of the exponent, and prepares to hold the exponent and the fraction in a floating point data flow register; and upon detection of exponent underflow during the rounder stage and detection of any other instructions in pipeline; then the control unit forces an interrupt for serialization, and cancels execution of this instruction and other instructions in pipeline.