JPH07302191A - Microprocessor and data conversion method thereof - Google Patents
Microprocessor and data conversion method thereofInfo
- Publication number
- JPH07302191A JPH07302191A JP9321494A JP9321494A JPH07302191A JP H07302191 A JPH07302191 A JP H07302191A JP 9321494 A JP9321494 A JP 9321494A JP 9321494 A JP9321494 A JP 9321494A JP H07302191 A JPH07302191 A JP H07302191A
- Authority
- JP
- Japan
- Prior art keywords
- general
- data
- microprocessor
- register
- purpose registers
- 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.)
- Withdrawn
Links
Landscapes
- Controls And Circuits For Display Device (AREA)
Abstract
(57)【要約】
【目的】 フォントデータや画像データなどの行・列方
向のデータ相互間のシフト変換処理を高速に実行できる
マイクロプロセッサを提供する。
【構成】 文字や図形を表現するフォントデータまたは
画像データを処理して印字するプリンタに用いられるマ
イクロプロセッサであって、バス・インタフェース、命
令デコーダ、制御部、演算部、レジスタおよびプログラ
ム・カウンタなどから構成されている。このレジスタと
して、自由に使用できる汎用レジスタ0〜7(51)を
持ち、この汎用レジスタ51の最上位ビットから同時に
発生した桁あふれビットの情報を同時に格納するキャリ
レジスタ52が内蔵されている。そして、汎用レジスタ
51の情報が複数汎用レジスタ同時左シフト命令により
1回で同時にシフト変換処理され、このときに発生した
桁あふれビットの情報がキャリレジスタ52に同時に格
納されるようになっている。
(57) [Abstract] [Purpose] To provide a microprocessor capable of performing shift conversion processing between row and column direction data such as font data and image data at high speed. [Composition] A microprocessor used in a printer for processing and printing font data or image data representing characters and figures, including a bus interface, an instruction decoder, a control unit, an arithmetic unit, a register and a program counter. It is configured. As this register, general-purpose registers 0 to 7 (51) that can be freely used are provided, and a carry register 52 that stores the information of the overflow bit simultaneously generated from the most significant bit of the general-purpose register 51 is built-in. The information in the general-purpose register 51 is simultaneously subjected to shift conversion processing once by a plurality of general-purpose register simultaneous left shift instructions, and the overflow register information generated at this time is simultaneously stored in the carry register 52.
Description
【0001】[0001]
【産業上の利用分野】本発明は、マイクロプロセッサに
関し、特にメモリ上の“1”、“0”の情報により対象
とする文字や図形を表現するプリンタやディスプレイな
どにおいて、フォントデータや画像データなどの行・列
配列のデータ相互間におけるシフト変換処理の高速化が
可能とされるマイクロプロセッサおよびそのデータ変換
方法に適用して有効な技術に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a microprocessor, and more particularly to a printer, a display, etc. which expresses a target character or figure based on "1" or "0" information in a memory, font data, image data, etc. The present invention relates to a microprocessor that is capable of speeding up shift conversion processing between row and column array data and a technique effectively applied to the data conversion method thereof.
【0002】[0002]
【従来の技術】一般的に、プリンタのフォントデータ、
たとえば“R”の文字のドットフォントデータは、たと
えば図4(a) に示すような100番地から107番地ま
での8ビットデータ長のデータ領域を持つメモリデータ
を用い、このメモリ上の“1”、“0”の情報により対
象とする“R”のフォントパターンは図4(b) のように
8×8ビットで構成されている。2. Description of the Related Art Generally, printer font data,
For example, the dot font data of the character "R" uses memory data having a data area of 8-bit data length from address 100 to address 107 as shown in FIG. , "0", the target "R" font pattern is composed of 8 × 8 bits as shown in FIG. 4 (b).
【0003】ところで、プリンタでは、このメモリデー
タのフォントを90゜回転させて横向きに印字すること
があり、その場合にはフォントデータを90゜変換する
必要がある。たとえば、マイクロプロセッサによる変換
は、メモリと同じ8ビット長の8個の汎用レジスタ0〜
7を用いて図5に示すような手順で行われており、その
変換手順を以下において順に説明する。By the way, in a printer, the font of the memory data may be rotated 90 ° and printed in a horizontal direction. In that case, it is necessary to convert the font data by 90 °. For example, conversion by a microprocessor is performed by eight general-purpose registers 0 to 8 having the same 8-bit length as the memory.
The procedure is as shown in FIG. 5 using the No. 7, and the conversion procedure will be described below in order.
【0004】(1).まず、のステップで、メモリの10
0〜107番地のデータをマイクロプロセッサ内の汎用
レジスタ0〜7にロードする。(1). First, in the step of
Data at addresses 0 to 107 are loaded into general purpose registers 0 to 7 in the microprocessor.
【0005】(2).そして、のステップで、左シフト命
令によりたとえば汎用レジスタ0内のデータを左へ1ビ
ットシフトさせる。その結果、汎用レジスタ0の最上位
ビットから発生した桁あふれビット(キャリ)はキャリ
フラグに格納される(図においては、汎用レジスタ7の
5段目のシフト動作を示している)。In step (2)., The left shift instruction shifts the data in the general-purpose register 0 to the left by 1 bit, for example. As a result, the overflow bit (carry) generated from the most significant bit of the general register 0 is stored in the carry flag (in the figure, the shift operation of the fifth stage of the general register 7 is shown).
【0006】(3).さらに、のステップで、命令により
汎用レジスタ8の内容を右へ1ビットシフトさせる。そ
の時、同時にキャリフラグの内容が汎用レジスタ8の最
上位ビットに格納される。(3) In the step (3), the contents of the general-purpose register 8 are shifted to the right by 1 bit by the instruction. At that time, the contents of the carry flag are simultaneously stored in the most significant bit of the general register 8.
【0007】(4).同様に、汎用レジスタ1〜7について
も、のステップを繰り返す。(4). Similarly, for general-purpose registers 1 to 7, the steps of are repeated.
【0008】(5).続いて、のステップで、命令により
汎用レジスタ8のバイトデータをメモリへストアする。
これにより、汎用レジスタ0〜7のそれぞれの最上位ビ
ットのデータがメモリの100番地に格納される。(5) Then, in step, the byte data of the general-purpose register 8 is stored in the memory by an instruction.
As a result, the most significant bit data of each of the general-purpose registers 0 to 7 is stored in the address 100 of the memory.
【0009】(6).同様に、2段目以降のビットから最下
位ビットまで〜のステップを繰り返し、汎用レジス
タ0〜7内にロードされたフォントデータ、すなわち最
上位ビットから最下位ビットまでの全てのデータがキャ
リフラグを介してメモリ上にストアされるまで続ける。(6) Similarly, the steps from the second and subsequent bits to the least significant bit are repeated to load the font data loaded in the general-purpose registers 0 to 7, that is, the most significant bit to the least significant bit. Continue until all data is stored in memory via the carry flag.
【0010】以上の一連の処理を行うことで、メモリ上
の“1”、“0”の情報による正しい向きの“R”の文
字のドットフォントデータを90゜シフト回転させて、
横向きへの変換を実現させることができる。By performing the above series of processing, the dot font data of the character of "R" in the correct direction according to the information of "1" and "0" on the memory is rotated by 90 ° and rotated.
A horizontal conversion can be realized.
【0011】[0011]
【発明が解決しようとする課題】ところが、前記のよう
な技術においては、マイクロプロセッサを用いたフォン
トデータの90゜変換の例のように、〜のステッ
プ、特に、のステップを繰り返す同一処理の反復が
多く、その結果、マイクロプロセッサによる変換処理の
高速処理化が妨げられている。However, in the above-mentioned technique, like the example of 90 ° conversion of font data using a microprocessor, the steps (1) to (3), in particular, the same step is repeated. As a result, high speed conversion processing by the microprocessor is hindered.
【0012】そこで、本発明者は、反復処理を行わなけ
ればならない要因について考え、次の2点の課題を解決
することにより、フォントデータの90゜回転などのシ
フト変換処理の高速化が実現可能とされることを見い出
した。Therefore, the present inventor considers the factors that must be iteratively processed, and solves the following two problems to realize a high speed shift conversion process such as 90 ° rotation of font data. I found out that.
【0013】すなわち、第1に、汎用レジスタを複数内
蔵していても、従来のシフト命令では同時には単一の汎
用レジスタに対してしか命令を実行できず、また第2
に、汎用レジスタからのキャリを格納するキャリフラグ
が1ビット分しか内蔵していない、という点を解決する
必要がある。That is, first, even if a plurality of general-purpose registers are built-in, the conventional shift instruction can execute the instruction only to a single general-purpose register at the same time.
In addition, it is necessary to solve the problem that the carry flag for storing the carry from the general-purpose register is built in for only one bit.
【0014】そこで、本発明の目的は、上記の2点の課
題を解決し、単一命令による複数の汎用レジスタの同時
シフト動作機能と、この同時シフト動作における桁あふ
れビットのキャリレジスタとを備えることによってフォ
ントデータや画像データなどの行・列配列のデータ相互
間のシフト変換処理を高速に実行させることができるマ
イクロプロセッサおよびそのデータ変換方法を提供する
ことにある。Therefore, an object of the present invention is to solve the above two problems, and to provide a simultaneous shift operation function for a plurality of general-purpose registers by a single instruction and a carry register for overflow bits in this simultaneous shift operation. Accordingly, it is an object of the present invention to provide a microprocessor and a data conversion method thereof that can perform shift conversion processing between row and column array data such as font data and image data at high speed.
【0015】本発明の前記ならびにその他の目的と新規
な特徴は、本明細書の記述および添付図面から明らかに
なるであろう。The above and other objects and novel features of the present invention will be apparent from the description of this specification and the accompanying drawings.
【0016】[0016]
【課題を解決するための手段】本願において開示される
発明のうち、代表的なものの概要を簡単に説明すれば、
以下のとおりである。Among the inventions disclosed in the present application, a brief description will be given to the outline of typical ones.
It is as follows.
【0017】すなわち、本発明のマイクロプロセッサ
は、少なくとも複数の汎用レジスタと、演算部および制
御部とを内蔵し、命令を解読して演算、制御動作を実行
するマイクロプロセッサであって、複数の汎用レジスタ
の情報を同時にシフト動作可能な単一命令を有するもの
である。That is, the microprocessor of the present invention is a microprocessor which incorporates at least a plurality of general-purpose registers, an arithmetic unit and a control unit, decodes an instruction, and executes an arithmetic operation and a control operation. It has a single instruction capable of simultaneously shifting register information.
【0018】この場合に、前記複数の汎用レジスタの最
上位ビットまたは最下位ビットから同時に発生した桁あ
ふれビットの情報を同時に格納するキャリレジスタを内
蔵するようにしたものである。In this case, a carry register for simultaneously storing information of overflow bits simultaneously generated from the most significant bit or the least significant bit of the plurality of general purpose registers is incorporated.
【0019】特に、前記マイクロプロセッサを、文字や
図形を表現するフォントデータまたは画像データを処理
するマイクロコンピュータに用いたり、あるいはフォン
トデータまたは画像データを処理して印字または表示す
るプリンタまたはディスプレイに用いるようにしたもの
である。In particular, the microprocessor may be used in a microcomputer for processing font data or image data representing characters or figures, or for a printer or display for processing or printing font data or image data. It is the one.
【0020】また、本発明のマイクロプロセッサのデー
タ変換方法は、メモリデータを複数の汎用レジスタにロ
ードした後、この複数の汎用レジスタのデータを単一命
令により同時にシフトさせ、その結果発生した桁あふれ
ビットのデータをキャリレジスタに同時に格納し、その
後キャリレジスタのデータをメモリにストアして行配列
または列配列に変換するものである。Further, according to the data conversion method of the microprocessor of the present invention, after the memory data is loaded into the plurality of general-purpose registers, the data of the plurality of general-purpose registers are simultaneously shifted by a single instruction, and the overflow caused as a result is caused. Bit data is simultaneously stored in a carry register, and then the carry register data is stored in a memory and converted into a row array or a column array.
【0021】[0021]
【作用】前記したマイクロプロセッサおよびそのデータ
変換方法によれば、複数の汎用レジスタの情報を同時に
シフト動作可能な単一命令を有し、さらに桁あふれビッ
トの情報を同時に格納するキャリレジスタを内蔵するこ
とにより、この単一命令で複数の汎用レジスタの情報を
キャリレジスタを介して同時にシフトさせることができ
る。According to the above-described microprocessor and data conversion method thereof, a carry register having a single instruction capable of simultaneously shifting the information of a plurality of general-purpose registers and further storing information of overflow bits is built-in. As a result, the information of a plurality of general-purpose registers can be simultaneously shifted through the carry register with this single instruction.
【0022】すなわち、マイクロプロセッサに内蔵され
た複数の汎用レジスタを単一命令で同時にシフト動作可
能な機能を実現し、さらにシフト動作によってそれぞれ
の汎用レジスタから同時に発生したキャリを一度に格納
できる機能を実現することにより達成される。That is, a function of simultaneously shifting a plurality of general-purpose registers incorporated in the microprocessor by a single instruction is realized, and further, a function of simultaneously storing the carry generated from each general-purpose register by the shift operation is provided. It is achieved by realizing.
【0023】これにより、単一命令による複数の汎用レ
ジスタの同時シフト動作によって処理の高速化を図るこ
とができ、また汎用レジスタのシフト命令を反復する必
要がないので、ソフトウェアの負担を軽減することがで
きるマイクロプロセッサを得ることができる。Thus, the processing speed can be increased by the simultaneous shift operation of a plurality of general-purpose registers by a single instruction, and the shift instruction of the general-purpose registers need not be repeated, so that the load on the software can be reduced. It is possible to obtain a microprocessor capable of
【0024】特に、このマイクロプロセッサをマイクロ
コンピュータに用いることにより、フォントデータまた
は画像データを単一命令によるシフト動作によって行配
列または列配列に相互に短時間で変換することができ
る。In particular, by using this microprocessor in a microcomputer, font data or image data can be mutually converted into a row arrangement or a column arrangement by a shift operation by a single instruction in a short time.
【0025】あるいは、プリンタまたはディスプレイに
用いた場合には、フォントデータまたは画像データを単
一命令によるシフト動作により短時間で90゜回転変換
させ、高速で水平方向または垂直方向に印字または表示
させることができる。Alternatively, when used for a printer or a display, the font data or the image data is rotated 90 ° in a short time by a shift operation by a single command, and is printed or displayed at a high speed in the horizontal or vertical direction. You can
【0026】[0026]
【実施例】以下、本発明の実施例を図面に基づいて詳細
に説明する。Embodiments of the present invention will now be described in detail with reference to the drawings.
【0027】図1は本発明の一実施例であるマイクロプ
ロセッサを示すブロック図、図2は本実施例のマイクロ
プロセッサ内の汎用レジスタを示す構成図、図3は本実
施例のマイクロプロセッサによるフォントデータの90
゜変換処理手順を示す説明図である。FIG. 1 is a block diagram showing a microprocessor according to an embodiment of the present invention, FIG. 2 is a block diagram showing a general-purpose register in the microprocessor of this embodiment, and FIG. 3 is a font by the microprocessor of this embodiment. 90 of the data
It is explanatory drawing which shows the (degree) conversion processing procedure.
【0028】まず、図1により本実施例のマイクロプロ
セッサの構成を説明する。First, the configuration of the microprocessor of this embodiment will be described with reference to FIG.
【0029】本実施例のマイクロプロセッサは、たとえ
ば文字や図形を表現するフォントデータを処理して印字
するプリンタに用いられ、外部との入出力を取り持つバ
ス・インタフェース1と、命令を解読する命令デコーダ
2と、全体の制御を行う制御部3と、演算を行う演算部
(ALU:Arithmetic Logic Unit )4と、データを一
時的に記憶するレジスタ5と、アドレス値を計数するプ
ログラム・カウンタ6などから構成され、たとえば1個
のLSIに集積されている。The microprocessor of this embodiment is used in a printer for processing and printing font data representing, for example, characters and figures, and has a bus interface 1 for input / output with the outside and an instruction decoder for decoding instructions. 2, a control unit 3 that performs overall control, an arithmetic unit (ALU: Arithmetic Logic Unit) 4 that performs arithmetic operations, a register 5 that temporarily stores data, a program counter 6 that counts address values, and the like. It is configured and integrated in, for example, one LSI.
【0030】バス・インタフェース1では、外部のメモ
リ7との間で命令の取り込みや、データの取り込み/書
き出しが行われ、この取り込まれた命令の機能は命令デ
コーダ2により解読されて制御部3に送られる。In the bus interface 1, instructions are fetched and data is fetched / written out from / to the external memory 7. The functions of the fetched instructions are decoded by the instruction decoder 2 and the control section 3 receives them. Sent.
【0031】制御部3では、解読された結果をもとに適
切なタイミングが作り出され、マイクロプロセッサの各
部に必要な信号が送り出され、この信号の一部は演算部
4に送られて演算が行われ、この演算結果などのデータ
はレジスタ5に一時的に記憶される。In the control section 3, appropriate timing is created based on the decoded result, necessary signals are sent to each section of the microprocessor, and a part of this signal is sent to the calculation section 4 for calculation. The data such as the calculation result is temporarily stored in the register 5.
【0032】この一連の動作は、外部のメモリ7内のカ
ウンタで示されるアドレスから命令を取り出し、マイク
ロプロセッサ内において、解読、実行後にプログラム・
カウンタ6の値を更新して、再び命令の取り出しから繰
り返して実行される。In this series of operations, an instruction is fetched from the address indicated by the counter in the external memory 7, and the program is executed after decoding and execution in the microprocessor.
The value of the counter 6 is updated, and the instruction is fetched again to be repeatedly executed.
【0033】また、本実施例においては、レジスタ5と
して自由に使用できる汎用レジスタを持ち、たとえば図
2に示すように、汎用レジスタ0〜7(51)と、この
汎用レジスタ51の最上位ビットから同時に発生した桁
あふれビットの情報を同時に格納するキャリレジスタ5
2とがマイクロプロセッサに内蔵されている。Further, in the present embodiment, there is provided a general-purpose register which can be freely used as the register 5. For example, as shown in FIG. 2, from the general-purpose registers 0 to 7 (51) and the most significant bit of the general-purpose register 51, Carry register 5 that simultaneously stores the information of overflow bits that occurred at the same time
And 2 are built into the microprocessor.
【0034】そして、この汎用レジスタ51およびキャ
リレジスタ52を用い、汎用レジスタ51の情報が単一
命令、たとえばシフト命令の組み合せによる複数汎用レ
ジスタ同時左シフト命令により1回で同時にシフト変換
処理され、このときに発生した桁あふれビットの情報が
キャリレジスタ52に同時に格納されるようになってい
る。Then, using the general-purpose register 51 and the carry register 52, the information of the general-purpose register 51 is simultaneously subjected to shift conversion processing once by a single instruction, for example, a plurality of general-purpose register simultaneous left shift instructions by a combination of shift instructions. Information of the overflow bit generated at any time is simultaneously stored in the carry register 52.
【0035】次に、本実施例の作用について、マイクロ
プロセッサによるシフト変換処理の処理手順を図3に基
づいて説明する。Next, with respect to the operation of this embodiment, the processing procedure of the shift conversion processing by the microprocessor will be described with reference to FIG.
【0036】(1).まず、のステップで、メモリ7の1
00〜107番地のデータをマイクロプロセッサ内の汎
用レジスタ0〜7(51)にロードする。(1). First, in the step of 1,
The data at addresses 00 to 107 are loaded into general purpose registers 0 to 7 (51) in the microprocessor.
【0037】(2).さらに、のステップで、複数汎用レ
ジスタ同時左シフト命令を実行し、汎用レジスタ0〜7
(51)のデータを同時に左へ1ビットシフトさせる。
その結果、汎用レジスタ0〜7(51)の最上位ビット
から発生した桁あふれビット(キャリ)は1回の処理で
キャリレジスタ52に格納される(図においては、5段
目のビットのシフト動作を示している)。(2) Further, in the step of (1), a general-purpose register simultaneous left shift instruction is executed, and general-purpose registers 0 to 7
The data of (51) is simultaneously shifted to the left by 1 bit.
As a result, the overflow bit (carry) generated from the most significant bit of the general-purpose registers 0 to 7 (51) is stored in the carry register 52 in one processing (in the figure, the shift operation of the fifth stage bit). Is shown).
【0038】(3).そして、のステップで、命令により
キャリレジスタ52内のバイトデータをメモリ7へスト
アする。これにより、汎用レジスタ0〜7(51)のそ
れぞれの最上位ビットのデータがメモリ7の100番地
に格納される(図においては、5段目のビットの104
番地への格納を示している)。In step (3)., The byte data in the carry register 52 is stored in the memory 7 by an instruction. As a result, the data of the most significant bit of each of the general-purpose registers 0 to 7 (51) is stored in the address 100 of the memory 7 (in the figure, the bit 104 of the fifth stage is 104).
Shows the storage in the address).
【0039】(4).同様に、2段目以降のビットから最下
位ビットまで、のステップを繰り返し、汎用レジス
タ0〜7(51)内にロードされたフォントデータ、す
なわち最上位ビットから最下位ビットまでの全てのデー
タがキャリレジスタ52を介してメモリ7上にストアさ
れるまで続ける。(4) Similarly, the steps from the second and subsequent bits to the least significant bit are repeated to load the font data loaded in the general-purpose registers 0 to 7 (51), that is, the most significant bit to the least significant bit. It continues until all the data up to the bit is stored in the memory 7 via the carry register 52.
【0040】以上の一連の処理を行うことで、メモリ7
上の“1”、“0”の情報による正しい向きの“R”の
文字のドットフォントデータを90゜シフト回転させ
て、横向きの文字への変換を変換終了後のメモリ7上に
高速で実現させることができる。By performing the above series of processing, the memory 7
Shift the dot font data of the character "R" in the correct direction based on the information of "1" and "0" above by 90 degrees and realize the conversion to the character in the horizontal direction on the memory 7 at high speed after the conversion is completed. Can be made.
【0041】従って、本実施例のマイクロプロセッサに
よれば、汎用レジスタ51からの桁あふれビットの情報
を格納するキャリレジスタ52を内蔵し、このキャリレ
ジスタ52を介した複数汎用レジスタ同時左シフト命令
によるシフト動作により、汎用レジスタ51の情報を同
時にシフト動作させることができるので、従来のような
汎用レジスタ51のシフト命令を反復する必要がないの
で、シフト動作を高速に処理することができる上に、こ
の場合のソフトウェアの負担を軽減することができる。Therefore, according to the microprocessor of this embodiment, the carry register 52 for storing the information of the overflow bit from the general register 51 is built in, and a plurality of general register simultaneous left shift instructions are executed via the carry register 52. Since the information in the general-purpose register 51 can be simultaneously shifted by the shift operation, it is not necessary to repeat the conventional shift instruction of the general-purpose register 51. Therefore, the shift operation can be processed at high speed. In this case, the load on the software can be reduced.
【0042】特に、本実施例のようにマイクロプロセッ
サをプリンタに用いた場合には、フォントデータを複数
汎用レジスタ同時左シフト命令により短時間で90゜シ
フト回転させ、水平方向から垂直方向、または垂直方向
から水平方向への変換による印字を高速で行うことがで
きる。In particular, when the microprocessor is used in the printer as in this embodiment, the font data is rotated by 90 ° in a short time by the simultaneous left shift command of a plurality of general-purpose registers, and then rotated from the horizontal direction to the vertical direction or the vertical direction. Printing can be performed at high speed by converting from the horizontal direction to the horizontal direction.
【0043】以上、本発明者によってなされた発明を実
施例に基づき具体的に説明したが、本発明は前記実施例
に限定されるものではなく、その要旨を逸脱しない範囲
で種々変更可能であることはいうまでもない。Although the invention made by the present inventor has been specifically described based on the embodiments, the present invention is not limited to the embodiments and various modifications can be made without departing from the scope of the invention. Needless to say.
【0044】たとえば、本実施例のマイクロプロセッサ
については、汎用レジスタ51、キャリレジスタ52、
メモリ7はデータ長を8ビットとした場合について説明
したが、本発明は前記実施例のように8ビットのデータ
長に限定されるものではなく、16ビット、32ビット
などの他のビット長についても広く適用可能である。For example, in the microprocessor of this embodiment, a general register 51, a carry register 52,
Although the memory 7 has been described as having a data length of 8 bits, the present invention is not limited to the data length of 8 bits as in the above embodiment, and other bit lengths such as 16 bits and 32 bits are possible. Is also widely applicable.
【0045】また、本実施例では、8×8ビットのフォ
ントデータを例に説明したが、たとえば画像データなど
の“1”、“0”により対象とする文字や図形を表現す
るデータであれば、他のデータについても適用可能であ
ることはいうまでもない。In the present embodiment, 8 × 8 bit font data has been described as an example, but if it is data representing a target character or figure by “1” or “0” such as image data, for example. Needless to say, it is applicable to other data.
【0046】さらに、汎用レジスタ51の桁あふれビッ
トは、最上位ビットからに限られるものではなく、最下
位ビットから発生させることも可能であり、この場合に
も最下位ビットから同時に発生した桁あふれビットの情
報は同時にキャリレジスタに格納される。Furthermore, the overflow bit of the general-purpose register 51 is not limited to the most significant bit, but it can be generated from the least significant bit. In this case as well, the overflow bit generated simultaneously from the least significant bit. Bit information is simultaneously stored in the carry register.
【0047】以上の説明では、主として本発明者によっ
てなされた発明をその利用分野であるプリンタに用いら
れるマイクロプロセッサに適用した場合について説明し
たが、これに限定されるものではなく、文字や図形を表
現するフォントデータまたは画像データを処理するマイ
クロコンピュータ、さらにフォントデータまたは画像デ
ータを処理して表示するディスプレイなどの他の装置に
用いる場合についても広く適用可能である。In the above description, the case where the invention mainly made by the present inventor is applied to a microprocessor used in a printer which is a field of application of the invention has been described. However, the invention is not limited to this. The present invention is also widely applicable to the case of using in other devices such as a microcomputer that processes font data or image data to be expressed, and a display that processes and displays font data or image data.
【0048】たとえば、マイクロプロセッサをマイクロ
コンピュータに用いた場合には、マイクロプロセッサの
他にRAM、ROMのメモリおよび入出力装置を1個の
LSIに集積し、ロウスキャンデータをカラムスキャン
データに変換する場合などのように、フォントデータま
たは画像データを単一命令によるシフト動作によって行
配列または列配列に相互に短時間で変換することができ
る。For example, when the microprocessor is used in a microcomputer, RAM, ROM memory and input / output device are integrated in one LSI in addition to the microprocessor, and row scan data is converted into column scan data. As in the case, the font data or the image data can be mutually converted into a row array or a column array in a short time by a shift operation by a single instruction.
【0049】[0049]
【発明の効果】本願において開示される発明のうち、代
表的なものによって得られる効果を簡単に説明すれば、
以下のとおりである。The effects obtained by the typical ones of the inventions disclosed in the present application will be briefly described as follows.
It is as follows.
【0050】(1).複数の汎用レジスタの情報を同時にシ
フト動作可能な単一命令を有し、この単一命令で複数の
汎用レジスタの情報を同時にシフトさせたときに、複数
の汎用レジスタの最上位ビットまたは最下位ビットから
同時に発生した桁あふれビットの情報を同時に格納する
キャリレジスタを内蔵することにより、この単一命令で
複数の汎用レジスタの情報をキャリレジスタを介して同
時にシフトさせることができるので、処理の高速化が可
能となる。(1). Having a single instruction capable of simultaneously shifting the information of a plurality of general-purpose registers, and when the information of a plurality of general-purpose registers is simultaneously shifted by this single instruction, By incorporating a carry register that simultaneously stores the information of overflow bits generated simultaneously from the most significant bit or the least significant bit, the information of multiple general-purpose registers can be simultaneously shifted through the carry register with this single instruction. Therefore, the processing speed can be increased.
【0051】(2).前記(1) により、単一命令で対象とす
る汎用レジスタ、キャリが複数となるために、汎用レジ
スタのシフト命令による反復処理が低減できるので、ソ
フトウェアの負担を軽減することができる。(2) According to the above (1), since a plurality of general-purpose registers and carries are targeted by a single instruction, the repetitive processing by the shift instruction of the general-purpose register can be reduced, and the load on the software is reduced. be able to.
【0052】(3).前記(1) において、特にマイクロプロ
セッサをマイクロコンピュータに用いることにより、フ
ォントデータまたは画像データを単一命令によるシフト
動作によって行配列または列配列の相互の変換が短時間
に可能となる。(3) In the above (1), in particular, by using the microprocessor for the microcomputer, the font data or the image data can be converted into the row array or the column array in a short time by the shift operation by a single instruction. It will be possible.
【0053】(4).前記(1) において、特にマイクロプロ
セッサをプリンタまたはディスプレイに用いることによ
り、フォントデータまたは画像データを単一命令による
シフト動作により短時間で90゜回転変換させることが
できるので、水平方向または垂直方向における印字また
は表示の高速化が可能となる。(4) In the above (1), since the microprocessor can be used for the printer or the display, the font data or the image data can be rotated 90 ° in a short time by the shift operation by a single command. It is possible to speed up printing or display in the horizontal direction or the vertical direction.
【図1】本発明の一実施例であるマイクロプロセッサを
示すブロック図である。FIG. 1 is a block diagram showing a microprocessor that is an embodiment of the present invention.
【図2】本実施例のマイクロプロセッサ内の汎用レジス
タを示す構成図である。FIG. 2 is a configuration diagram showing a general-purpose register in the microprocessor of the present embodiment.
【図3】本実施例のマイクロプロセッサによるフォント
データの90゜変換処理手順を示す説明図である。FIG. 3 is an explanatory diagram showing a 90 ° conversion processing procedure of font data by the microprocessor of the present embodiment.
【図4】(a),(b) は従来技術の一例であるマイクロプロ
セッサにおいて、一般的に使用されているフォントのメ
モリデータとそのフォントパターンを示す説明図であ
る。4A and 4B are explanatory views showing memory data of a font generally used in a microprocessor which is an example of a conventional technique and a font pattern thereof.
【図5】従来技術の一例であるマイクロプロセッサによ
るフォントデータの90゜変換処理手順を示す説明図で
ある。FIG. 5 is an explanatory diagram showing a 90 ° conversion processing procedure of font data by a microprocessor which is an example of a conventional technique.
1 バス・インタフェース 2 命令デコーダ 3 制御部 4 演算部 5 レジスタ 6 プログラム・カウンタ 7 メモリ 51 汎用レジスタ 52 キャリレジスタ 1 Bus Interface 2 Instruction Decoder 3 Control Unit 4 Operation Unit 5 Register 6 Program Counter 7 Memory 51 General-purpose Register 52 Carry Register
───────────────────────────────────────────────────── フロントページの続き (72)発明者 浦 一 東京都小平市上水本町5丁目22番1号 株 式会社日立マイコンシステム内 (72)発明者 大塚 喜久雄 東京都小平市上水本町5丁目22番1号 株 式会社日立マイコンシステム内 ─────────────────────────────────────────────────── ─── Continuation of front page (72) Inventor Uraichi 5-22-1 Kamimizuhoncho, Kodaira-shi, Tokyo Inside Hitachi Microcomputer System Co., Ltd. (72) Inventor Kikuo Otsuka 5-chome, Mizumizuhoncho, Kodaira-shi, Tokyo No. 22-1 Hitachi Ltd. Microcomputer system
Claims (5)
部および制御部とを内蔵し、命令を解読して演算、制御
動作を実行するマイクロプロセッサであって、前記複数
の汎用レジスタの情報を同時にシフト動作可能な単一命
令を有し、該単一命令で前記複数の汎用レジスタの情報
を同時にシフトさせることを特徴とするマイクロプロセ
ッサ。1. A microprocessor that includes at least a plurality of general-purpose registers, an arithmetic unit and a control unit, decodes an instruction to execute an arithmetic operation and a control operation, and simultaneously shifts information of the plurality of general-purpose registers. A microprocessor having an operable single instruction, wherein the information of the plurality of general-purpose registers is simultaneously shifted by the single instruction.
または最下位ビットから同時に発生した桁あふれビット
の情報を同時に格納するキャリレジスタを内蔵すること
を特徴とする請求項1記載のマイクロプロセッサ。2. The microprocessor according to claim 1, further comprising a carry register for simultaneously storing information of overflow bits simultaneously generated from the most significant bit or the least significant bit of the plurality of general-purpose registers.
を表現するフォントデータまたは画像データを処理する
マイクロコンピュータに用い、前記フォントデータまた
は画像データを前記単一命令によるシフト動作により行
配列または列配列に相互に変換することを特徴とする請
求項1または2記載のマイクロプロセッサ。3. The microprocessor is used in a microcomputer for processing font data or image data representing characters or graphics, and the font data or image data is arranged in a row array or a column array by a shift operation by the single instruction. 3. The microprocessor according to claim 1, wherein the microprocessors convert each other.
を表現するフォントデータまたは画像データを処理して
印字または表示するプリンタまたはディスプレイに用
い、前記フォントデータまたは画像データを、前記単一
命令によるシフト動作により90゜回転変換させて水平
方向または垂直方向に印字または表示させることを特徴
とする請求項1または2記載のマイクロプロセッサ。4. The microprocessor is used in a printer or display that processes and prints or displays font data or image data representing characters or graphics, and shifts the font data or image data by the single command. 3. The microprocessor according to claim 1, wherein the microprocessor is rotated by 90 DEG for printing or displaying in the horizontal or vertical direction.
ロプロセッサにおけるデータ変換方法であって、メモリ
データを複数の汎用レジスタにロードした後、該複数の
汎用レジスタのデータを単一命令により同時にシフトさ
せ、その結果発生した桁あふれビットのデータをキャリ
レジスタに同時に格納し、その後前記キャリレジスタの
データをメモリにストアして行配列または列配列に変換
することを特徴とするマイクロプロセッサのデータ変換
方法。5. The data conversion method for a microprocessor according to claim 1, 2, 3 or 4, wherein after loading memory data into a plurality of general-purpose registers, the data of the plurality of general-purpose registers is processed by a single instruction. Data of a microprocessor characterized by shifting at the same time and simultaneously storing the data of overflow bits generated as a result in a carry register, and then storing the data of the carry register in a memory and converting it into a row array or a column array. How to convert.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP9321494A JPH07302191A (en) | 1994-05-02 | 1994-05-02 | Microprocessor and data conversion method thereof |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP9321494A JPH07302191A (en) | 1994-05-02 | 1994-05-02 | Microprocessor and data conversion method thereof |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH07302191A true JPH07302191A (en) | 1995-11-14 |
Family
ID=14076320
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP9321494A Withdrawn JPH07302191A (en) | 1994-05-02 | 1994-05-02 | Microprocessor and data conversion method thereof |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH07302191A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| SG83671A1 (en) * | 1996-09-13 | 2001-10-16 | Sanyo Electric Co | Program execution method and program executive device |
-
1994
- 1994-05-02 JP JP9321494A patent/JPH07302191A/en not_active Withdrawn
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| SG83671A1 (en) * | 1996-09-13 | 2001-10-16 | Sanyo Electric Co | Program execution method and program executive device |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| KR940009094B1 (en) | Data processing system | |
| US5867145A (en) | Graphical image recasting | |
| JP2554050B2 (en) | Data processing method | |
| US6189086B1 (en) | Data processing apparatus | |
| JP2739487B2 (en) | Drawing processing device and image display device using the drawing processing device | |
| JP2005077522A (en) | Image processor and image processing method | |
| JPH07302191A (en) | Microprocessor and data conversion method thereof | |
| US5649172A (en) | Color mixing device using a high speed image register | |
| US6504543B1 (en) | Polygon drawing method and polygon drawing apparatus | |
| JP2587042B2 (en) | Semiconductor integrated circuit | |
| US6727903B1 (en) | Microprocessor, and graphics processing apparatus and method using the same | |
| EP0359255A2 (en) | Pattern data generating system | |
| JP3043861B2 (en) | Data processing device | |
| JPH07129398A (en) | Microprocessor | |
| JPH0228828A (en) | Maximum value and minimum value detecting circuit | |
| WO1991018353A1 (en) | Display list processor for terminal controller | |
| JP2610858B2 (en) | Color pixel information processing device | |
| JPH0863146A (en) | Microprocessor and graphics processing device | |
| JPH07210136A (en) | Gradation character generation method | |
| JPH0134383B2 (en) | ||
| JPH09179541A (en) | Image display device | |
| JP2001351111A (en) | Image processing apparatus and drawing processing apparatus | |
| JPH0855017A (en) | Integer data processing circuit for graphic and image processing,multiplier unit with pipeline,logical operation unit and shift register unit | |
| JPS61140986A (en) | Character rotation apparatus | |
| JPH01295568A (en) | Picture element synthesis processing unit |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A300 | Withdrawal of application because of no request for examination |
Free format text: JAPANESE INTERMEDIATE CODE: A300 Effective date: 20010703 |