JPH06337791A - Program converting device and processor - Google Patents
Program converting device and processorInfo
- Publication number
- JPH06337791A JPH06337791A JP12621293A JP12621293A JPH06337791A JP H06337791 A JPH06337791 A JP H06337791A JP 12621293 A JP12621293 A JP 12621293A JP 12621293 A JP12621293 A JP 12621293A JP H06337791 A JPH06337791 A JP H06337791A
- Authority
- JP
- Japan
- Prior art keywords
- instruction
- address
- data
- register
- bit width
- 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.)
- Granted
Links
- 238000000034 method Methods 0.000 description 25
- 230000010365 information processing Effects 0.000 description 12
- 238000004364 calculation method Methods 0.000 description 5
- 230000015556 catabolic process Effects 0.000 description 5
- 238000006731 degradation reaction Methods 0.000 description 5
- 230000000694 effects Effects 0.000 description 5
- 238000004458 analytical method Methods 0.000 description 3
- 238000010586 diagram Methods 0.000 description 2
- TVEXGJYMHHTVKP-UHFFFAOYSA-N 6-oxabicyclo[3.2.1]oct-3-en-7-one Chemical compound C1C2C(=O)OC1C=CC2 TVEXGJYMHHTVKP-UHFFFAOYSA-N 0.000 description 1
- 238000006073 displacement reaction Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000001343 mnemonic effect Effects 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 230000000717 retained effect Effects 0.000 description 1
Landscapes
- Devices For Executing Special Programs (AREA)
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は高級言語プログラムを機
械語プログラムに変換するプログラム変換装置、及び、
その機械語プログラムを実行するプロセッサに関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a program conversion device for converting a high level language program into a machine language program, and
The present invention relates to a processor that executes the machine language program.
【0002】[0002]
【従来の技術】近年の電子技術の発展により、マイクロ
プロセッサ等の情報処理装置が普及し、あらゆる分野で
用いられている。。従来のプロセッサとしては、例え
ば、森下巖著、「マイクロプロセッサのハードウェア」
(1984年11月9日、岩波書店)に示されている、
セグメントアドレス方式の16ビットプロセッサがあ
る。2. Description of the Related Art With the recent development of electronic technology, information processing devices such as microprocessors have become widespread and used in all fields. . As a conventional processor, for example, Izumi Morishita, "Hardware of Microprocessor"
(November 9, 1984, Iwanami Shoten),
There is a segment addressing 16-bit processor.
【0003】このセグメントアドレス方式の16ビット
プロセッサは、16ビットよりも上位のビットを含む上
位アドレスを格納するセグメントレジスタを備えること
により、データのビット幅が16ビットでありながら6
4キロバイトを超えるアドレス空間を扱うことができ
る。すなわち、64キロバイトを越える全アドレス空間
をセグメントと呼ぶ64キロバイト単位の部分に分ける
とともに、各セグメントに番号を付ける方式である。ア
ドレスは、セグメントレジスタに収められたセグメント
番号と、データのビット幅と同じ16ビットで表される
セグメントの先頭からの距離(オフセット)とで管理さ
れる。これにより、セグメントアドレス方式の16ビッ
トプロセッサでは、データのビット幅が16ビットで6
4キロバイトを超えるアドレス空間を扱うことができ
る。This segment address type 16-bit processor is provided with a segment register for storing a high-order address including bits higher than 16 bits, so that the bit width of data is 16 bits, but is 6 bits.
It can handle address spaces larger than 4 kilobytes. That is, the entire address space exceeding 64 kilobytes is divided into 64 kilobyte units called segments, and each segment is numbered. The address is managed by the segment number stored in the segment register and the distance (offset) from the beginning of the segment represented by 16 bits which is the same as the bit width of the data. As a result, in a segment address type 16-bit processor, the bit width of data is 16 bits and 6 bits.
It can handle address spaces larger than 4 kilobytes.
【0004】また、従来のプロセッサとして、同書に示
されている32ビットプロセッサがある。この32ビッ
トプロセッサは、32ビット幅のアドレスを32ビット
幅のデータと同一に管理して、4ギガバイトのアドレス
空間を扱うことができる。このようなプロセッサ上で実
行される機械語プログラムは、コンパイラ等のプログラ
ム変換装置によって生成される。As a conventional processor, there is a 32-bit processor shown in the same document. The 32-bit processor can manage a 32-bit width address in the same manner as a 32-bit width data and handle a 4-gigabyte address space. A machine language program executed on such a processor is generated by a program conversion device such as a compiler.
【0005】上記16ビットプロセッサに対するコンパ
イラは、アドレス管理の方式に関して、ラージモデル方
式を呼ばれるものと、ニアファーモデル方式と呼ばれる
ものがある。ラージモデル方式を採用するコンパイラ
は、ポインタ変数を常にセグメントレジスタと16ビッ
トオフセットとを対にして設定する。このため、このコ
ンパイラによるオブジェクトコードを実行するプロセッ
サは、アドレス計算の度にセグメントレジスタの内容を
計算して更新する操作が発生し、セグメントアドレス方
式を採らない16ビットプロセッサに比べて著しく性能
が劣化するという短所を有している。Regarding the address management system, the compiler for the 16-bit processor is classified into a large model system and a near-far model system. A compiler adopting the large model method always sets a pointer variable in pairs with a segment register and a 16-bit offset. For this reason, the processor that executes the object code by this compiler needs to calculate and update the contents of the segment register every time the address is calculated, and the performance is significantly deteriorated as compared with the 16-bit processor that does not adopt the segment address method. It has the disadvantage of
【0006】また、ニアファーモデル方式とを採用する
コンパイラは、ラージモデル方式における上記の短所を
次のようにして解決している。この方式は、同一セグメ
ント内をアクセスするためのニアポインタ変数と、セグ
メント境界をまたいでアクセスするためのファーポイン
タ変数という2種類のポインタ変数を指定できるように
なっている。コンパイラは、ニアポインタ変数には16
ビットオフセットのみを設定し、ファーポインタ変数に
はセグメントレジスタと16ビットオフセットとを対に
して設定する。ニアポインタ変数とファーポインタ変数
のいずれを用いるかは、プログラマが選択する。Further, the compiler adopting the near-far model method solves the above disadvantages of the large-model method as follows. In this method, two types of pointer variables can be designated: a near pointer variable for accessing the same segment and a far pointer variable for accessing across a segment boundary. The compiler uses 16 for near pointer variables
Only the bit offset is set, and the far pointer variable is set by pairing the segment register and the 16-bit offset. The programmer selects whether to use the near pointer variable or the far pointer variable.
【0007】このニアファーモデル方式は、ニアポイン
タ変数を用いる場面ではラージモデル方式に比べて性能
が向上する反面、プログラマがプログラム作成時にセグ
メント境界を認識して2種類のポインタ変数を使い分け
る必要があり、プログラム開発効率が著しく低下すると
いう新たな問題点を有している。他方、32ビットプロ
セッサに対するコンパイラは、上記の問題点を有してい
ない。即ち、コンパイラが32ビットのデータ変数と同
様にポインタ変数にも32ビットのアドレスを設定する
ので、プログラマがセグメントの境界を認識する必要が
ないので、プログラムの開発効率を低下させることもな
い。また、コンパイルされたプロクラムを実行するプロ
セッサは、アドレス計算による性能劣化を発生させな
い。そして、4ギガバイトという広大なアドレス空間を
扱うことができる。In this near-far model method, the performance is improved in the case of using the near pointer variable as compared with the large model method, but it is necessary for the programmer to recognize the segment boundary at the time of program creation and properly use two kinds of pointer variables. However, there is a new problem that the program development efficiency is significantly reduced. On the other hand, compilers for 32-bit processors do not have the above problems. That is, since the compiler sets a 32-bit address to a pointer variable as well as a 32-bit data variable, the programmer does not need to recognize the segment boundary, and therefore the program development efficiency is not reduced. In addition, the processor that executes the compiled program does not suffer performance degradation due to address calculation. It can handle a vast address space of 4 gigabytes.
【0008】[0008]
【発明が解決しようとする課題】しかしながら従来技術
のプロセッサおよびプログラム変換装置によれば、組み
込み用途のマイクロコンピュータでの応用(アプリケー
ション)おいては、32ビットのデータ幅を必要とせ
ず、かつ、4ギガバイトのアドレス空間を必要としない
ものがほとんどである。多くのアプリケーションでは、
データ幅については16ビットあれば十分であるが、ア
ドレス空間については64キロバイトでは不足する。こ
のような現状に鑑みると、データのビット幅が16ビッ
ト必要で、かつ、アドレス空間が64キロバイト以上を
必要とするが4ギガバイトもの大きさを必要としない応
用では、最適なマイクロコンピュータおよびコンパイラ
がなかったという問題点があった。However, according to the processor and the program conversion device of the prior art, the data width of 32 bits is not required in the application (application) in the microcomputer for the embedded use, and 4 Most do not require a gigabyte of address space. In many applications,
16 bits is sufficient for the data width, but 64 kilobytes is insufficient for the address space. In view of such a current situation, in an application that requires a data bit width of 16 bits and an address space of 64 kilobytes or more, but does not require a size of 4 gigabytes, an optimum microcomputer and compiler are required. There was a problem that it did not exist.
【0009】より具体的に説明すると、32ビットプロ
セッサは、32ビットのデータおよびアドレスを処理す
るためのハードウェアを有することから、過分なハード
ウェアとなるのでコストおよび消費電力が増大するとい
う問題点を有している。16ビットプロセッサは、アド
レス空間の管理が従来技術で述べたようにアドレス計算
の点で性能劣化を避けられない。また、プログラマがセ
グメントの境界を認識する必要があることから、プログ
ラムの開発効率が落ちる。More specifically, since the 32-bit processor has hardware for processing 32-bit data and addresses, it becomes redundant hardware, resulting in an increase in cost and power consumption. have. In the 16-bit processor, management of the address space is inevitable in terms of address calculation as described in the prior art. In addition, the programmer needs to recognize the boundaries of the segments, which reduces the program development efficiency.
【0010】また、32ビットプロセッサ用コンパイラ
は、16ビットまたは32ビットを基本語長とする機械
語命令を使い分け、プログラム中では32ビットのアド
レス指定が必要なために、プログラムのコードサイズが
増大する。また、32ビットプロセッサとメモリとを接
続するデータバスのビット幅が16ビットの場合は32
ビットに比べて性能が著しく劣化するという問題点も有
している。The 32-bit processor compiler selectively uses machine language instructions having a basic word length of 16 bits or 32 bits, and 32-bit addressing is required in the program, which increases the code size of the program. . If the bit width of the data bus connecting the 32-bit processor and the memory is 16 bits, 32
There is also a problem that the performance is significantly deteriorated as compared with the bit.
【0011】本発明は上記問題点に鑑み、データのビッ
ト幅が16ビットで16メガバイト程度のアドレス空間
を必要とする応用において、好適したプログラム変換装
置およびプロセッサを提供することを目的とする。In view of the above problems, it is an object of the present invention to provide a program conversion device and a processor suitable for applications in which the bit width of data is 16 bits and an address space of about 16 megabytes is required.
【0012】[0012]
【課題を解決するための手段】上記の課題を解決するた
め本発明のプログラム変換装置は、主たるデータの型に
おける有効なビット幅よりも長いビット幅をもつアドレ
スを扱うプロセッサを対象とし、高級言語プログラムに
基づいて機械語命令を生成するプログラム変換装置であ
って、主たるデータの型における有効なビット幅および
アドレスのビット幅を保持するパラメータ保持手段と、
生成すべき機械語命令で用いられる変数が、データを表
す変数である場合、パラメータ保持手段が保持するデー
タのビット幅を有効とする命令を生成し、アドレスを表
す変数である場合、パラメータ保持手段が保持するアド
レスのビット幅を有効とする命令を生成する生成手段と
を備えている。In order to solve the above-mentioned problems, the program conversion device of the present invention is intended for a processor that handles an address having a bit width longer than the effective bit width in a main data type, and is intended for a high-level language. A program conversion device for generating a machine language instruction based on a program, and a parameter holding means for holding an effective bit width in a main data type and an address bit width,
When the variable used in the machine language instruction to be generated is a variable that represents data, an instruction that validates the bit width of the data held by the parameter holding means is generated, and when it is a variable that represents an address, the parameter holding means And a generation unit that generates an instruction that validates the bit width of the address held by.
【0013】前記データのビット幅Mは16であり、前
記アドレスのビット幅Nは17以上31以下であっても
よい。また、前記生成手段は、生成すべき機械語命令が
メモリをアクセスする命令である場合に、アクセス対象
となる変数がデータであるかアドレスであるかに応じ
て、パラメータ保持手段に保持された対応するビット幅
をアクセス幅とすべきことを指示するメモリ管理手段
と、生成すべき機械語命令がレジスタを使用する命令で
ある場合に、そのレジスタにリード又はライトされる変
数がデータであるかアドレスであるか応じて、パラメー
タ保持手段に保持された対応するビット幅を有効とすべ
きことを指示するレジスタ管理手段と、生成すべき機械
語命令が即値を使用する命令である場合にその即値がデ
ータであるかアドレスであるか応じて、パラメータ保持
手段に保持された対応するビット幅の即値を用いるべき
ことを指示する即値管理手段とメモリ管理手段、レジス
タ管理手段、即値管理手段からの指示に従って、機械後
命令を生成するコード生成手段とからなっていてもよ
い。The bit width M of the data may be 16, and the bit width N of the address may be 17 or more and 31 or less. Further, when the machine language instruction to be generated is an instruction to access a memory, the generating means stores the correspondence held in the parameter holding means according to whether the variable to be accessed is data or address. Memory management means for instructing that the access width be the bit width to be read, and if the machine language instruction to be generated is an instruction that uses a register, the variable read or written to that register is data or an address. Register management means for instructing that the corresponding bit width held in the parameter holding means should be valid, and if the machine language instruction to be generated is an instruction that uses an immediate value, the immediate value is Immediate value management means for instructing to use the immediate value of the corresponding bit width held in the parameter holding means depending on whether it is data or address Memory management unit, the register managing unit, according to an instruction from the immediate managing means may consist of a code generating means for generating machine after instruction.
【0014】また、本発明のプロセッサは、上記プログ
ラム変換装置により生成されたプログラムを実行するプ
ロセッサであって、Nビット長のプログラムカウンタ
と、Nビット長の演算、及びデータのビット幅であるM
ビット長の演算を実行する実行手段とを備えている。The processor of the present invention is a processor for executing the program generated by the program conversion device, and is a program counter having an N-bit length, an operation having an N-bit length, and a data bit width M.
And a means for executing a bit length operation.
【0015】ここで、前記Nは24であり、Mは16で
あってもよい。Here, N may be 24 and M may be 16.
【0016】[0016]
【作用】上記の手段により本発明のプログラム変換装置
において、生成手段は、生成すべき機械語命令で用いら
れる変数が、データを表す変数である場合、パラメータ
保持手段が保持するデータのビット幅を有効とする命令
を生成する。アドレスを表す変数である場合、パラメー
タ保持手段が保持するアドレスのビット幅を有効とする
命令を生成する。In the program conversion device of the present invention by the above means, the generation means determines the bit width of the data held by the parameter holding means when the variable used in the machine language instruction to be generated is a variable representing data. Generate valid instructions. If it is a variable representing an address, an instruction for validating the bit width of the address held by the parameter holding means is generated.
【0017】また、前記生成手段において、メモリ管理
手段は、生成すべき機械語命令がメモリをアクセスする
命令である場合に、アクセス対象となる変数がデータで
あるかアドレスであるかに応じて、パラメータ保持手段
に保持された対応するビット幅をアクセス幅とすべきこ
とをコード生成手段に指示する。レジスタ管理手段は、
生成すべき機械語命令がレジスタを使用する命令である
場合に、そのレジスタにリード又はライトされる変数が
データであるかアドレスであるか応じて、パラメータ保
持手段に保持された対応するビット幅を有効とすべきこ
とをコード生成手段に指示する。即値管理手段は、生成
すべき機械語命令が即値を使用する命令である場合にそ
の即値がデータであるかアドレスであるか応じて、パラ
メータ保持手段に保持された対応するビット幅の即値を
用いるべきことをコード生成手段に指示する。Further, in the generating means, the memory management means, when the machine language instruction to be generated is an instruction to access the memory, determines whether the variable to be accessed is data or address. The code generation means is instructed that the corresponding bit width held in the parameter holding means should be the access width. The register management means is
When the machine language instruction to be generated is an instruction using a register, the corresponding bit width held in the parameter holding means is set according to whether the variable read or written in the register is data or address. Instructs the code generation means that it should be valid. When the machine language instruction to be generated is an instruction that uses an immediate value, the immediate value management means uses the immediate value of the corresponding bit width held in the parameter holding means according to whether the immediate value is data or an address. Instruct the code generation means what to do.
【0018】また、本発明のプロセッサは、N(24)
ビット長のプログラムカウンタにより2のN乗(16メ
ガバイト)のアドレス空間を利用でき、実行手段により
N(24)ビット長の演算、及びデータのビット幅であ
るM(16)ビット長の演算を実行し得る。Further, the processor of the present invention is N (24)
An address space of 2 N (16 megabytes) can be used by a bit-length program counter, and an operation unit executes an operation of N (24) -bit length and an operation of M (16) -bit length, which is the bit width of data. You can
【0019】[0019]
【実施例】図1は本発明の実施例におけるマイクロコン
ピュータおよびプログラム変換装置(以下、コンパイラ
と略す。マイクロコンピュータとコンパイラを含めて情
報処理装置と呼ぶ)のブロック図を示す。図1におい
て、本情報処理装置は、C言語プログラムを格納してい
る記憶装置1と、C言語プログラムを機械語プログラム
に翻訳するコンパイラ2と、オブジェクトコードを実行
するハードウェア3とからなる。FIG. 1 is a block diagram of a microcomputer and a program conversion device (hereinafter abbreviated as a compiler; the microcomputer and the compiler are collectively referred to as an information processing device) according to an embodiment of the present invention. In FIG. 1, the information processing apparatus includes a storage device 1 that stores a C language program, a compiler 2 that translates the C language program into a machine language program, and hardware 3 that executes an object code.
【0020】コンパイラ2は、以下のものからなる。5
は構文解析部で、C言語プログラムの構文を解析し、プ
ログラム文が中間形式に変換された中間形式文及び中間
コードからなる中間ファイルを生成する。7はコード生
成部で、中間ファイルに基づいてオブジェクトコードを
生成する。The compiler 2 consists of the following: 5
Is a syntax analysis unit, which analyzes the syntax of the C language program and generates an intermediate file composed of intermediate format statements and intermediate codes in which the program statements are converted into the intermediate format. A code generator 7 generates an object code based on the intermediate file.
【0021】8はパラメータ設定部で、整数型のデータ
変数のビット幅とポインタ変数のビット幅とを保持す
る。本実施例では、予め利用者により整数型のデータ変
数のビット幅が16ビットに、ポインタ変数のビット幅
が24ビットに設定されているものとする。9はメモリ
管理部で、コード生成部7が生成すべきロード・ストア
命令について、その命令の対象となる変数の型に応じ
て、メモリを読み書きするビット幅を指示する。A parameter setting unit 8 holds the bit width of the integer type data variable and the bit width of the pointer variable. In this embodiment, it is assumed that the user has previously set the bit width of the integer type data variable to 16 bits and the bit width of the pointer variable to 24 bits. A memory management unit 9 indicates a bit width for reading and writing the memory for the load / store instruction to be generated by the code generation unit 7 according to the type of the variable that is the target of the instruction.
【0022】10はレジスタ管理部で、コード生成部7
が生成すべきレジスタを使用する命令について、レジス
タにリード/ライトされる変数の型に応じて、有効なビ
ット幅を指示する。11は即値管理部で、コード生成部
7が生成すべき即値を用いる命令について、即値である
変数の型に応じて、命令コード中の即値のビット幅を指
示する。Reference numeral 10 denotes a register management unit, which is a code generation unit 7
Specifies an effective bit width according to the type of the variable read / written in the register for the instruction using the register to be generated. An immediate value management unit 11 indicates the bit width of the immediate value in the instruction code for the instruction using the immediate value that the code generation unit 7 should generate, according to the type of the variable that is the immediate value.
【0023】また、ハードウェア3は、以下のものから
なる。13はメモリで、オブジェクトコードおよびプロ
グラムで用いられるデータを格納する。14はアドレス
バスで、24ビットのビット幅を持つ。15はデータバ
スで、16ビットのビット幅を持つ。The hardware 3 is composed of the following. A memory 13 stores the object code and data used in the program. An address bus 14 has a bit width of 24 bits. A data bus 15 has a bit width of 16 bits.
【0024】16はバス制御回路で、アドレスバス14
とデータバス15とを介してメモリ13に接続され、メ
モリ13に格納されたオブジェクトコードを命令として
逐一読み出し、またメモリ13に対してデータを読み書
きする。17は命令制御回路で、プログラムカウンタ1
9を有し、バス制御回路16へ命令アドレスを指示し、
バス制御回路16から命令を受け取り解読する。A bus control circuit 16 is provided for the address bus 14.
It is connected to the memory 13 via the data bus 15 and the data bus 15, and reads the object code stored in the memory 13 as an instruction one by one and reads / writes data from / to the memory 13. Reference numeral 17 is an instruction control circuit, which is a program counter 1
9 for indicating an instruction address to the bus control circuit 16,
It receives an instruction from the bus control circuit 16 and decodes it.
【0025】プログラムカウンタ19は、24ビットの
命令アドレスを出力する。18は演算実行回路で、レジ
スタファイル20と演算器21からなる。レジスタファ
イル20は、24ビットの複数のレジスタを有する。演
算器21は、レジスタファイル20に保持された値を用
いて24ビット幅の算術論理演算等を実行する。The program counter 19 outputs a 24-bit instruction address. Reference numeral 18 denotes an arithmetic execution circuit, which includes a register file 20 and an arithmetic unit 21. The register file 20 has a plurality of 24-bit registers. The arithmetic unit 21 uses the value held in the register file 20 to execute a 24-bit wide arithmetic logic operation or the like.
【0026】図2は、コード生成部7の処理フローを示
す。ステップ20は、中間ファイルからデータ変数を抽
出して、それぞれの変数に関する情報を載せた変数テー
ブル(シンボルテーブル)を作成する。シンボルテーブ
ルの一例を図7に示す。同図において、シンボル欄はデ
ータ変数のシンボルを、型欄はデータ変数が整数型であ
るかポインタ型であるかを、バイト数欄はそのデータ変
数のバイト数を、先頭アドレス欄はメモリに割り付けら
れている場合の先頭アドレスを、レジスタ欄はレジスタ
が割り当てれている場合のレジスタ名を示す。FIG. 2 shows a processing flow of the code generator 7. In step 20, data variables are extracted from the intermediate file and a variable table (symbol table) carrying information on each variable is created. An example of the symbol table is shown in FIG. In the figure, the symbol column assigns the symbol of the data variable, the type column assigns whether the data variable is an integer type or pointer type, the byte number column assigns the byte number of the data variable, and the head address column assigns it to memory. If the register is assigned, the register name indicates the register name when the register is assigned.
【0027】ステップ21は、中間ファイルからコード
生成が未処理の中間命令があるか否かを判定する。あれ
ばステップ22に進み、なければコード生成が終了す
る。ステップ22は、中間ファイルから次に処理すべき
順の中間命令を1つ読み出す。ステップ23は、1つの
中間命令を実現する1つ又は複数の機械語命令を選定す
る。In step 21, it is determined whether or not there is an intermediate instruction for which code generation has not been processed from the intermediate file. If so, the process proceeds to step 22, and if not, the code generation ends. Step 22 reads one intermediate instruction in the order to be processed next from the intermediate file. Step 23 selects one or more machine language instructions that implement one intermediate instruction.
【0028】ステップ24は、選定された機械語命令か
ら次に処理すべき順の機械語命令を1つ指定する。ステ
ップ25は、指定された1つの機械語命令(以下、個別
命令と呼ぶ)の命令コードを生成する処理(以下、個別
処理と呼ぶ)を行う。ステップ26は、ステップ23で
選定された機械語命令のうち次に処理すべき機械語命令
があるか否かを判定する。あればステップ24に戻り、
なければステップ21に戻る。In step 24, one machine language instruction to be processed next from the selected machine language instruction is designated. The step 25 performs a process (hereinafter, referred to as an individual process) for generating an instruction code of one designated machine language instruction (hereinafter, referred to as an individual instruction). In step 26, it is determined whether or not there is a machine language instruction to be processed next among the machine language instructions selected in step 23. If so, return to step 24,
If not, the process returns to step 21.
【0029】図3〜図6は、上記ステップ25の個別処
理のフローを示す。第1に、ステップ30は、個別命令
がロード/ストア命令の種類に属するか否かを判定し、
そうである場合はメモリ管理部9に通知し、そうでない
場合ステップ31に進む。この通知を受けたメモリ管理
部9の処理フローを図4に示す。図4において、ステッ
プ40は、その個別命令(ロード/ストア命令)におい
てメモリとの間でロード/ストアすべき変数について、
シンボルテーブルを参照し、その変数の型を調べる。3 to 6 show the flow of the individual processing in step 25 described above. First, step 30 determines whether the individual instruction belongs to a load / store instruction type,
If so, the memory management unit 9 is notified, and if not, the process proceeds to step 31. FIG. 4 shows a processing flow of the memory management unit 9 which receives this notification. In FIG. 4, step 40 is for a variable to be loaded / stored in / from the memory in the individual instruction (load / store instruction),
Look up the symbol table to find out the variable type.
【0030】ステップ41は、その変数の型が整数型デ
ータ変数であるか、ポインタ型データ変数であるかを判
定し、前者である場合ステップ42に、後者である場合
ステップ43に進む。ステップ42は、アクセスするデ
ータ幅が2バイトのロード/ストア命令を生成すべきこ
とをコード生成部7に指示し、ステップ31に進む。In step 41, it is determined whether the type of the variable is an integer type data variable or a pointer type data variable, and if it is the former, the process proceeds to step 42, and if it is the latter, the process proceeds to step 43. In step 42, the code generation unit 7 is instructed that a load / store instruction having a data width to be accessed of 2 bytes should be generated, and the process proceeds to step 31.
【0031】ステップ43は、アクセスするデータ幅が
3バイトのロード/ストア命令を生成すべきことをコー
ド生成部7に指示し、ステップ31に進む。第2に、ス
テップ31は、個別命令がレジスタを使用するか否かを
判定し、そうである場合はレジスタ管理部10に通知
し、そうでない場合ステップ32に進む。この通知を受
けた場合のレジスタ管理部10の処理フローを図5に示
す。図5において、ステップ50は、その個別命令が使
用するレジスタに格納される変数について、シンボルテ
ーブルを参照し、その変数の型を調べる。In step 43, the code generator 7 is instructed to generate a load / store instruction having a data width to be accessed of 3 bytes, and the process proceeds to step 31. Second, step 31 determines whether or not the individual instruction uses a register, and if so, notifies the register management unit 10 and otherwise proceeds to step 32. FIG. 5 shows a processing flow of the register management unit 10 when receiving this notification. In FIG. 5, a step 50 refers to the symbol table for the variable stored in the register used by the individual instruction and checks the type of the variable.
【0032】ステップ51は、その変数の型が整数型デ
ータ変数であるか、ポインタ型データ変数であるかを判
定し、前者である場合ステップ52に、後者である場合
ステップ53に進む。ステップ52は、使用するレジス
タの下位16ビットを有効とする命令を生成すべきこと
をコード生成部7に指示し、ステップ32に進む。In step 51, it is determined whether the type of the variable is an integer type data variable or a pointer type data variable, and if it is the former, the process proceeds to step 52, and if it is the latter, the process proceeds to step 53. In step 52, the code generation unit 7 is instructed to generate an instruction for validating the lower 16 bits of the register to be used, and the process proceeds to step 32.
【0033】ステップ53は、使用するレジスタの全2
4ビットを有効とする命令を生成すべきことをコード生
成部7に指示し、ステップ32に進む。第3に、ステッ
プ32は、個別命令が即値データを使用するかか否かを
判定し、そうである場合は即値管理部11に通知し、そ
うでない場合ステップ33に進む。この通知を受けた場
合の即値管理部11の処理フローを図6に示す。In step 53, all two registers to be used are used.
The code generation unit 7 is instructed to generate an instruction that enables 4 bits, and the process proceeds to step 32. Thirdly, the step 32 determines whether or not the individual instruction uses the immediate data, and if so, notifies the immediate value management unit 11; otherwise, the process proceeds to step 33. FIG. 6 shows a processing flow of the immediate value management unit 11 when receiving this notification.
【0034】図6において、ステップ60は、当該個別
命令において使用する即値データとなる変数について、
シンボルテーブルを参照し、その変数の型を調べる。ス
テップ61は、その変数の型が整数型データ変数である
か、ポインタ型データ変数であるかを判定し、前者であ
る場合ステップ62に、後者である場合ステップ63に
進む。In FIG. 6, in step 60, a variable which is immediate data used in the individual instruction is
Look up the symbol table to find out the variable type. A step 61 decides whether the type of the variable is an integer type data variable or a pointer type data variable, and if it is the former, it proceeds to step 62, and if it is the latter, it proceeds to step 63.
【0035】ステップ62は、2バイトの即値を持つ命
令を生成すべきことをコード生成部7に指示し、ステッ
プ33に進む。ステップ63は、3バイトの即値を持つ
命令を生成すべきことをコード生成部7に指示し、ステ
ップ33に進む。第4に、ステップ33は、メモリ管理
部9、レジスタ管理部10、即値管理部11からの指示
があれば、それにしたがって個別命令の命令コードを生
成する。In step 62, the code generator 7 is instructed to generate an instruction having an immediate value of 2 bytes, and the process proceeds to step 33. In step 63, the code generation unit 7 is instructed to generate an instruction having an immediate value of 3 bytes, and the process proceeds to step 33. Fourthly, in step 33, if there is an instruction from the memory management unit 9, the register management unit 10, or the immediate value management unit 11, the instruction code of the individual instruction is generated according to the instruction.
【0036】以上のように構成された本実施例のマイク
ロコンピュータおよびプログラム変換装置について、以
下その動作を説明する。説明を簡潔にするために、記憶
装置1に記憶されているC言語プログラムが次に示す場
合を例にあげる。 構文解析部5は、記憶装置1からC言語プログラムを取
り出し、構文を文法に照らして解析して中間形式の言語
で記述された中間ファイルを生成する。この中間ファイ
ルのイメージを以下に示す。ただし、ここでは便宜上、
中間形式の記述を意味がわかるように書き直してある。The operation of the microcomputer and the program conversion device of the present embodiment configured as described above will be described below. In order to simplify the explanation, the case where the C language program stored in the storage device 1 is as follows is given as an example. The syntax analysis unit 5 takes out a C language program from the storage device 1, analyzes the syntax according to the grammar, and generates an intermediate file described in an intermediate format language. An image of this intermediate file is shown below. However, for convenience here,
The intermediate form description has been rewritten to make sense.
【0037】中間形式文1: (int *a, b, c) 中間命令1: t1:=*a 中間命令2: t2:=t1+b 中間命令3: t3:=t2+1 中間命令4: c:=t3 中間形式文1は、宣言文int *a, b, c に対応し、中間
命令1〜4は、演算式c= *a + b + 1 に対応する。Intermediate format statement 1: (int * a, b, c) Intermediate instruction 1: t1: = * a Intermediate instruction 2: t2: = t1 + b Intermediate instruction 3: t3: = t2 + 1 Intermediate instruction 4: c: = t3 Intermediate format statement 1 corresponds to the declaration statements int * a, b, c, and intermediate instructions 1 to 4 correspond to the arithmetic expression c = * a + b + 1.
【0038】これらの中間形式文、中間命令は、それぞ
れ以下のようにしてオブジェクトコードに変換される。
この中間ファイルが入力されると、コード生成部7は、
中間ファイル中のデータ変数(宣言のないものも含め
て)を抽出し、それぞれの変数の型を調査し、必要があ
ればメモリに割り当て、図7に示したシンボルテーブル
を作成する(図2のステップ20)。These intermediate format statements and intermediate instructions are converted into object codes as follows.
When this intermediate file is input, the code generator 7
Data variables (including those without declaration) in the intermediate file are extracted, the type of each variable is inspected, and if necessary, allocated to memory, and the symbol table shown in FIG. 7 is created (see FIG. 2). Step 20).
【0039】上の例では、中間形式文1から明示に宣言
された変数*a,b,cが抽出される。ポインタ変数として宣
言された変数*aは、パラメータ設定部8においてポイン
タ変数のビット幅が24ビットに設定されているので、
メモリ上に24ビット(3バイト)の領域が確保され割
り付けられる。また、整数型データ変数として宣言され
た2つの変数b,cは、パラメータ設定部8において整数
型データ変数のビット幅が16ビットに設定されている
ので、それぞれメモリ上に16ビット(2バイト)の領
域が確保され割り付けられる。ここでは、変数*a,b,c
は、それぞれメモリの1000番地から3バイト、1004番地
から2バイト、1006番地から2バイトの領域に割り当て
られているものとする。ただし、1003番地の1バイトは
空領域である。In the above example, the variables * a, b, c explicitly declared are extracted from the intermediate format sentence 1. Since the variable * a declared as a pointer variable has the bit width of the pointer variable set to 24 bits in the parameter setting unit 8,
A 24-bit (3 bytes) area is secured and allocated in the memory. Further, the two variables b and c declared as integer type data variables have 16 bits (2 bytes) in the memory because the bit width of the integer type data variable is set to 16 bits in the parameter setting unit 8. Area is secured and allocated. Here, the variables * a, b, c
Are respectively allocated to the areas from the address 1000 to 3 bytes, the address 1004 to 2 bytes, and the address 1006 to 2 bytes. However, 1 byte at address 1003 is an empty area.
【0040】さらに、中間命令1〜4から一時変数t1,t
2,t3が抽出される。一時変数t1,t2,t3は、演算対象とな
る変数に合わせて、それぞれ整数型データ変数として扱
われる。これらの変数に関する情報がシンボルテーブル
に書き込まれる。このシンボルテーブルの内容は、以後
レジスタ割当等の変更があれば、その都度ダイナミック
にその内容が書き換えられる。既に示した図7は、この
時点におけるシンボルテーブルの内容である。この時点
では、レジスタ欄及び一時変数の先頭アドレス欄は、割
当がないので空欄のままである。Further, the temporary variables t1, t from the intermediate instructions 1 to 4
2, t3 is extracted. The temporary variables t1, t2, t3 are treated as integer type data variables in accordance with the variables to be calculated. Information about these variables is written to the symbol table. The contents of the symbol table are dynamically rewritten whenever the register allocation or the like is changed thereafter. FIG. 7 already shown shows the contents of the symbol table at this point. At this point, the register column and the head address column of the temporary variable are left blank because there is no allocation.
【0041】この後、コード生成部7は、中間命令のそ
れぞれについて、以下のようにして対応する機械語命令
を生成する。 << 中間命令1:t1:=*a >>コード生成部7は、中間ファ
イル中に処理すべき(未処理の)中間命令が残っている
か否かを判定する(図2のステップ21)。この時点で
は、中間命令1〜4が残っているので、ステップ22に
進む。After that, the code generator 7 generates a corresponding machine language instruction for each of the intermediate instructions as follows. << Intermediate instruction 1: t1: = * a >> The code generation unit 7 determines whether or not there is an intermediate instruction to be processed (unprocessed) in the intermediate file (step 21 in FIG. 2). At this point, the intermediate instructions 1 to 4 remain, so the process proceeds to step 22.
【0042】次に、コード生成部7は、未処理の中間命
令のうち先頭の中間命令を1つ読み出し(ステップ2
2)、その中間命令を実現する1つ又は複数の機械語命
令を選定する(ステップ23)。ステップ23における
中間命令1を実現する1つ又は複数の命令の選定を具体
的に説明する。Next, the code generator 7 reads one of the unprocessed intermediate instructions at the beginning (step 2).
2) Select one or more machine language instructions that implement the intermediate instruction (step 23). The selection of one or more instructions that realize the intermediate instruction 1 in step 23 will be specifically described.
【0043】中間命令1は「ポインタ変数*aが割り当
てられている1000番地から、3バイトを読み出して、
その内容をアドレスとして2バイト読み出して一時変
数t1に格納する。」ことを内容とする。コード生成部7
は、この内容を実現するため上記〜に対応する機械
語命令を選定する。すなわち、アドレス1000番地を即
値データとして、第1のアドレスレジスタに格納するmo
v命令、第1のアドレスレジスタを用いて*aの内容
(ポインタ)をアドレスとして、第2のアドレスレジス
タに読み出すmov命令、第2のアドレスレジスタを用
いて、ポインタが指すデータをデータレジスタに読み出
すmov命令、の3つの命令を選定する。上記第1、第2
のアドレスレジスタは、A0、A1が割り当てられているも
のとする。これは、シンボルテーブルに記入される。The intermediate instruction 1 reads "3 bytes from the address 1000 to which the pointer variable * a is assigned,
The contents are read out as 2 bytes and stored in the temporary variable t1. It is the content. Code generator 7
Selects a machine language instruction corresponding to the above items 1 to 3 to realize this content. That is, the address 1000 is stored as immediate data in the first address register.
v instruction, 1st address register is used to read the contents (pointer) of * a to the 2nd address register, mov instruction, 2nd address register is used to read the data pointed to by the pointer to the data register Three instructions, mov instruction, are selected. The first and second
Address registers A0 and A1 are assigned. This is entered in the symbol table.
【0044】<個別命令の生成>さらに、コード生成
部7は、これらの複数の命令の中から処理すべき命令
(個別命令)を1つ指定し(ステップ24)、個別命令
に対する命令コードを生成する(ステップ25)。こ
のステップ25における個別命令の命令コード生成を
図3〜6のフローを用いて具体的に説明する。<Generation of Individual Instruction> Further, the code generator 7 designates one instruction (individual instruction) to be processed from these plural instructions (step 24) and generates an instruction code for the individual instruction. (Step 25). The instruction code generation of the individual instruction in step 25 will be specifically described with reference to the flows of FIGS.
【0045】コード生成部7は、ステップ24で指定さ
れた個別命令がメモリアクセスするロード/ストア命
令でなく(図3のステップ30)、レジスタA0を使用す
る命令であるのでレジスタ管理部10にその旨通知する
(ステップ31)。レジスタ管理部10は、シンボルテ
ーブルを参照し(図5のステップ50)、レジスタA0に
格納すべき変数がポインタであることから(ステップ5
1)、レジスタの全24ビットが有効となる命令を生成
すべきことをコード生成部7に対して指示する(ステッ
プ53)。Since the individual instruction designated in step 24 is not the load / store instruction for accessing the memory (step 30 in FIG. 3) but the instruction using the register A0, the code generator 7 informs the register manager 10 of the instruction. To that effect (step 31). The register management unit 10 refers to the symbol table (step 50 in FIG. 5), and the variable to be stored in the register A0 is a pointer (step 5).
1) Instruct the code generation unit 7 to generate an instruction in which all 24 bits of the register are valid (step 53).
【0046】さらに、コード生成部7は、個別命令が
即値データを用いるので即値管理部11にその旨通知す
る(ステップ32)。即値管理部11は、シンボルテー
ブルを参照し(図6のステップ60)、レジスタA0に格
納すべき即値がポインタであることから(ステップ6
1)、3バイトの即値データを有する命令を生成すべき
ことをコード生成部7に対して指示する(ステップ6
3)。Furthermore, since the individual instruction uses immediate data, the code generator 7 notifies the immediate management unit 11 of that (step 32). The immediate value management unit 11 refers to the symbol table (step 60 in FIG. 6), and the immediate value to be stored in the register A0 is a pointer (step 6).
1) Instruct the code generation unit 7 to generate an instruction having 3-byte immediate data (step 6)
3).
【0047】ステップ53、63からの指示に従って、
コード生成部7は、個別命令に対応する、次に示す命
令1を生成する(ステップ33)。 命令1: MOV #001000,A0 この後コード生成部7は、ステップ23で選定された複
数命令のうち、次の命令コードを生成すべき命令、
が残っているので(ステップ26)、ステップ24に進
む。In accordance with the instructions from steps 53 and 63,
The code generator 7 generates the following instruction 1 corresponding to the individual instruction (step 33). Instruction 1: MOV # 001000, A0 After that, the code generation unit 7 is to generate the next instruction code among the plurality of instructions selected in step 23,
Remains (step 26), the process proceeds to step 24.
【0048】<個別命令の生成>コード生成部7は、
これらの複数の命令の中から処理すべき命令(個別命
令)を1つ指定し(ステップ24)、個別命令に対す
る命令コードを生成する(ステップ25)。このステッ
プ25における個別命令の命令コード生成を図3〜6
のフローを用いて具体的に説明する。<Generation of Individual Instruction> The code generation section 7
One instruction (individual instruction) to be processed is designated from these plural instructions (step 24), and an instruction code for the individual instruction is generated (step 25). The instruction code generation of the individual instruction in this step 25 is shown in FIGS.
A specific description will be given using the flow.
【0049】コード生成部7は、個別命令がメモリア
クセスするロード/ストア命令であるので、メモリ管理
部9にその旨通知する(図3のステップ30)。メモリ
管理部9は、シンボルテーブルを参照し(図4のステッ
プ40)、第2のレジスタA1に格納すべき変数がポイン
タであることから(ステップ41)、メモリアクセスに
おけるアクセス幅が3バイトであるロード命令を生成す
べきことをコード生成部7に対して指示する(ステップ
43)。Since the individual instruction is a load / store instruction for accessing the memory, the code generating section 7 notifies the memory managing section 9 to that effect (step 30 in FIG. 3). The memory management unit 9 refers to the symbol table (step 40 in FIG. 4), and since the variable to be stored in the second register A1 is the pointer (step 41), the access width in memory access is 3 bytes. The code generation unit 7 is instructed that a load instruction should be generated (step 43).
【0050】さらに、コード生成部7は、個別命令が
レジスタA0、A1を使用する命令であるのでレジスタ管理
部10にその旨通知する(ステップ31)。レジスタ管
理部10は、シンボルテーブルを参照し(図5のステッ
プ50)、第2のレジスタA1に格納すべき変数がポイン
タであることから(ステップ51)、レジスタの全24
ビットが有効となる命令を生成すべきことをコード生成
部7に対して指示する(ステップ53)。Furthermore, since the individual instruction is an instruction that uses the registers A0 and A1, the code generation unit 7 notifies the register management unit 10 to that effect (step 31). The register management unit 10 refers to the symbol table (step 50 in FIG. 5), and the variable to be stored in the second register A1 is a pointer (step 51).
The code generation unit 7 is instructed to generate an instruction whose bit is valid (step 53).
【0051】この後、コード生成部7は、個別命令が
即値データを用いないので(ステップ32)、ステップ
33に進む。ステップ43、53からの指示に従って、
コード生成部7は個別命令に対応する、次に示す命令
2を生成する(ステップ33)。 命令2: MOV @A0,A1 この後コード生成部7は、ステップ23で選定された複
数命令のうち、次の命令コードを生成すべき命令が残
っているので(ステップ26)、ステップ24に進む。After that, the code generator 7 proceeds to step 33 because the individual instruction does not use immediate data (step 32). Follow the instructions from steps 43 and 53
The code generator 7 generates the following instruction 2 corresponding to the individual instruction (step 33). Instruction 2: MOV @ A0, A1 After that, the code generation unit 7 proceeds to step 24 because there is an instruction to generate the next instruction code among the plurality of instructions selected in step 23 (step 26). .
【0052】<個別命令の生成>個別命令について
も上記と同様にして、コード生成部7は次の命令3を生
成する(ステップ24〜26)。この時点で、一時変数
t1には、D0レジスタが割り当てられている。 命令3: MOV @A1,D0 以下、上記と同様にして、ステップ21〜26のループ
において各中間命令の処理が、ステップ24、25(図
3、4のフロー)、26において各個別命令の処理が行
われるので、詳細な説明は省略して概要を示す。<Generation of Individual Instruction> For the individual instruction as well, the code generator 7 generates the next instruction 3 (steps 24 to 26). At this point, the temporary variable
The D0 register is assigned to t1. Instruction 3: MOV @ A1, D0 Hereinafter, in the same manner as above, the processing of each intermediate instruction in the loop of steps 21 to 26 is the processing of each individual instruction in steps 24, 25 (flow of FIGS. 3 and 4), and 26. Therefore, a detailed description is omitted and an outline is shown.
【0053】<< 中間命令2:t2:=t1+b >>この中間命令
は、「変数bが割り当てられている1004番地から2バ
イト読み出して、その内容と一時変数t1とを加算して
一時変数t2に格納する。」ことを内容とする。まず、コ
ード生成部7は、個別命令に対応してA0レジスタの内
容が示す1000番地から4番地離れた番地をロードする命
令4を生成する。その際、メモリ管理部9は、シンボル
テーブルを参照して(ステップ40)、個別命令4が整
数型データ変数をロードすることから(ステップ4
1)、アクセス幅が2バイトのロード命令を生成すべき
ことを指示する(ステップ42)。レジスタ管理部10
は、シンボルテーブルを参照して(ステップ50)、レ
ジスタに整数型データを格納するので(ステップ5
1)、レジスタの下位16ビットが有効となる命令を生
成すべきことを指示する(ステップ52)。この時点
で、レジスタD1には変数bが格納されている。<< Intermediate instruction 2: t2: = t1 + b >> This intermediate instruction reads "2 bytes from the address 1004 to which the variable b is allocated, and adds the content and the temporary variable t1 to the temporary It is stored in the variable t2. " First, the code generation unit 7 generates an instruction 4 for loading an address four addresses away from the address 1000 indicated by the contents of the A0 register, corresponding to an individual instruction. At this time, the memory management unit 9 refers to the symbol table (step 40) and the individual instruction 4 loads the integer type data variable (step 4).
1) Instruct that a load instruction having an access width of 2 bytes should be generated (step 42). Register management unit 10
Refers to the symbol table (step 50) and stores the integer type data in the register (step 5).
1) Instructing that an instruction in which the lower 16 bits of the register are valid should be generated (step 52). At this time, the variable b is stored in the register D1.
【0054】命令4: MOV @(04,A0),D1 次に、コード生成部7は、個別命令に対応してD1レジ
スタに格納された変数bと、D0レジスタの内容が示す一
時変数t1とを加算して、その結果をD1レジスタに格納す
る命令5を生成する。その際、レジスタ管理部10は、
シンボルテーブルを参照して(ステップ50)、レジス
タに整数型データを格納するので(ステップ51)、レ
ジスタの下位16ビットが有効となる命令を生成すべき
ことを指示する(ステップ52)。この時点で、一時変
数t2にはレジスタD1が割り当てられている。Instruction 4: MOV @ (04, A0), D1 Next, the code generator 7 stores a variable b stored in the D1 register corresponding to the individual instruction and a temporary variable t1 indicated by the contents of the D0 register. Is added and the instruction 5 for storing the result in the D1 register is generated. At that time, the register management unit 10
Since the integer type data is stored in the register by referring to the symbol table (step 50) (step 51), it is instructed to generate an instruction in which the lower 16 bits of the register are valid (step 52). At this point, the register D1 is assigned to the temporary variable t2.
【0055】命令5: ADD D0,D1 <<中間命令3:t3:=t2+1 >>この中間命令は、「一時
変数t2に1を加算して一時変数t3に格納する」ことを内
容とする。コード生成部7は、レジスタ管理部10、即
値管理部11の指示に従って、2バイトの即値#0001と
レジスタD1とを加算した結果をD1レジスタに格納する次
の命令6を生成する。この時点で、一時変数t3にはレジ
スタD1が割り当てられている。Instruction 5: ADD D0, D1 << Intermediate instruction 3: t3: = t2 + 1 >> This intermediate instruction has the content that "1 is added to temporary variable t2 and stored in temporary variable t3". To do. The code generation unit 7 generates the next instruction 6 for storing the result of adding the 2-byte immediate value # 0001 and the register D1 in the D1 register according to the instructions of the register management unit 10 and the immediate value management unit 11. At this point, the register D1 is assigned to the temporary variable t3.
【0056】命令6: ADD #0001,D1 <<中間命令4:c:=t3 >>この中間命令は「変数cが割
り当てられている1006番地から2バイトの領域に一時変
数t3を書き込む」ことを内容とする。コード生成部7
は、メモリ管理部9の指示に従って、レジスタA1の内容
が示す番地から6番地離れた番地にレジスタD1の内容を
ストアする次の命令7を生成する。Instruction 6: ADD # 0001, D1 << Intermediate instruction 4: c: = t3 >> This intermediate instruction is to write the temporary variable t3 in the area of 2 bytes from the address 1006 to which the variable c is allocated. Is the content. Code generator 7
In accordance with an instruction from the memory management unit 9, generates the next instruction 7 for storing the contents of the register D1 at an address 6 apart from the address indicated by the contents of the register A1.
【0057】命令7: MOV D1,@(06,A0) 上記のようにして各中間命令の処理が終了する。その結
果、コード生成部7から次のようなオブジェクトコード
がメモリ13に対して出力される。メモリ13上で、命
令1から命令7はそれぞれ、100000番地、100005番地、
100007番地、100008番地、10000a番地、10000b番地、10
000f番地に配置されるものとする。Instruction 7: MOV D1, @ (06, A0) As described above, the processing of each intermediate instruction is completed. As a result, the code generator 7 outputs the following object code to the memory 13. On the memory 13, the instruction 1 to the instruction 7 are 100000, 100005,
100007, 100008, 10000a, 10000b, 10
It will be located at address 000f.
【0058】 命令1: 100000番地 MOV #001000,A0 命令2: 100005番地 MOV @A0,A1 命令3: 100007番地 MOV @A1,D0 命令4: 100008番地 MOV @(04,A0),D1 命令5: 10000a番地 ADD D0,D1 命令6: 10000b番地 ADD #0001,D1 命令7: 10000f番地 MOV D1,@(06,A0) これらの命令は、オブジェクトコードを便宜上ニモニッ
ク(アセンブリ言語)で表現したものであり、メモリ1
3に格納される際は2進数で表される。上記の数値はす
べて16進数である。以下、メモリ13に配置されたこ
のオブジェクトコードについて、マイクロコンピュータ
により実行される動作を説明する。Instruction 1: Address 100000 MOV # 001000, A0 Instruction 2: Address 100005 MOV @ A0, A1 Instruction 3: Address 100007 MOV @ A1, D0 Instruction 4: Address 100008 MOV @ (04, A0), D1 Instruction 5: Address 10000a ADD D0, D1 Instruction 6: Address 10000b ADD # 0001, D1 Instruction 7: Address 10000f MOV D1, @ (06, A0) These instructions represent the object code in mnemonic (assembly language) for convenience. , Memory 1
When stored in 3, it is represented by a binary number. All of the above numbers are hexadecimal numbers. The operation executed by the microcomputer for this object code arranged in the memory 13 will be described below.
【0059】(命令1:100000番地 MOV #001000,A0
)バス制御回路16および命令制御回路17は、プロ
グラムカウンタ19が保持している値100000をアドレス
バス14に出力し、データバス15を介して命令1をフ
ェッチして解読する。解読結果に従って演算実行回路1
8は、命令1のオペランドで指定されている即値001000
を命令制御回路17から受け取り、レジスタファイル2
0の中のA0レジスタに格納する。(Instruction 1: Address 100000 MOV # 001000, A0
The bus control circuit 16 and the instruction control circuit 17 output the value 100000 held by the program counter 19 to the address bus 14 and fetch the instruction 1 via the data bus 15 to decode it. Operation execution circuit 1 according to the decoding result
8 is the immediate value 001000 specified by the operand of instruction 1
Is received from the instruction control circuit 17, and the register file 2
Store in A0 register in 0.
【0060】(命令2:100005番地 MOV @A0,A1 )バ
ス制御回路16および命令制御回路17は、同様にし
て、命令2をフェッチして解読する。演算実行回路18
は、A0レジスタの内容を読み出し、それをアドレスバス
14に出力してメモリ13を読み出し、データバス15
を介して読み出された16ビットのデータをA1レジスタ
の下位16ビットに格納する。続いて、演算実行回路1
8は、演算器21によりA0レジスタの値001000に2を加
算し、バス制御回路16により加算結果001002をアドレ
スバス14に出力してメモリ13を読み出し、データバ
ス15を介して読み出された8ビットのデータをA1レジ
スタの上位8ビットに格納する。(Instruction 2: Address 100005 MOV @ A0, A1) The bus control circuit 16 and the instruction control circuit 17 similarly fetch and decode the instruction 2. Calculation execution circuit 18
Reads the contents of the A0 register, outputs it to the address bus 14, reads the memory 13, and
The 16-bit data read out via is stored in the lower 16 bits of the A1 register. Subsequently, the arithmetic execution circuit 1
8 is read by the arithmetic unit 21 by adding 2 to the value 001000 of the A0 register, outputting the addition result 001002 to the address bus 14 by the bus control circuit 16, reading the memory 13, and reading via the data bus 15. Store the bit data in the upper 8 bits of the A1 register.
【0061】(命令3:100007番地 MOV @A1,D0 )バ
ス制御回路16および命令制御回路17は、命令3をフ
ェッチして解読する。演算実行回路18は、A1レジスタ
の内容を読み出し、それをアドレスバス14に出力し、
メモリ13を読み出す。その後演算実行回路18は、デ
ータバス15を介して読み出された16ビットの値をD0
レジスタの下位16ビットに格納する。D0レジスタは、
ポインタ変数*aが指し示すデータを保持することにな
る。(Instruction 3: Address 100007 MOV @ A1, D0) The bus control circuit 16 and the instruction control circuit 17 fetch and decode the instruction 3. The arithmetic execution circuit 18 reads the contents of the A1 register and outputs it to the address bus 14,
The memory 13 is read. After that, the arithmetic execution circuit 18 sets the 16-bit value read via the data bus 15 to D0.
Store in the lower 16 bits of the register. The D0 register is
It will hold the data pointed to by the pointer variable * a.
【0062】(命令4:100008番地 MOV @(04,A0),D1
)バス制御回路16および命令制御回路17は、命令
4をフェッチして解読する。演算実行回路18は、変位
値04を命令制御回路17から受け取り、演算器21にお
いて読み出されたA0レジスタの値001000と加算し、加算
結果001004をバス制御回路16によりアドレスバス14
に出力しメモリ13の読み出しを行う。その後演算実行
回路18は、データバス15に読み出された16ビット
の値をレジスタファイル20の中のD1レジスタの下位1
6ビットに格納する。D1レジスタは、変数bを保持する
ことになる。(Instruction 4: Address 100008 MOV @ (04, A0), D1
) Bus control circuit 16 and instruction control circuit 17 fetch and decode instruction 4. The arithmetic execution circuit 18 receives the displacement value 04 from the instruction control circuit 17, adds it to the value 001000 of the A0 register read by the arithmetic unit 21, and adds the addition result 001004 to the address bus 14 by the bus control circuit 16.
To the memory 13 for reading. After that, the operation execution circuit 18 uses the lower 16 bits of the D1 register in the register file 20 to read the 16-bit value read on the data bus 15.
Store in 6 bits. The D1 register will hold the variable b.
【0063】(命令5:10000a番地 ADD D0,D1 )バ
ス制御回路16および命令制御回路17は、命令5をフ
ェッチして解読する。演算実行回路18は、演算器21
においてレジスタファイル20から読み出されたD0レジ
スタの値とD1レジスタの値とを加算し、加算結果をレジ
スタファイル20の中のD1レジスタに格納する。演算器
21はこの加算を24ビットで行うが、D1レジスタは下
位16ビットが有効である。D1レジスタは、ポインタ変
数*aが示すデータと変数bとの加算値を保持することに
なる。(Instruction 5: Address 10000a ADD D0, D1) The bus control circuit 16 and the instruction control circuit 17 fetch and decode the instruction 5. The arithmetic execution circuit 18 includes an arithmetic unit 21.
The value of the D0 register read from the register file 20 and the value of the D1 register are added, and the addition result is stored in the D1 register in the register file 20. The arithmetic unit 21 performs this addition with 24 bits, but the lower 16 bits of the D1 register are effective. The D1 register holds the added value of the data indicated by the pointer variable * a and the variable b.
【0064】(命令6:10000b番地 ADD #0001,D1 )
バス制御回路16および命令制御回路17は、命令6を
フェッチして解読する。演算実行回路18は、演算器2
1においてレジスタファイル20から読み出されたD1レ
ジスタの値と、命令制御回路17から受け取った即値00
01とを加算し、加算結果をD1レジスタに格納する。D1レ
ジスタは、ポインタ変数*aが示すデータと変数bと即値0
001との加算値を保持することになる。(Instruction 6: Address 10000b ADD # 0001, D1)
The bus control circuit 16 and the instruction control circuit 17 fetch and decode the instruction 6. The arithmetic execution circuit 18 is the arithmetic unit 2
1, the value of the D1 register read from the register file 20 and the immediate value 00 received from the instruction control circuit 17
01 and are added, and the addition result is stored in the D1 register. The D1 register stores the data indicated by the pointer variable * a, the variable b, and the immediate value 0.
The added value with 001 will be retained.
【0065】(命令7:10000f番地 MOV D1,@(06,A0)
)バス制御回路16および命令制御回路17は、命令
7をフェッチして解読する。演算実行回路18は、変位
置06を命令制御回路17から受け取り、演算器21にお
いてレジスタファイル20から読み出されたA0レジスタ
の値001000と加算し、加算結果001006をバス制御回路1
6によりデータバス15に出力するとともに、D1レジス
タの下位16ビットの値をデータバス15に出力し、メ
モリ13に対して16ビットデータの書き込みを行う。
メモリ13の001006番地には、ポインタ変数*aが示すデ
ータと変数bと即値0001との加算値が書き込まれること
になる。(Instruction 7: Address 10000f MOV D1, @ (06, A0)
The bus control circuit 16 and the instruction control circuit 17 fetch and decode the instruction 7. The arithmetic execution circuit 18 receives the variable position 06 from the instruction control circuit 17, adds it to the value 001000 of the A0 register read from the register file 20 in the arithmetic unit 21, and adds the addition result 001006 to the bus control circuit 1.
6 outputs the lower 16 bits of the D1 register to the data bus 15 and outputs 16 bits of data to the memory 13.
At the address 001006 of the memory 13, the data indicated by the pointer variable * a, the added value of the variable b and the immediate value 0001 will be written.
【0066】このようにしてC言語プログラムがコンパ
イラ2で翻訳されて生成されたオブジェクトコードが、
ハードウェア3で実行される。以上のように本実施例に
よれば、コンパイラ2が全ての変数と生成するオブジェ
クトコードとのメモリ上での配置を24ビットのアドレ
スで管理し、マイクロコンピュータが24ビットのレジ
スタファイル20および演算器21でこれらのアドレス
を計算し24ビットのアドレスバス14でメモリ13を
アクセスするため、本実施例の情報処理装置はセグメン
トに分割しない全く均一な16メガバイトのアドレス空
間を実現することができ、従ってC言語プログラムを記
述するプログラマはセグメントの境界のような空間の不
均一性を認識する必要がなく、またセグメントレジスタ
の操作のようなアドレス計算での性能劣化も発生しな
い。それに伴ってプログラムの開発効率も向上する。The object code generated by the C language program being translated by the compiler 2 in this way is
It is executed by hardware 3. As described above, according to the present embodiment, the compiler 2 manages the arrangement of all variables and the generated object code on the memory with the 24-bit address, and the microcomputer manages the 24-bit register file 20 and the arithmetic unit. Since these addresses are calculated by 21 and the memory 13 is accessed by the 24-bit address bus 14, the information processing apparatus of this embodiment can realize a completely uniform 16-megabyte address space which is not divided into segments, and A programmer who writes a C language program does not need to recognize spatial nonuniformity such as segment boundaries, and does not suffer performance degradation in address calculation such as segment register manipulation. Along with that, the development efficiency of the program is improved.
【0067】また、データのビット幅が16ビットで1
6メガバイトのアドレス空間を必要とする応用にとっ
て、本実施例の情報処理装置は、マイクロコンピュータ
が24ビットのレジスタファイル20および演算器21
で構成されるため、従来の32ビットプロセッサのよう
に過分なハードウェアによってコストおよび消費電力が
増大することがない。When the bit width of data is 16 bits, 1
For applications requiring an address space of 6 megabytes, the information processing apparatus according to the present embodiment has a 24-bit register file 20 and an arithmetic unit 21 for a microcomputer.
The cost and power consumption do not increase due to excessive hardware unlike the conventional 32-bit processor.
【0068】また、マイクロコンピュータの機械語命令
の基本語長は8ビットであり、上記の命令1のように命
令中にアドレスの即値が伴う場合でもその即値は最大で
も24ビットとなるため、コンパイラ2が生成するオブ
ジェクトコードは、機械語命令の基本語長を16または
32ビットとしアドレスの即値が最大32ビットとなる
32ビットプロセッサの情報処理装置に比べて極めて小
さくなる。また64キロバイトのアドレス空間しか扱え
ない16ビットプロセッサに比べても、コードサイズの
増加の要因が命令に伴うアドレスの即値による最大1バ
イトだけであるため、オブジェクトコードのサイズはほ
とんど大きくならない。Further, the basic word length of the machine language instruction of the microcomputer is 8 bits, and even when the immediate value of the address is included in the instruction as in the above-mentioned instruction 1, the immediate value is at most 24 bits, so the compiler The object code generated by 2 is extremely small as compared with an information processing device of a 32-bit processor in which the basic word length of a machine language instruction is 16 or 32 bits and the immediate value of an address is 32 bits at maximum. Further, even if compared with a 16-bit processor that can handle only an address space of 64 kilobytes, the cause of the increase in code size is only 1 byte at maximum due to the immediate value of the address associated with the instruction, so the size of the object code does not become large.
【0069】本実施例のマイクロコンピュータのデータ
バス15の幅は16ビットであるが、これを24ビット
とした場合と比べると、レジスタファイル20に格納さ
れた24ビットのアドレスに関する値をメモリ13に対
して読み書きする時のみ実行時間が長くなるだけであ
り、この性能の低下は、メモリに対して常に32ビット
で読み書きする32ビットプロセッサの情報処理装置の
データバスのビット幅を16ビットにした場合に比べて
極めて小さい。The width of the data bus 15 of the microcomputer of this embodiment is 16 bits. Compared with the case where this is 24 bits, the value relating to the 24-bit address stored in the register file 20 is stored in the memory 13. However, the execution time only increases when reading and writing, and this performance degradation occurs when the bit width of the data bus of the information processing device of the 32-bit processor that always reads and writes in 32 bits to the memory is 16 bits. Very small compared to.
【0070】なお、本実施例は、マイクロコンピュータ
のアドレスバス14、プログラムカウンタ19、レジス
タファイル20および演算器21のビット幅を24ビッ
トとし、コンパイラ2のパラメータ設定部8のポインタ
変数のビット幅を24ビットに設定しているが、これら
を必要とするアドレス空間の広さに対応して17ビット
から31ビットの任意のビット幅にしてもよい。対応は
次のようになる。In this embodiment, the bit width of the address bus 14, the program counter 19, the register file 20 and the arithmetic unit 21 of the microcomputer is set to 24 bits, and the bit width of the pointer variable of the parameter setting section 8 of the compiler 2 is set to 24 bits. Although it is set to 24 bits, it may be set to an arbitrary bit width of 17 bits to 31 bits corresponding to the width of the required address space. The correspondence is as follows.
【0071】 必要なアドレス空間 ビット幅 128キロバイト 17ビット 256キロバイト 18ビット 512キロバイト 19ビット 1メガバイト 20ビット 2メガバイト 21ビット 4メガバイト 22ビット 8メガバイト 23ビット 16メガバイト 24ビット(本実施例) 32メガバイト 25ビット 64メガバイト 26ビット 128メガバイト 27ビット 256メガバイト 28ビット 512メガバイト 29ビット 1ギガバイト 30ビット 2ギガバイト 31ビット このようにすることにより、アドレスのビット幅を超す
過分なハードウェアがなくなり、応用に応じてコストお
よび消費電力の最適化を図ることができる。Required address space Bit width 128 kilobytes 17 bits 256 kilobytes 18 bits 512 kilobytes 19 bits 1 megabyte 20 bits 2 megabytes 21 bits 4 megabytes 22 bits 8 megabytes 23 bits 16 megabytes 24 bits (this embodiment) 32 megabytes 25 bits 64 megabytes 26 bits 128 megabytes 27 bits 256 megabytes 28 bits 512 megabytes 29 bits 1 gigabyte 30 bits 2 gigabytes 31 bits By doing this, there is no excessive hardware that exceeds the bit width of the address, and cost and The power consumption can be optimized.
【0072】また本実施例は、マイクロコンピュータの
データバス15の幅を16ビットとしているが、これを
24ビットとしてもよい。また本実施例は、マイクロコ
ンピュータのアドレスバス14、プログラムカウンタ1
9、レジスタファイル20および演算器21のビット幅
とコンパイラ2のパラメータ設定部8のポインタ変数の
ビット幅の設定値とを24ビットとし、コンパイラ2の
パラメータ設定部8のデータ変数のビット幅の設定値を
16ビットとしているが、これらのビット幅を限定する
ものではない。後者をプログラムが主として扱う型のデ
ータのビット幅(Mとする)と等しくし、前者をMより
大きい値(Nとする)とすることにより、情報処理装置
は、主として扱う型のデータのビット幅で表現できる2
のM乗バイトの空間を越える2のN乗バイトのアドレス
空間を扱うことができる。Although the width of the data bus 15 of the microcomputer is 16 bits in this embodiment, it may be 24 bits. In addition, the present embodiment is based on the address bus 14 and the program counter 1
9. The bit width of the register file 20 and the arithmetic unit 21 and the setting value of the bit width of the pointer variable of the parameter setting unit 8 of the compiler 2 are set to 24 bits, and the bit width of the data variable of the parameter setting unit 8 of the compiler 2 is set. Although the value is set to 16 bits, these bit widths are not limited. By setting the latter to be equal to the bit width of the type of data mainly handled by the program (denoted by M) and the former by a value larger than M (denoted by N), the information processing apparatus causes the bit width of the type of data primarily handled by the program. 2 that can be expressed by
It is possible to handle an address space of 2 N power bytes that exceeds the space of M power bytes of.
【0073】また本実施例は、パラメータ設定部8でビ
ット幅を設定するデータ変数の型を整数型としている
が、これをC言語プログラムで主として扱うデータの型
に合わせていかなる型にしてもよい。また本実施例は、
C言語プログラムをコンパイルして実行するものである
が、言語を限定するものではない。コンパイラ2をプロ
グラムの記述言語に対応させることにより、情報処理装
置はいかなる言語のプログラムでも実行できる。Further, in the present embodiment, the type of the data variable for setting the bit width in the parameter setting unit 8 is an integer type, but this may be any type according to the type of data mainly handled by the C language program. . In addition, this embodiment is
The C language program is compiled and executed, but the language is not limited. By making the compiler 2 correspond to the description language of the program, the information processing device can execute the program of any language.
【0074】[0074]
【発明の効果】以上説明してきたたように本発明によれ
ば、パラメータ設定手段にデータ幅及びポインタ幅を任
意に設定できるので、プログラマにセグメントの境界の
ような空間の不均一性を認識させることなく、かつセグ
メントレジスタの操作のようなアドレス計算での性能劣
化をも伴うことなく、主として扱う型のデータのビット
幅で表現できる空間を超える広さの任意のアドレス空間
を扱うことができるという効果がある。As described above, according to the present invention, since the data width and the pointer width can be set arbitrarily in the parameter setting means, the programmer is made to recognize the spatial nonuniformity such as the segment boundary. It is possible to handle an arbitrary address space that is larger than the space that can be represented by the bit width of the data of the type to be handled, without causing the performance degradation in address calculation such as the operation of the segment register. effective.
【0075】また、組み込み用途のマイクロコンピュー
タでの応用(アプリケーション)おいては、データのビ
ット幅が16ビット必要で、かつ、アドレス空間が64
キロバイト以上を必要とするが4ギガバイトもの大きさ
を必要としないものに対して最適化を図ることができる
という効果がある。また本発明によれば、従来の32ビ
ットプロセッサの情報処理装置に比べてプログラムのコ
ードサイズが小さく、またデータバスのビット幅が16
ビットの場合でも性能劣化がほとんどない情報処理装置
を実現できるという効果がある。In addition, in the application (application) of the microcomputer for embedded use, the data bit width is required to be 16 bits, and the address space is 64 bits.
There is an effect that optimization can be achieved for a device that requires more than kilobytes but does not require a size of 4 gigabytes. Further, according to the present invention, the code size of the program is smaller than that of the conventional 32-bit processor information processing apparatus, and the bit width of the data bus is 16.
Even in the case of bits, there is an effect that it is possible to realize an information processing device with almost no performance degradation.
【図1】本発明の実施例における情報処理装置のブロッ
ク図である。FIG. 1 is a block diagram of an information processing apparatus according to an embodiment of the present invention.
【図2】同実施例におけるコード生成部7の処理フロー
を示す。FIG. 2 shows a processing flow of a code generation unit 7 in the embodiment.
【図3】同実施例におけるコード生成部7の処理フロー
のうち個別処理のフローを示す。FIG. 3 shows a flow of individual processing in a processing flow of a code generation unit 7 in the same embodiment.
【図4】同実施例におけるメモリ管理部9の処理フロー
を示す。FIG. 4 shows a processing flow of a memory management unit 9 in the embodiment.
【図5】同実施例におけるレジスタ管理部10の処理フ
ローを示す。FIG. 5 shows a processing flow of a register management unit 10 in the embodiment.
【図6】同実施例における即値管理部11の処理フロー
を示す。FIG. 6 shows a processing flow of an immediate value management unit 11 in the same embodiment.
【図7】同実施例におけるシンボルテーブルを示す。FIG. 7 shows a symbol table in the embodiment.
1 記憶装置 2 コンパイラ 3 ハードウェア 5 構文解析部 7 コード生成部 8 パラメータ設定部 9 メモリ管理部 10 レジスタ管理部 11 即値管理部 13 メモリ 14 アドレスバス 15 データバス 16 バス制御回路 17 命令制御回路 18 演算実行回路 19 プログラムカウンタ 20 レジスタファイル 21 演算器 1 storage device 2 compiler 3 hardware 5 syntax analysis unit 7 code generation unit 8 parameter setting unit 9 memory management unit 10 register management unit 11 immediate value management unit 13 memory 14 address bus 15 data bus 16 bus control circuit 17 instruction control circuit 18 operation Execution circuit 19 Program counter 20 Register file 21 Operation unit
Claims (5)
幅Mよりも長いビット幅Nをもつアドレスを扱うプロセ
ッサを対象とし、高級言語プログラムに基づいて機械語
命令を生成するプログラム変換装置であって、 主たるデータの型における有効なビット幅およびアドレ
スのビット幅を保持するパラメータ保持手段と、 生成すべき機械語命令で用いられる変数が、データを表
す変数である場合、パラメータ保持手段が保持するデー
タのビット幅を有効とする命令を生成し、アドレスを表
す変数である場合、パラメータ保持手段が保持するアド
レスのビット幅を有効とする命令を生成する生成手段と
を備えたことを特徴とするプログラム変換装置。1. A program conversion device for generating a machine language instruction based on a high-level language program for a processor handling an address having a bit width N longer than an effective bit width M in a main data type, When the parameter holding means that holds the effective bit width and the bit width of the address in the main data type and the variable used in the machine language instruction to be generated are variables that represent data, A program conversion, comprising: a generating unit that generates an instruction that validates a bit width, and generates an instruction that validates the bit width of an address held by a parameter holding unit when the variable represents an address. apparatus.
とを特徴とする請求項1記載のプログラム変換装置。2. The program conversion device according to claim 1, wherein the bit width M of the data is 16, and the bit width N of the address is 17 or more and 31 or less.
る場合に、アクセス対象となる変数がデータであるかア
ドレスであるかに応じて、パラメータ保持手段に保持さ
れた対応するビット幅をアクセス幅とすべきことを指示
するメモリ管理手段と、 生成すべき機械語命令がレジスタを使用する命令である
場合に、そのレジスタにリード又はライトされる変数が
データであるかアドレスであるか応じて、パラメータ保
持手段に保持された対応するビット幅を有効とすべきこ
とを指示するレジスタ管理手段と、 生成すべき機械語命令が即値を使用する命令である場合
にその即値がデータであるかアドレスであるか応じて、
パラメータ保持手段に保持された対応するビット幅の即
値を用いるべきことを指示する即値管理手段とメモリ管
理手段、レジスタ管理手段及び即値管理手段からの指示
に従って、機械語命令を生成するコード生成手段とから
なることを特徴とする請求項1又は2記載のプログラム
変換装置。3. When the machine language instruction to be generated is an instruction to access a memory, the generating means holds it in the parameter holding means according to whether the variable to be accessed is data or address. If the machine language instruction to be generated is an instruction that uses a register, the variable that is read or written in the register is data. Depending on whether it is an address or an address, register management means for instructing that the corresponding bit width held in the parameter holding means should be valid, and the machine language instruction to be generated is an instruction using an immediate value. Depending on whether the immediate value is data or an address,
An immediate value management means for instructing to use the immediate value of the corresponding bit width held in the parameter holding means, and a code generation means for generating a machine language instruction in accordance with instructions from the memory management means, the register management means and the immediate value management means 3. The program conversion device according to claim 1, comprising:
グラム変換装置により生成されたプログラムを実行する
プロセッサであって、 Nビット長のプログラムカウンタと、 Nビット長の演算、及びデータのビット幅であるMビッ
ト長の演算を実行する実行手段とを備えたことを特徴と
するプロセッサ。4. A processor for executing a program generated by the program conversion device according to claim 1, comprising a program counter having an N-bit length, an operation having an N-bit length, and a bit width of data. And an executing means for executing an operation of M bit length.
求項3記載のプロセッサ。5. The processor of claim 3, wherein N is 24.
Priority Applications (13)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP12621293A JP2875711B2 (en) | 1993-05-27 | 1993-05-27 | Program conversion device and processor |
EP02076028A EP1229440B1 (en) | 1993-05-27 | 1994-05-27 | Program converting unit and processor improved in address management |
DE69434971T DE69434971T2 (en) | 1993-05-27 | 1994-05-27 | Program Implementation Unit |
EP94303862A EP0626641B1 (en) | 1993-05-27 | 1994-05-27 | Processor improved in address management |
EP04075265A EP1416374A3 (en) | 1993-05-27 | 1994-05-27 | Program converting unit and processor improved in address management |
DE69434967T DE69434967T2 (en) | 1993-05-27 | 1994-05-27 | Program conversion unit and improved addressing processor |
DE69432445T DE69432445T2 (en) | 1993-05-27 | 1994-05-27 | Improved processor for addressing |
EP01202455A EP1164479B1 (en) | 1993-05-27 | 1994-05-27 | Program converting unit |
EP02076025A EP1229439A3 (en) | 1993-05-27 | 1994-05-27 | Program converting unit and processor improved in address management |
US08/587,338 US5809306A (en) | 1993-05-27 | 1996-01-16 | Variable address length compiler and processor improved in address management |
US09/662,484 USRE41959E1 (en) | 1993-05-27 | 2000-09-14 | Variable address length compiler and processor improved in address management |
US10/991,367 USRE40498E1 (en) | 1993-05-27 | 2004-11-19 | Variable address length compiler and processor improved in address management |
US11/607,889 US20080320454A1 (en) | 1993-05-27 | 2006-12-04 | Variable address length compiler and processor improved in address management |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP12621293A JP2875711B2 (en) | 1993-05-27 | 1993-05-27 | Program conversion device and processor |
Publications (2)
Publication Number | Publication Date |
---|---|
JPH06337791A true JPH06337791A (en) | 1994-12-06 |
JP2875711B2 JP2875711B2 (en) | 1999-03-31 |
Family
ID=14929508
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP12621293A Expired - Lifetime JP2875711B2 (en) | 1993-05-27 | 1993-05-27 | Program conversion device and processor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2875711B2 (en) |
-
1993
- 1993-05-27 JP JP12621293A patent/JP2875711B2/en not_active Expired - Lifetime
Also Published As
Publication number | Publication date |
---|---|
JP2875711B2 (en) | 1999-03-31 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10514922B1 (en) | Transfer triggered microcontroller with orthogonal instruction set | |
KR100328162B1 (en) | Information Processing Circuits and Microcomputers and Electronic Devices | |
USRE41959E1 (en) | Variable address length compiler and processor improved in address management | |
US4293907A (en) | Data processing apparatus having op-code extension register | |
US5249280A (en) | Microcomputer having a memory bank switching apparatus for accessing a selected memory bank in an external memory | |
KR20010043826A (en) | Microcontroller instruction set | |
US6687808B2 (en) | Data processor using indirect register addressing | |
KR100272622B1 (en) | Data processing device | |
JP2004086837A (en) | Data processor | |
KR19990036893A (en) | Processor Architecture for Execution of Multiple Addressing Modes and Its Design Method | |
JP3106060B2 (en) | Signal processor | |
US4691282A (en) | 16-bit microprocessor system | |
KR19990037573A (en) | Processor architecture and instruction set to maximize available opcodes and execute various addressing modes | |
EP0206653A2 (en) | Method and means for loading and storing data in a reduced instruction set computer | |
KR100960095B1 (en) | Microcontroller Instruction Set | |
US6886159B2 (en) | Computer system, virtual machine, runtime representation of object, storage media and program transmission apparatus | |
JPH06337792A (en) | Program converting device and processor | |
JPH06337791A (en) | Program converting device and processor | |
EP0180077B1 (en) | A data processing machine for compiling computer programs | |
KR100897857B1 (en) | Microcontroller instruction set | |
JP3345050B2 (en) | Two-dimensional array type memory system | |
JPH09505428A (en) | Microcontroller with page address mode | |
JPS62107339A (en) | Instruction constituting method for microcomputer | |
JPH0666052B2 (en) | A computer that automatically maps memory contents to machine registers | |
US5479632A (en) | Microcomputer having two-level memory to facilitate calculation of effective addresses |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Year of fee payment: 9 Free format text: PAYMENT UNTIL: 20080114 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090114 Year of fee payment: 10 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20090114 Year of fee payment: 10 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Year of fee payment: 11 Free format text: PAYMENT UNTIL: 20100114 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Year of fee payment: 12 Free format text: PAYMENT UNTIL: 20110114 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110114 Year of fee payment: 12 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Year of fee payment: 13 Free format text: PAYMENT UNTIL: 20120114 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Year of fee payment: 14 Free format text: PAYMENT UNTIL: 20130114 |
|
FPAY | Renewal fee payment (prs date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20130114 Year of fee payment: 14 |
|
EXPY | Cancellation because of completion of term |