JP7006808B2 - 演算処理装置および演算処理装置の制御方法 - Google Patents
演算処理装置および演算処理装置の制御方法 Download PDFInfo
- Publication number
- JP7006808B2 JP7006808B2 JP2020554661A JP2020554661A JP7006808B2 JP 7006808 B2 JP7006808 B2 JP 7006808B2 JP 2020554661 A JP2020554661 A JP 2020554661A JP 2020554661 A JP2020554661 A JP 2020554661A JP 7006808 B2 JP7006808 B2 JP 7006808B2
- Authority
- JP
- Japan
- Prior art keywords
- arithmetic
- circuit
- arithmetic processing
- calculation
- log
- 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.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F7/00—Methods or arrangements for processing data by operating upon the order or content of the data handled
- G06F7/38—Methods or arrangements for performing computations using exclusively denominational number representation, e.g. using binary, ternary, decimal representation
- G06F7/48—Methods 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/544—Methods 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 for evaluating functions by calculation
- G06F7/556—Logarithmic or exponential functions
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Computational Mathematics (AREA)
- Mathematical Analysis (AREA)
- Pure & Applied Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computing Systems (AREA)
- Mathematical Optimization (AREA)
- General Engineering & Computer Science (AREA)
- Complex Calculations (AREA)
- Advance Control (AREA)
Description
この図8に示す演算処理回路500は、レジスタ501~504,判定回路505,CSA(Carry-Save Adder:桁上げ保存加算器)506,507,Log Table回路508,右シフト回路(RSFT)509,510および演算回路511~514を備える。
Lはべき数の空間の変数であり、Eは指数の空間の変数である。また、iは演算の繰り返し回数である。
Li+1= Li - log(1 + n × 2^-2i) ・・・(1)
Ei+1= Ei × (1 + n × 2^-2i)
=Ei+ Ei × n × 2^-2i ・・・(2)
Lは対数の空間の変数であり、Eは真数の空間の変数である。またiは繰り返し演算の回数である。
指数演算においては、例えば、演算1回で商2bitを求めるradix4のSTL(Sequential Table Lookup)法を用いてもよい。
例えば、xを入力とし、exp(x)を求める。
Lはべき数の空間の変数であり、Eは指数の空間の変数である。また、iは演算の繰り返し回数である。
対数演算にSTL法を用いてもよい。
例えば、xを入力とし、log(x)を求める。
図1に示す演算処理回路1は、レジスタ101~104,判定回路105,CSA107,114,Log Table回路106,右シフト回路(RSFT2)108,109および演算回路110~113を備える。
本実施形態においては、i≦kのときには1サイクルあたりに求めるビット数(第1数)は1であり、i>kのときには1サイクルあたりに求めるビット数(第2数)は2である。
上述の如く構成された実施形態の一例としての演算処理回路1の処理の概要を、図5に示すフローチャート(ステップA1~A15)に従って説明する。
このように、実施形態の一例としての演算処理回路1によれば、演算の繰り返し回数iが閾値k以下の時点において、1サイクル当たりに求めるビット数を少なくするとともに、演算の繰り返し回数iが閾値kよりも多い時点において、1サイクル当たりに求めるビット数を多くする。これにより、指数演算のEiをexp(x)に、対数演算のLiをlog(x)にそれぞれ収束させることができる。
図7は上述した実施形態の一例としての演算処理回路1を、例えば、ディープラーニング等の用途のプロセッサに実装する構成例を示す図である。
10 制御ユニット
11 メモリ
12 プロセッサ
101~104 レジスタ
105 判定回路
107,114 CSA
106 Log Table回路
108,109 右シフト回路
110~113 演算回路
1081 セレクタ
Claims (5)
- 指数演算または対数演算を行なう演算回路と、
前記演算回路による演算繰り返し回数が閾値以下の場合に、1サイクル当たりに前記演算回路が求めるビット数を第1数に設定し、前記演算繰り返し回数が前記閾値よりも多い場合に、1サイクル当たりに前記演算回路が求めるビット数を、前記第1数よりも多い第2数に設定する設定部と
を備えること特徴とする、演算処理装置。 - 前記設定部が、処理対象データのビット列に対して右シフトを行なう右シフト回路であって、
前記右シフト回路が、前記処理対象データに対して、前記演算繰り返し回数に応じた数のビットシフトを行なう
ことを特徴とする、請求項1に記載の演算処理装置。 - 前記演算回路が、指数演算を実施する指数演算回路であり、
演算繰り返し回数(i)が閾値以下の場合に、Li+1 = Li - log(1 + n × 2^-i)を演算し、
前記演算繰り返し回数(i)が前記閾値よりも多い場合に、Li+1 = Li- log(1 + n × 2^-(2i-k))を演算する
ことを特徴とする、請求項1または2記載の演算処理装置。 - 前記演算回路が、対数演算を実施する指数演算回路であり、
演算繰り返し回数(i)が閾値以下の場合に、Ei+1 = Ei + Ei× n × 2^-iを演算し、
前記演算繰り返し回数(i)が前記閾値よりも多い場合に、Ei+1 = Ei+ Ei × n × 2^-(2i-k)を演算する
ことを特徴とする、請求項1~3のいずれか1項に記載の演算処理装置。 - 指数演算または対数演算を行なう演算回路を備える演算処理装置において、
前記演算回路による演算繰り返し回数を確認する処理と、
前記演算回路による前記演算繰り返し回数が閾値以下の場合に、1サイクル当たりに前記演算回路が求めるビット数を第1数に設定し、前記演算繰り返し回数が前記閾値よりも多い場合に、1サイクル当たりに前記演算回路が求めるビット数を、前記第1数よりも多い第2数に設定する処理
とを備えること特徴とする、演算処理装置の制御方法。
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2018/040476 WO2020090025A1 (ja) | 2018-10-31 | 2018-10-31 | 演算処理装置および演算処理装置の制御方法 |
Publications (2)
Publication Number | Publication Date |
---|---|
JPWO2020090025A1 JPWO2020090025A1 (ja) | 2021-09-24 |
JP7006808B2 true JP7006808B2 (ja) | 2022-01-24 |
Family
ID=70462894
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2020554661A Active JP7006808B2 (ja) | 2018-10-31 | 2018-10-31 | 演算処理装置および演算処理装置の制御方法 |
Country Status (2)
Country | Link |
---|---|
JP (1) | JP7006808B2 (ja) |
WO (1) | WO2020090025A1 (ja) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113721886A (zh) * | 2020-05-25 | 2021-11-30 | 瑞昱半导体股份有限公司 | 对数计算方法及对数计算电路 |
Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009276990A (ja) | 2008-05-14 | 2009-11-26 | Sharp Corp | 演算装置およびその演算方法、信号処理装置、演算装置制御プログラム、並びに該プログラムを記録した記録媒体 |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2822399B2 (ja) * | 1988-10-28 | 1998-11-11 | 日本電気株式会社 | 対数関数演算装置 |
JP3110288B2 (ja) * | 1995-07-21 | 2000-11-20 | 日本電気株式会社 | 指数対数変換回路 |
-
2018
- 2018-10-31 WO PCT/JP2018/040476 patent/WO2020090025A1/ja active Application Filing
- 2018-10-31 JP JP2020554661A patent/JP7006808B2/ja active Active
Patent Citations (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2009276990A (ja) | 2008-05-14 | 2009-11-26 | Sharp Corp | 演算装置およびその演算方法、信号処理装置、演算装置制御プログラム、並びに該プログラムを記録した記録媒体 |
Also Published As
Publication number | Publication date |
---|---|
WO2020090025A1 (ja) | 2020-05-07 |
JPWO2020090025A1 (ja) | 2021-09-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP6540725B2 (ja) | 演算処理装置、方法、およびプログラム | |
US8271571B2 (en) | Microprocessor | |
JPWO2019168084A1 (ja) | 推論装置、畳み込み演算実行方法及びプログラム | |
JP6882281B2 (ja) | ベクトルの処理のためのレーン位置情報 | |
JP7096828B2 (ja) | 入力オペランド値を処理するための装置及び方法 | |
CN110955406A (zh) | 浮点动态范围扩展 | |
US20210081173A1 (en) | Concurrent multi-bit adder | |
JP2019139338A (ja) | 情報処理装置、情報処理方法、およびプログラム | |
US20030212723A1 (en) | Computer methods of vector operation for reducing computation time | |
KR100744216B1 (ko) | 계산 장치 및 방법과 컴퓨터 프로그램 저장 매체 | |
JP7006808B2 (ja) | 演算処理装置および演算処理装置の制御方法 | |
TWI235328B (en) | Logic network and methods of computing | |
JPH0317132B2 (ja) | ||
US9703525B2 (en) | Partially and fully parallel normaliser | |
US9612800B2 (en) | Implementing a square root operation in a computer system | |
JPH0234054B2 (ja) | ||
US7016927B2 (en) | Method and apparatus for modular multiplication | |
JP7120320B2 (ja) | 演算処理装置および演算処理装置の制御方法 | |
JP7131627B2 (ja) | 演算処理装置 | |
Maxfield | An introduction to different rounding algorithms | |
CN116149600B (zh) | 多常数乘法器的逻辑电路设置方法、装置、设备及介质 | |
JP4399280B2 (ja) | 剰余装置、剰余方法、プログラム及び記録媒体 | |
KR101980448B1 (ko) | Rsa 알고리즘 용 몽고메리 알고리즘 파라미터 계산 방법 | |
JP7078129B2 (ja) | 演算処理装置及び演算処理装置の制御方法 | |
JP7120885B2 (ja) | 半導体装置、および除算方法 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20210311 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20210311 |
|
TRDD | Decision of grant or rejection written | ||
A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 Effective date: 20211207 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20211220 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 7006808 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |