JPH04281524A - Floating point arithmetic processor - Google Patents

Floating point arithmetic processor

Info

Publication number
JPH04281524A
JPH04281524A JP3045061A JP4506191A JPH04281524A JP H04281524 A JPH04281524 A JP H04281524A JP 3045061 A JP3045061 A JP 3045061A JP 4506191 A JP4506191 A JP 4506191A JP H04281524 A JPH04281524 A JP H04281524A
Authority
JP
Japan
Prior art keywords
addition
error
section
sum
floating
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
JP3045061A
Other languages
Japanese (ja)
Inventor
Makoto Sakamoto
誠 坂本
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
JFE Steel Corp
Original Assignee
Kawasaki Steel Corp
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 Kawasaki Steel Corp filed Critical Kawasaki Steel Corp
Priority to JP3045061A priority Critical patent/JPH04281524A/en
Publication of JPH04281524A publication Critical patent/JPH04281524A/en
Pending legal-status Critical Current

Links

Abstract

(57)【要約】本公報は電子出願前の出願データであるた
め要約のデータは記録されません。
(57) [Summary] This bulletin contains application data before electronic filing, so abstract data is not recorded.

Description

【発明の詳細な説明】[Detailed description of the invention]

【0001】0001

【産業上の利用分野】本発明は、所定ビットのデジタル
データを浮動小数点加算処理する浮動小数点演算処理装
置、特にデータ伝送を行うバスの幅を増加せずに演算精
度を上昇するものに関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a floating-point arithmetic processing device that performs floating-point addition processing on digital data of predetermined bits, and more particularly to a floating-point arithmetic processing device that increases arithmetic precision without increasing the width of a bus for data transmission.

【0002】0002

【従来の技術】従来より、デジタル演算を行う場合にお
いて、扱えるデータのビット数は、入出力データバスの
バス幅によって限定されてしまう。すなわち、データバ
スが8ビットであった場合には、入力されるデータも8
ビットであり、出力される演算結果も8ビットである。 そこで、小数点演算を行う場合には、有効ビット数(有
効桁数)をなるべく多くするため、浮動小数点演算が行
われる場合が多い。このような浮動小数点演算において
は、扱うデータの大きさが大体揃っている場合には、か
なり高精度の演算を行うことができる。
2. Description of the Related Art Conventionally, when performing digital operations, the number of data bits that can be handled has been limited by the bus width of an input/output data bus. In other words, if the data bus is 8 bits, the input data will also be 8 bits.
The output result of the operation is also 8 bits. Therefore, when performing decimal point calculations, floating point calculations are often performed in order to increase the number of effective bits (number of effective digits) as much as possible. In such floating point calculations, if the size of the data to be handled is approximately the same, calculations can be performed with fairly high precision.

【0003】0003

【発明が解決しようとする課題】しかしながら、演算処
理を行うデータの小数点の位置が大きく異なる場合には
、浮動小数点演算によって有効な演算を行うことができ
ない場合が生ずる。たとえば、デジタルフィルタなどに
おいては、同一の係数を乗算して得た結果を順次加算し
ていきその総和を求める演算が利用される。このような
演算の場合、各回において加算する数字は小さなもので
あるが、これを累積加算していった場合には、累積加算
値はかなり大きな数となる。そして、この大きな値の前
回の加算結果に対し小さな値の今回の加算値を加算する
ため、小数点位置がかなり異なった数の加算となる。 そこで、このような加算を行うと、浮動小数点演算によ
っては、その誤差が大きくなってしまうという問題点が
あった。
However, if the positions of the decimal points of the data to be subjected to arithmetic processing differ greatly, there may be cases where floating point arithmetic cannot perform effective arithmetic. For example, in a digital filter, an operation is used in which the results obtained by multiplying by the same coefficient are sequentially added to obtain the total sum. In the case of such an operation, the numbers added each time are small, but when these numbers are cumulatively added, the cumulatively added value becomes a considerably large number. Then, since the current addition value, which is a small value, is added to the previous addition result, which has a large value, the numbers are added with considerably different decimal point positions. Therefore, when such addition is performed, there is a problem that the error becomes large depending on the floating point calculation.

【0004】一方、このような問題を解決するためには
、バス幅を増加させ、有効桁数を増やして対応すること
となる。しかし、バス幅を増加することは、データ演算
装置の回路規模が大きくなってしまい、また消費電力も
増加するという問題点があった。
On the other hand, in order to solve such problems, it is necessary to increase the bus width and increase the number of effective digits. However, increasing the bus width increases the circuit scale of the data processing device and also increases power consumption.

【0005】本発明は、バス幅を増大させずに浮動小数
点演算の精度を上昇することができる浮動小数点演算処
理装置を提供することを目的とする。
SUMMARY OF THE INVENTION An object of the present invention is to provide a floating point arithmetic processing device that can improve the precision of floating point arithmetic operations without increasing the bus width.

【0006】[0006]

【課題を解決するための手段】本発明に係る浮動小数点
演算処理装置は、所定の数列を順次浮動小数点加算して
総和を求める浮動小数点演算処理装置であって、順次点
加算して総和を求める総和算出部と、この総和算出部に
よって得られた今回の加算結果から前回の加算結果を減
算して、浮動小数点加算によって実際に加算された丸め
後加算値を求める減算部と、今回の演算において加算し
た値から減算部によって得られた丸め後加算値を減算し
て今回の演算における丸め誤差を算出する誤差算出部と
、この誤差算出部の丸め誤差を加算して累積誤差を算出
する累積誤差算出部と、加算部の演算結果に累積誤差を
加算して加算結果を補正する補正部とを有することを特
徴とする。
[Means for Solving the Problems] A floating point arithmetic processing device according to the present invention is a floating point arithmetic processing device that calculates a sum by sequentially adding floating point numbers to a predetermined number sequence, and which calculates a sum by sequentially adding points. A sum calculation section, a subtraction section that subtracts the previous addition result from the current addition result obtained by this sum calculation section to obtain the rounded addition value actually added by floating point addition, and a subtraction section that calculates the rounded addition value actually added by floating point addition. An error calculation unit that calculates the rounding error in the current operation by subtracting the rounded addition value obtained by the subtraction unit from the added value, and a cumulative error calculation unit that calculates the cumulative error by adding the rounding errors of this error calculation unit. and a correction section that adds an accumulated error to the calculation result of the addition section and corrects the addition result.

【0007】[0007]

【作用】このように本発明においては、総和算出部にお
いて、従来と同様に順次供給される加算値を積算してい
き総和を算出する。この総和算出部で算出された総和は
、浮動小数点演算によるものであり、有効桁数の制限に
よって丸められたものである。この総和算出部によって
得られた結果から前回の加算結果を減算すると、総和算
出部において今回実際に加算された丸め後の加算値を算
出することができる。ここで、この丸め後の加算値と今
回の加算値の差を求めることによって今回の加算演算に
おける丸め誤差が算出される。そして、この丸め誤差は
、その値が加算値よりも必ず小さなものとなっている。 このため、この丸め誤差を累積演算しても、この累積誤
差はそれほど大きな数字とはならない。従って、誤差算
出部において精度の高い誤差の累積演算が行われる。
[Operation] As described above, in the present invention, the sum calculation section calculates the sum by integrating the addition values sequentially supplied as in the conventional case. The sum calculated by this sum calculation unit is based on floating point arithmetic and is rounded due to the limit on the number of significant digits. By subtracting the previous addition result from the result obtained by the summation calculation section, the summation calculation section can calculate the rounded addition value that was actually added this time. Here, the rounding error in the current addition operation is calculated by finding the difference between the rounded addition value and the current addition value. The value of this rounding error is always smaller than the added value. Therefore, even if this rounding error is cumulatively calculated, the cumulative error does not become a very large number. Therefore, the error calculation section performs a highly accurate cumulative error calculation.

【0008】そこで、この累積誤差を総和演算部の最終
的な結果である総和に加算することによって高精度の累
積演算の値を得ることができる。そして、これらの演算
は全てバス幅を増加せずに行うことができ、バス幅を増
加せずに高精度の演算を達成することができる。
[0008] Therefore, by adding this cumulative error to the sum which is the final result of the sum calculation section, a highly accurate cumulative calculation value can be obtained. All of these operations can be performed without increasing the bus width, and highly accurate operations can be achieved without increasing the bus width.

【0009】[0009]

【実施例】以下、本発明に係る浮動小数点演算処理装置
、特に S=Σai     i=0〜n という式の加算を行うものについて図面に基づいて説明
する。
DESCRIPTION OF THE PREFERRED EMBODIMENTS Hereinafter, a floating point arithmetic processing device according to the present invention, particularly one that performs addition of the formula S=Σai i=0 to n, will be described with reference to the drawings.

【0010】図1は、実施例の全体構成を示す構成図で
あり、総和算出部10、減算部12、誤差算出部14、
累積誤差算出部16、補正部18からなっている。そし
て、総和算出部10は、加算器10aを有しており、入
力される加算値ai と加算器10aからの出力Si−
1 の加算を行う。ここで、この加算演算は1クロック
毎に行われるが、この演算によって1クロック分遅延す
るため、加算器10aの出力をそのまま入力に戻すこと
によってこの加算器10aによって加算値ai が順次
加算されることとなる。
FIG. 1 is a block diagram showing the overall structure of the embodiment, which includes a sum calculation section 10, a subtraction section 12, an error calculation section 14,
It consists of a cumulative error calculation section 16 and a correction section 18. The total sum calculation unit 10 has an adder 10a, and the input addition value ai and the output Si− from the adder 10a
Add 1. Here, this addition operation is performed every clock, but since this operation causes a delay of one clock, the output of the adder 10a is returned to the input as it is, so that the adder 10a sequentially adds the addition value ai. It happens.

【0011】すなわち、この総和算出部10においては
、 Si =Si−1 +ai  の演算が行われる。
That is, in this sum calculation section 10, the calculation Si=Si-1+ai is performed.

【0012】次に、この加算結果Si は、減算部12
に送られる。この減算部12は、減算器12a及び遅延
器12bからなっており、総和算出部10からの加算結
果についての信号とこれを1回遅延した前回の加算結果
の信号を減算器12aによって減算し丸め後加算値ti
 を求める。この丸め後加算値ti は総和算出部10
において出力された実際の丸め後の加算値2つの減算と
なっており、浮動小数点演算において実際に加算された
加算値を表している。
Next, this addition result Si is sent to the subtractor 12
sent to. The subtracter 12 is composed of a subtracter 12a and a delayer 12b, and the subtracter 12a subtracts the signal for the addition result from the sum calculation unit 10 and the signal for the previous addition result that is delayed once, and rounds the result. Post-added value ti
seek. This rounded addition value ti is calculated by the sum calculation unit 10
This is a subtraction of the two actual rounded addition values output in , and represents the addition value actually added in the floating point operation.

【0013】すなわち、この減算部12においては、t
i =Si −Si−1  という演算が行われる。
That is, in this subtraction section 12, t
The calculation i = Si - Si-1 is performed.

【0014】次に、この減算部12の演算結果である丸
め後加算値ti は、誤差算出部14に供給される。こ
の誤差算出部14は減算器14aと2つの遅延器14b
,14cからなっている。そして、丸め後加算値ti 
はそのまま減算器14aに入力され、今回の加算値ai
 は2つの遅延器14b,14cを介し減算器14aに
入力されている。ここで、丸め後加算値ti は、2つ
の加算器10a,12aを介し現慙愧14aに入力され
るため2クロック分遅延している。そこで、2つの遅延
器14b,14cを介し減算器14aに入力された加算
値ai とti は両方とも今回の加算に関するもので
ある。従って、浮動小数点演算において実際に加算され
た値ti と加算したかった加算値ai の差がこの減
算器14aにおいて得られることとなる。
Next, the rounded addition value ti, which is the calculation result of the subtraction unit 12, is supplied to the error calculation unit 14. This error calculation section 14 includes a subtracter 14a and two delay devices 14b.
, 14c. Then, the rounded addition value ti
is input as is to the subtractor 14a, and the current addition value ai
is input to the subtracter 14a via two delay devices 14b and 14c. Here, the rounded addition value ti is input to the adder 14a via the two adders 10a and 12a, so it is delayed by two clocks. Therefore, the addition values ai and ti inputted to the subtracter 14a via the two delay devices 14b and 14c are both related to the current addition. Therefore, the difference between the value ti actually added in the floating point operation and the added value ai to be added is obtained in the subtracter 14a.

【0015】すなわち、αi =ai −ti という
演算が誤差算出部14によって行われる。
That is, the error calculation unit 14 performs the calculation αi =ai −ti.

【0016】この誤差算出部14において算出された丸
め誤差αi は、丸め誤差を累積加算する累積誤差算出
部16に供給される。この累積誤差算出部16は丸め誤
差αi を累積加算する加算器16aからなっており、
このために加算器16aの出力が入力側に戻されている
。そして、この加算器16aにおいても1クロック分出
力は遅れたものであるため、この加算器16aにおいて
、βi =βi−1 +αi  という演算が行われる。
The rounding error αi calculated by the error calculating section 14 is supplied to a cumulative error calculating section 16 which cumulatively adds the rounding errors. The cumulative error calculation unit 16 includes an adder 16a that cumulatively adds rounding errors αi.
For this purpose, the output of the adder 16a is returned to the input side. Since the output of this adder 16a is also delayed by one clock, the calculation βi = βi-1 + αi is performed in this adder 16a.

【0017】そして、上述の総和算出部10の出力及び
累積誤差算出部16の出力は、補正部18に供給されて
いる。この補正部18は、加算器18aからなっており
、上述の総和算出部10、減算部12、誤差算出部14
、累積誤差算出部16における演算が全て終了した場合
に初めてその演算を行う。すなわち、加算値ai につ
いてその入力が終了し、これについての演算が全て終了
した場合にその時に加算器10a及び加算器16aにお
いて演算されていた結果である累積値の加算を行う。
The output of the sum calculation section 10 and the output of the cumulative error calculation section 16 described above are supplied to a correction section 18. This correction section 18 includes an adder 18a, and includes the above-mentioned sum calculation section 10, subtraction section 12, and error calculation section 14.
, the calculation is performed only when all the calculations in the cumulative error calculating section 16 are completed. That is, when the input of the addition value ai is completed and all calculations regarding it are completed, the cumulative values that are the results of calculations in the adders 10a and 16a at that time are added.

【0018】すなわちSi =Si +βi という演
算が行われる。
That is, the calculation Si=Si+βi is performed.

【0019】ここで、このような演算は全て同一ビット
幅のバスを介して行っている。しかし、累積誤差算出部
16における累積誤差は、その値がかなり小さいもので
あり、十分な精度をもって累積演算が行われる。このた
め、補正部18において出力される補正後の加算結果S
* については、誤差が非常に小さなものとなっている
。 従ってバス幅を増加せずに高精度の累積加算演算を達成
することができる。
[0019] Here, all such operations are performed via buses having the same bit width. However, the value of the cumulative error in the cumulative error calculating section 16 is quite small, and the cumulative calculation is performed with sufficient accuracy. Therefore, the addition result S after correction outputted by the correction unit 18
Regarding *, the error is very small. Therefore, highly accurate cumulative addition operations can be achieved without increasing the bus width.

【0020】各種の機器において、マイクロコンピュー
タ等を利用した制御などが行われるが、このような処理
において、特定の演算処理については、CPUを介さず
特定のゲートアレイ等で行う場合が多い。このようにす
るとCPUに対する負担が軽減されると共に所定の特定
演算のみを行うゲートアレイによって高速かつ高精度の
演算ができるからである。このような演算処理部におい
て本実施例の構成を利用すればそのゲートアレイの構成
を簡略化しかつ高精度の演算を行うことができる。
Various types of equipment are controlled using microcomputers and the like, but in such processing, specific arithmetic processing is often performed by a specific gate array or the like without using the CPU. This is because the load on the CPU is reduced and the gate array that performs only predetermined specific calculations allows high-speed and highly accurate calculations. If the configuration of this embodiment is utilized in such an arithmetic processing section, the configuration of the gate array can be simplified and highly accurate arithmetic operations can be performed.

【0021】[0021]

【発明の効果】以上説明したように、本発明に係る浮動
小数点演算処理装置によれば、バス幅を増加させること
なく、高精度の累積加算演算を行うことができる。
As described above, according to the floating point arithmetic processing device of the present invention, high-precision cumulative addition operations can be performed without increasing the bus width.

【図面の簡単な説明】[Brief explanation of the drawing]

【図1】本発明に係る浮動小数点演算処理装置の全体構
成を示すブロック図である。
FIG. 1 is a block diagram showing the overall configuration of a floating-point arithmetic processing device according to the present invention.

【符号の説明】[Explanation of symbols]

10  総和算出部 12  減算部 14  誤差算出部 16  累積誤差算出部 18  補正部 10 Total sum calculation section 12 Subtraction section 14 Error calculation section 16 Cumulative error calculation section 18 Correction section

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】所定の数列を順次浮動小数点加算して総和
を求める浮動小数点演算処理装置であって、順次点加算
して総和を求める総和算出部と、この総和算出部によっ
て得られた今回の加算結果から前回の加算結果を減算し
て、浮動小数点加算によって実際に加算された丸め後加
算値を求める減算部と、今回の演算において加算した値
から減算部によって得られた丸め後加算値を減算して今
回の演算における丸め誤差を算出する誤差算出部と、こ
の誤差算出部の丸め誤差を加算して累積誤差を算出する
累積誤差算出部と、加算部の演算結果に累積誤差を加算
して加算結果を補正する補正部と、を有することを特徴
とする浮動小数点演算処理装置。
1. A floating-point arithmetic processing device that calculates a sum by sequentially adding floating-point numbers to a predetermined sequence of numbers, comprising: a sum calculation unit that sequentially adds points and calculates the sum; A subtraction unit subtracts the previous addition result from the addition result to obtain the rounded addition value actually added by floating-point addition, and a rounded addition value obtained by the subtraction unit from the value added in the current operation. An error calculation section that calculates the rounding error in the current operation by subtracting, a cumulative error calculation section that adds the rounding error of this error calculation section to calculate the cumulative error, and a cumulative error calculation section that adds the cumulative error to the calculation result of the addition section. A floating point arithmetic processing device comprising: a correction section that corrects a result.
JP3045061A 1991-03-11 1991-03-11 Floating point arithmetic processor Pending JPH04281524A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP3045061A JPH04281524A (en) 1991-03-11 1991-03-11 Floating point arithmetic processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP3045061A JPH04281524A (en) 1991-03-11 1991-03-11 Floating point arithmetic processor

Publications (1)

Publication Number Publication Date
JPH04281524A true JPH04281524A (en) 1992-10-07

Family

ID=12708843

Family Applications (1)

Application Number Title Priority Date Filing Date
JP3045061A Pending JPH04281524A (en) 1991-03-11 1991-03-11 Floating point arithmetic processor

Country Status (1)

Country Link
JP (1) JPH04281524A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6055648A (en) * 1997-06-03 2000-04-25 Justsystem Corp. Method and apparatus for recovering the computing error, and a computer-readable recording medium for storing the program for executing the method
US6073155A (en) * 1996-08-08 2000-06-06 Fuji Xerox Co., Ltd. Floating-point accumulator
US8370226B1 (en) * 2010-04-19 2013-02-05 Intuit Inc. Technique for correcting round-off errors

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6073155A (en) * 1996-08-08 2000-06-06 Fuji Xerox Co., Ltd. Floating-point accumulator
US6055648A (en) * 1997-06-03 2000-04-25 Justsystem Corp. Method and apparatus for recovering the computing error, and a computer-readable recording medium for storing the program for executing the method
US8370226B1 (en) * 2010-04-19 2013-02-05 Intuit Inc. Technique for correcting round-off errors

Similar Documents

Publication Publication Date Title
US6687722B1 (en) High-speed/low power finite impulse response filter
JP3487903B2 (en) Arithmetic device and arithmetic method
JPH09325955A (en) Square root arithmetic circuit for sum of squares
JPH04281524A (en) Floating point arithmetic processor
JPH0833809B2 (en) Floating point display data calculation method
JPS61256436A (en) arithmetic device
JPH0519170B2 (en)
JPH0772860B2 (en) Calculation method
JPS6131488B2 (en)
CA1314995C (en) Method and apparatus for decoding reed-solomon code
JP3137131B2 (en) Floating point multiplier and multiplication method
JP3523104B2 (en) Fixed-point multiplier / adder
JPS61213926A (en) Dsp arithmetic processing system
KR920006324B1 (en) Optimization method of 2's complement code multplier
JP2508286B2 (en) Square root calculator
JP2000137701A (en) Product-sum operation error correcting method and product sum arithmetic unit
JP3136150B2 (en) Integrating circuit and method
SU662942A1 (en) Arithmetic device with conditional sums and self-checking
JP2813513B2 (en) Data conversion circuit
JPS61138332A (en) Digital operating circuit
JP3053637B2 (en) Calculation method of digital filter
JPH0828646B2 (en) Digital filter
SU783791A1 (en) Polynominal multiplying device
JPH0319583B2 (en)
JP2530916B2 (en) Arithmetic circuit