JPH0793131A - Bit reverse operation circuit - Google Patents

Bit reverse operation circuit

Info

Publication number
JPH0793131A
JPH0793131A JP5237045A JP23704593A JPH0793131A JP H0793131 A JPH0793131 A JP H0793131A JP 5237045 A JP5237045 A JP 5237045A JP 23704593 A JP23704593 A JP 23704593A JP H0793131 A JPH0793131 A JP H0793131A
Authority
JP
Japan
Prior art keywords
circuit
bit
bits
shifter
shift
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
JP5237045A
Other languages
Japanese (ja)
Inventor
Naoyuki Hatanaka
直行 畑中
Yoshinori Yoshitomi
美紀 吉富
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.)
Toshiba Corp
Original Assignee
Toshiba 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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP5237045A priority Critical patent/JPH0793131A/en
Publication of JPH0793131A publication Critical patent/JPH0793131A/en
Pending legal-status Critical Current

Links

Abstract

(57)【要約】 【目的】小回路規模で実現でき、高速で、しかも設計効
率のよいビットリバース演算回路を提供することを目的
とする。 【構成】上位(M−N)ビット処理回路、下位Nビット
処理回路加算回路からなり、下位Nビット処理回路中の
(M−N)ビット左シフト回路は、制御信号を反転した
信号を用いる第1のシフタ回路と、ある所定数のシフト
を行なう第2のシフタ回路で構成される。そして、M=
3×2n-2 (nは制御信号のビット数、Mは入力信号の
ビット数)が成り立つ場合は、第1のシフタ回路をn個
の2のべき乗のシフタ回路で、また第2のシフタを2°
のシフタ回路で実現する。
(57) [Abstract] [Purpose] An object of the present invention is to provide a bit reverse operation circuit which can be realized in a small circuit scale, is high-speed, and has a high design efficiency. [Structure] An upper (M−N) bit processing circuit and a lower N bit processing circuit adder circuit, and a (M−N) bit left shift circuit in the lower N bit processing circuit uses a signal obtained by inverting a control signal. One shifter circuit and a second shifter circuit that performs a predetermined number of shifts. And M =
If 3 × 2 n−2 (n is the number of control signal bits and M is the number of input signal bits) holds, the first shifter circuit is an n-th power of 2 shifter circuit, and the second shifter circuit is a second shifter circuit. 2 °
It is realized by the shifter circuit of.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、ビットリバース演算回
路に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a bit reverse arithmetic circuit.

【0002】[0002]

【従来の技術】従来、図2に示すようにMビットの入力
信号1に対し、n(2n ≧M)ビットの制御信号2によ
り、その制御信号が表す数値Nにしたがって、上位(M
−N)ビットはそのままで、下位Nビットがビットリバ
ースした信号を出力10するビットリバース演算回路
は、1ビットリバース回路11、2ビットリバース回路
12、・・・Mビットリバース回路13、の計M種類の
固定数ビットリバース回路と、前記制御信号が表す数値
Nにしたがってこれらの回路のうちのただ1つの回路の
出力を選択する選択回路14とから構成されており、M
が増加するとそれにともなって回路規模も大きくなって
しまうという問題があった。
2. Description of the Related Art Conventionally, as shown in FIG. 2, an n-bit (2 n ≧ M) -bit control signal 2 is applied to an M-bit input signal 1 according to a numerical value N represented by the control signal.
The bit-reverse operation circuit that outputs a signal in which the lower N bits are bit-reversed while the -N) bit remains unchanged is a 1-bit reverse circuit 11, a 2-bit reverse circuit 12, ... It is composed of a fixed number bit reverse circuit of a kind and a selection circuit 14 which selects the output of only one of these circuits according to the numerical value N represented by the control signal.
However, there is a problem that the circuit scale also increases as the number increases.

【0003】また、回路規模を小さくするために、上位
(M−N)ビット処理回路、下位Nビット処理回路およ
び加算回路とから構成されるビットリバース演算回路で
あって、その下位Nビット処理回路の中に(M−N)ビ
ットシフトを行う回路を用い、その(M−N)ビットシ
フトを行う回路に(M−N)を計算する演算回路を用い
た場合、高速化が困難であるという問題があった。
Further, in order to reduce the circuit scale, there is provided a bit reverse operation circuit composed of an upper (MN) bit processing circuit, a lower N bit processing circuit and an adding circuit, the lower N bit processing circuit thereof. It is difficult to increase the speed when a circuit for performing (M−N) bit shift is used in the above and an arithmetic circuit for calculating (M−N) is used for the circuit for performing the (M−N) bit shift. There was a problem.

【0004】[0004]

【発明が解決しようとする課題】前述のように従来の、
Mビットの入力信号に対し、n(2n ≧M)ビットの制
御信号により、その制御信号が表す数値Nにしたがっ
て、上位(M−N)ビットはそのままで、下位Nビット
がビットリバースした信号を出力するビットリバース演
算回路においては、回路規模が大きくなる、あるいは高
速化が困難であるという問題があった。
As described above, the conventional
For an M-bit input signal, an n (2 n ≧ M) -bit control signal causes the upper (M−N) bits to remain unchanged and the lower N bits to be bit-reversed according to the numerical value N represented by the control signal. In the bit reverse operation circuit that outputs the signal, there is a problem that the circuit scale becomes large or it is difficult to increase the speed.

【0005】本発明は、前記のような問題を解決するた
めに考案したものであり、小回路規模で実現でき、高速
でしかも設計効率のよいビットリバース演算回路を提供
することを目的とする。
The present invention was devised to solve the above problems, and an object of the present invention is to provide a bit reverse operation circuit which can be realized with a small circuit scale, is fast, and has a high design efficiency.

【0006】[0006]

【課題を解決するための手段】上記目的を達成するため
に、本発明のビットリバース演算回路は、上位(M−
N)ビット処理回路、下位Nビット処理回路および加算
回路とから構成され、その下位Nビット処理回路の中に
(M−N)ビットシフトを行う回路を用いる。そしてそ
の(M−N)ビットシフトを行う回路は、前記制御信号
を全ビット反転させた信号を制御入力信号とする第1の
シフタ回路と、ある所定数のシフトを行う第2のシフタ
回路とからなる。そして、MとNとの間にM=3×2
n-2 なる関係があるとき、第1のシフタ回路は20 ビッ
トシフタ回路、21 ビットシフト回路、22 ビットシフ
ト回路、・・・2n-2 ビットシフト回路および、2n-2
ビッドシフト回路の計n個の2のべき乗ビットシフト回
路から構成され、また第2のシフタ回路は20 ビットシ
フト回路からなる。
In order to achieve the above object, a bit reverse operation circuit of the present invention is a high-order (M-
An N) bit processing circuit, a lower N bit processing circuit, and an addition circuit, and a circuit for performing (MN) bit shift is used in the lower N bit processing circuit. A circuit for performing the (M−N) -bit shift includes a first shifter circuit that uses a signal obtained by inverting all the bits of the control signal as a control input signal, and a second shifter circuit that performs a predetermined number of shifts. Consists of. Then, M = 3 × 2 between M and N
When there are n-2 the relationship, the first shifter circuit 2 0 bit shifter circuit, 2 1 bit shift circuit, 2 2 bit shift circuit, · · · 2 n-2 bit shift circuit and, 2 n-2
It is composed of a total of n power of two-bit shift circuit of bids shift circuit, and the second shifter circuit is composed of 2 0 bit shift circuit.

【0007】[0007]

【作用】本発明の回路においては、上位(M−N)ビッ
ト処理回路は、Mビットの入力信号の上位(M−N)ビ
ットはそのままで下位Nビットはすべて0である信号を
出力する。また、下位Nビット処理回路は、Mビットの
入力信号の上位(M−N)ビットはすべて0で下位Nビ
ットがビットリバースした信号を出力する。そしてそれ
ら上位(M−N)ビット処理回路と下位Nビット処理回
路からの2つの出力信号を加算回路で加算する(論理和
を求める)ことで、上位(M−N)ビットはそのまま
で、下位Nビットがビットリバースした信号を得る。こ
こで下位Nビット処理回路は、以下のようにして実現さ
れる。入力されたMビットの信号は、内部の(M−N)
ビットシフトを行う回路により(M−N)ビット左シフ
トされる。ここで下位(M−N)ビットはすべて0とな
るものとする。次にその(M−N)ビット左シフトされ
た信号をMビット(全ビット)リバースする。その結果
前記のごとき、Mビットの入力信号の上位(M−N)ビ
ットはすべて0で下位Nビットがビットリバースした信
号が得られる。
In the circuit of the present invention, the high-order (M-N) bit processing circuit outputs a signal in which the high-order (M-N) bits of the M-bit input signal remain unchanged and the low-order N bits are all zero. Further, the lower N-bit processing circuit outputs a signal in which all the upper (MN) bits of the M-bit input signal are 0 and the lower N bits are bit-reversed. Then, the two output signals from the high-order (M−N) bit processing circuit and the low-order N-bit processing circuit are added by an adder circuit (the logical sum is obtained), so that the high-order (M−N) bits remain unchanged and the low-order A signal in which N bits are bit-reversed is obtained. Here, the lower N-bit processing circuit is realized as follows. The input M-bit signal is the internal (M−N)
The bit shift circuit shifts to the left by (M−N) bits. Here, it is assumed that all the lower (MN) bits are 0. Then, the signal shifted left by (M−N) bits is reversed by M bits (all bits). As a result, as described above, a signal in which the upper (M−N) bits of the M-bit input signal are all 0 and the lower N bits are bit-reversed is obtained.

【0008】さて、本発明の(M−N)ビットシフトを
行う回路は、以下のようにして実現される。いま、nビ
ットの制御信号は、その2進数値が数値Nを表すものと
する。第1のシフタ回路はその制御信号を全ビット反転
した信号を用いる。この全ビット反転した信号は1の補
数であるので、元の数値Nに対して数値(2n −1−
N)を表すことになる。ところが、その制御信号の各ビ
ットはn個の2のべき乗のビットシフト回路、すなわち
0 ビットシフト回路、21 ビットシフト回路、・・・
n-2 ビットシフト回路および2n-2 ビットシフト回路
を制御する。最後のシフト回路が2n-1 でなく2n-2
ットシフト回路であるため、前記数値(2n −1−N)
と実際に行われるシフト量とは一致しない。結果的に
は、第1のシフタ回路は、Mビットの入力信号に対し
(2n −1−N)−2n-2 ビット左シフトを行う。ここ
でMとnとの間にM=3×2n-2 なる関係があるとき、
第1のシフタ回路は、(2n −1−N)−2n-2 =M−
N−1ビット左シフトを行ったことになる。そしてその
左シフトされた信号を第2のシフタ回路によりある所定
のビット数、すなわち20 =1ビット左シフトする。こ
のようにして全体として、(M−N)ビット左シフトさ
れた信号が得られる。
The circuit for (MN) bit shifting according to the present invention is realized as follows. Now, it is assumed that the binary value of the n-bit control signal represents the numerical value N. The first shifter circuit uses a signal obtained by inverting all the bits of the control signal. Since the signal obtained by inverting all the bits is a one's complement, the numerical value (2 n -1-
N). However, the power of the bit shift circuit each bit of n 2 of the control signal, i.e. 2 0 bit shift circuit, 2 1 bit shift circuit, ...
It controls the 2 n-2 bit shift circuit and the 2 n-2 bit shift circuit. Since the last shift circuit is a 2 n- 2 bit shift circuit instead of 2 n-1 , the above numerical value (2 n -1-N)
Does not match the actual shift amount. As a result, the first shifter circuit performs (2 n -1-N) -2 n-2 bit left shift on the M-bit input signal. Here, when there is a relation of M = 3 × 2 n−2 between M and n,
The first shifter circuit has (2 n −1−N) −2 n−2 = M−
This means that N-1 bit left shift has been performed. Then, the left-shifted signal is left-shifted by a predetermined number of bits, that is, 2 0 = 1 bit by the second shifter circuit. In this way, a signal shifted to the left by (M−N) bits is obtained as a whole.

【0009】通常、第1のシフタ回路は、20 ビットシ
フト回路、21 ビットシフト回路、・・・2n-1 ビット
シフト回路で構成され、よってMビットの入力信号に対
し(2n −1−N)ビット左シフトを行う。そして、第
2のシフタ回路によりある所定のビット数、すなわち
(2n −1−M)ビット右シフトを行う。それにより全
体として(2n −1−N)−(2n −1−M)=(M−
N)ビット左シフトを実現する。しかしながらその場
合、第1のシフタ回路では、最大2n-1 ビットのシフト
回路が必要であり、また第2のシフタ回路も(2n −1
−M)ビットというシフト量の大きなシフト回路が必要
となる。一方、本発明においては、第1のシフタ回路
は、最大でもシフト量が2n-2 ビットのシフト回路で、
また第2のシフタ回路は、最小のシフト量である20
ットのシフト回路で実現でき、よって両者併せて、たっ
た(n−1)種類で(n+1)個の、しかも2のべき乗
ビットシフト回路だけで実現できるため、回路規模が小
さい、設計効率のよいビットリバース演算回路を提供で
きる。
[0009] Usually, the first shifter circuit 2 0 bit shift circuit, 2 1 bit shift circuit is constituted by · · · 2 n-1 bit shift circuit, thus the input signal of M bits (2 n - 1-N) shift left by one bit. Then, the second shifter circuit shifts to the right by a predetermined number of bits, that is, (2 n -1-M) bits. Thereby, as a whole, (2 n -1-N)-(2 n -1-M) = (M-
N) A bit left shift is realized. However, in that case, the first shifter circuit requires a shift circuit with a maximum of 2 n-1 bits, and the second shifter circuit also has a shift circuit of (2 n -1).
A shift circuit having a large shift amount of −M) bits is required. On the other hand, in the present invention, the first shifter circuit is a shift circuit having a maximum shift amount of 2 n-2 bits,
The second shifter circuit may be realized in 2 0 bit shift circuit is the minimum shift amount, thus together both only (n-1) kinds (n + 1) number of, yet a power of 2 bit shift circuit Therefore, it is possible to provide a bit reverse operation circuit having a small circuit scale and good design efficiency.

【0010】[0010]

【実施例】以下に本発明の実施例について図面を参照し
ながら説明する。図1は、本発明のビットリバース演算
回路のブロック図である。上位(M−N)ビット処理回
路3、下位Nビット処理回路4と加算(論理和)回路5
より構成されており、下位Nビット処理回路4は、反転
した制御信号2を用いるn個の2のべき乗のビットシフ
ト回路からなる第1のシフタ回路6と、20 ビットシフ
トを行う第2のシフタ回路7と、Mビットリバース回路
8とよりなる。上位(M−N)ビット処理回路3は、上
位(M−N)ビットはそのままで下位nビットはすべて
0である信号を出力する。下位Nビット処理回路4は、
Mビットの入力信号1に対し第1および第2のシフタ回
路による(M−N)ビット左シフタ回路9で(M−N)
ビット左シフトを行い、次にMビットのビットリバース
を行う。その結果、上位(M−N)ビットはすべて0で
下位Nビットがビットリバースした信号が出力される。
加算回路5でこれら2つの出力信号を加算し、Mビット
の入力信号の上位(M−N)ビットはそのままで下位N
ビットがビットリバースした出力信号10を出力する。
Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram of a bit reverse operation circuit of the present invention. Upper (MN) bit processing circuit 3, lower N bit processing circuit 4 and addition (logical sum) circuit 5
The lower N-bit processing circuit 4 includes a first shifter circuit 6 composed of n number of bit-shift circuits to the power of 2 using the inverted control signal 2 and a second shifter circuit 2 for performing 2 0 bit shift. It comprises a shifter circuit 7 and an M-bit reverse circuit 8. The upper (MN) bit processing circuit 3 outputs a signal in which the upper (MN) bits remain unchanged and the lower n bits are all 0s. The lower N-bit processing circuit 4
For the M-bit input signal 1, the (MN) bit left shifter circuit 9 by the first and second shifter circuits (MN)
Bit shift left, then bit reverse M bits. As a result, a signal in which the upper (M−N) bits are all 0 and the lower N bits are bit-reversed is output.
These two output signals are added by the adder circuit 5, and the upper (M−N) bits of the M-bit input signal remain unchanged and the lower N
The output signal 10 in which the bits are bit-reversed is output.

【0011】[0011]

【発明の効果】以上述べてきたように本発明によれば、
下位Nビット処理回路に用いる(M−N)ビットシフト
を行う回路に、制御信号を反転させた信号を入力する第
1のシフタ回路と、ある所定数のシフトを行う第2のシ
フタ回路を用いることで、従来の方式のものに比べて全
体として回路規模が小さい、ビットリバース演算回路を
実現できる。さらにMとnとの間にM=3×2n-2 なる
関係があるとき、第1のシフタ回路は、最大でもシフト
量が2n-2 ビットのシフト回路で、また第2のシフタ回
路は、最小のシフト量である20 ビットのシフト回路で
実現でき、よって両者併せて、たった(n−1)種類で
(n+1)個の、しかも2のべき乗ビットシフト回路だ
けで実現できるため、回路規模が小さい、設計効率のよ
いビットリバース演算回路を提供する。
As described above, according to the present invention,
A first shifter circuit for inputting a signal obtained by inverting a control signal and a second shifter circuit for performing a certain predetermined number of shifts are used for a circuit for (MN) bit shift used in a lower N bit processing circuit. As a result, it is possible to realize a bit reverse operation circuit whose circuit scale is smaller than that of the conventional system. Further, when there is a relationship of M = 3 × 2 n−2 between M and n, the first shifter circuit is a shift circuit having a shift amount of at most 2 n−2 bits and the second shifter circuit. may be realized in 2 0 bit shift circuit is the minimum shift amount, thus together both only (n-1) kinds of (n + 1), yet can be realized only by a power bit shift circuit 2, (EN) Provided is a bit reverse operation circuit having a small circuit size and good design efficiency.

【図面の簡単な説明】[Brief description of drawings]

【図1】 本発明の実施例を示すブロック図。FIG. 1 is a block diagram showing an embodiment of the present invention.

【図2】 従来例を示すブロック図。FIG. 2 is a block diagram showing a conventional example.

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

1…Mビット入力信号 2…nビット制御信号 3…上位(M−N)ビット処理回路 4…下位Nビット処理回路 5…加算回路 6…第1のシフタ回路 7…第2のシフタ回路 8…Mビットリバース回路 9…(M−N)ビット左シフタ回路 10…出力信号 1 ... M bit input signal 2 ... n bit control signal 3 ... Higher (MN) bit processing circuit 4 ... Lower N bit processing circuit 5 ... Adding circuit 6 ... First shifter circuit 7 ... Second shifter circuit 8 ... M-bit reverse circuit 9 ... (MN) bit left shifter circuit 10 ... Output signal

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 Mビットの入力信号に対して、n(2n
≧M)ビットの制御信号により、その制御信号が表す数
値Nにしたがって、上位(M−N)ビットはそのままで
下位Nビットのみビットリバースした信号を出力するビ
ットリバース演算回路であって、その回路は上位(M−
N)ビット処理回路、下位Nビット処理回路および加算
回路とから構成され、その下位Nビット処理回路の中に
は(M−N)ビットシフトを行う回路を用い、その(M
−N)ビットシフトを行う回路は、前記制御信号を全ビ
ット論理反転させた信号を制御入力信号とする第1のシ
フタ回路と、ある所定数のシフトを行う第2のシフタ回
路とからなる、ビットリバース演算回路において、Mと
nとの間にM=3×2n-2 なる関係があるとき、前記第
1のシフタ回路は20 ビットシフト回路、21 ビットシ
フト回路、22 ビットシフト回路、・・・2n-2 ビット
シフト回路および2n-2 ビットシフト回路の、計n個の
2のべき乗ビットシフト回路から構成され、また前記第
2のシフタ回路は20 ビットシフト回路からなることを
特徴とするビットリバース演算回路
1. For an M-bit input signal, n (2 n
A bit-reverse operation circuit that outputs a signal in which only the lower N bits are bit-reversed according to a numerical value N represented by the control signal by a control signal of ≧ M) bits and the lower N bits are output. Is higher (M-
N) bit processing circuit, lower N bit processing circuit, and adder circuit. A circuit for performing (M−N) bit shift is used in the lower N bit processing circuit.
-N) A circuit for performing a bit shift includes a first shifter circuit that uses a signal obtained by logically inverting all bits of the control signal as a control input signal, and a second shifter circuit that performs a predetermined number of shifts. In the bit reverse operation circuit, when there is a relation of M = 3 × 2 n-2 between M and n, the first shifter circuit is a 2 0 bit shift circuit, a 2 1 bit shift circuit, a 2 2 bit shift circuit. circuit, the · · · 2 n-2 bit shift circuit and 2 n-2 bit shift circuit is composed of a power bit shift circuit having a total of n 2, also the second shifter circuit from 2 0 bit shift circuit Bit reverse operation circuit characterized by
JP5237045A 1993-09-24 1993-09-24 Bit reverse operation circuit Pending JPH0793131A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP5237045A JPH0793131A (en) 1993-09-24 1993-09-24 Bit reverse operation circuit

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP5237045A JPH0793131A (en) 1993-09-24 1993-09-24 Bit reverse operation circuit

Publications (1)

Publication Number Publication Date
JPH0793131A true JPH0793131A (en) 1995-04-07

Family

ID=17009594

Family Applications (1)

Application Number Title Priority Date Filing Date
JP5237045A Pending JPH0793131A (en) 1993-09-24 1993-09-24 Bit reverse operation circuit

Country Status (1)

Country Link
JP (1) JPH0793131A (en)

Similar Documents

Publication Publication Date Title
US4953115A (en) Absolute value calculating circuit having a single adder
JPS6132437Y2 (en)
US5367477A (en) Method and apparatus for performing parallel zero detection in a data processing system
JPH07182141A (en) Arithmetic device and arithmetic method
EP0416869B1 (en) Digital adder/accumulator
JPH05224883A (en) System for converting binary number of magnitude having floating-point n-bit code into binary number indicated by two's complement of fixed-point m-bit
US5177703A (en) Division circuit using higher radices
US4977534A (en) Operation circuit based on floating-point representation with selective bypass for increasing processing speed
JPH09222991A (en) Adding method and adder
US6269385B1 (en) Apparatus and method for performing rounding and addition in parallel in floating point multiplier
JPH0346024A (en) Floating point computing element
JP2509279B2 (en) Floating point number-fixed point number converter
JPH0793131A (en) Bit reverse operation circuit
JP2645422B2 (en) Floating point processor
CN114895868B (en) Division operation unit and divider based on two-bit quotient calculation
JP2734438B2 (en) Multiplier
JPH09185493A (en) Integrated circuit for adder
KR100203742B1 (en) Adder using multiplex
US20040167949A1 (en) Data saturation manager and corresponding method
JP2907276B2 (en) Arithmetic processing unit
US4141077A (en) Method for dividing two numbers and device for effecting same
JPH05224888A (en) Variable point position type data multiplication circuit
KR100265358B1 (en) Speedy shift apparatus
JP3539077B2 (en) Division method by parallel operation method
JPS63115229A (en) Element shift system