JP2008003867A - Microcomputer - Google Patents

Microcomputer Download PDF

Info

Publication number
JP2008003867A
JP2008003867A JP2006173053A JP2006173053A JP2008003867A JP 2008003867 A JP2008003867 A JP 2008003867A JP 2006173053 A JP2006173053 A JP 2006173053A JP 2006173053 A JP2006173053 A JP 2006173053A JP 2008003867 A JP2008003867 A JP 2008003867A
Authority
JP
Japan
Prior art keywords
memory
address
cpu
memory address
output
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
Application number
JP2006173053A
Other languages
Japanese (ja)
Inventor
Iwao Orii
巌 織井
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Toshiba Corp
Kioxia Systems Co Ltd
Original Assignee
Toshiba Corp
Toshiba Memory Systems Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Toshiba Corp, Toshiba Memory Systems Co Ltd filed Critical Toshiba Corp
Priority to JP2006173053A priority Critical patent/JP2008003867A/en
Publication of JP2008003867A publication Critical patent/JP2008003867A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Memory System (AREA)
  • Microcomputers (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To make it possible to expand the memory of a microcomputer without deteriorating performance or code efficiency by changing the ratio of sizes of memories for storing a program code and a data code at the stage of system development. <P>SOLUTION: An address translation circuit 102 is provided. Either an inputted address from a CPU 101 or an address formed by adding a bias value 130 is selected by an identifying signal 105 that identifies an instruction fetch of the CPU 101/data access. The memory size of the memory 103 is expanded by performing addressing of the program code region or the data code region of the memory 103. <P>COPYRIGHT: (C)2008,JPO&INPIT

Description

本発明は、メモリアクセス領域拡張回路技術に係わり、マイクロコンピュータに適用するのに好適な構成に関する。   The present invention relates to a memory access area expansion circuit technique and relates to a configuration suitable for application to a microcomputer.

マイクロコンピュータを搭載するシステムの機能向上に伴い、マイクロコンピュータの制御プログラムサイズが増加している。このため、マイクロコンピュータで使用できるメモリのサイズ拡張が求められている。   As the functions of a system equipped with a microcomputer improve, the control program size of the microcomputer has increased. For this reason, there is a demand for expanding the size of memory that can be used in a microcomputer.

メモリサイズの拡張をCPUのアドレス信号のビット数を増加させて実現する方法は、命令コードを含むシステム変更を伴うため変更作業量が多く、開発期間やコストが増加するなどの問題がある。   The method of realizing the expansion of the memory size by increasing the number of bits of the address signal of the CPU involves a problem that the amount of change work is large because the system change including the instruction code is involved, and the development period and cost increase.

このため、コスト増加を抑制しながらメモリサイズの拡張を実現する方法が提案され実装されている。   For this reason, a method for realizing expansion of the memory size while suppressing an increase in cost has been proposed and implemented.

図5は、メモリサイズの拡張を行なう従来のマイクロコンピュータの回路構成例の主要部分を示すブロック図である。このマイクロコンピュータ900は、CPU901と、制御レジスタ902と、アドレス変換器903と、プログラムやデータを格納するメモリ904等から構成される。CPU901から出力されるアドレスバス出力信号905は、制御レジスタ902とアドレス変換器903に入力される。制御レジスタ902から出力されるアドレス変換制御信号906は、アドレス変換器903に入力される。また、アドレス変換器903から出力されるメモリアドレスバス入力信号907は、メモリ904に入力される。データバス908は、CPU901と制御レジスタ902とメモリ904とに接続される。   FIG. 5 is a block diagram showing a main part of a circuit configuration example of a conventional microcomputer for expanding the memory size. The microcomputer 900 includes a CPU 901, a control register 902, an address converter 903, a memory 904 for storing programs and data, and the like. An address bus output signal 905 output from the CPU 901 is input to the control register 902 and the address converter 903. The address conversion control signal 906 output from the control register 902 is input to the address converter 903. A memory address bus input signal 907 output from the address converter 903 is input to the memory 904. The data bus 908 is connected to the CPU 901, the control register 902, and the memory 904.

図6は、図5のマイクロコンピュータ900のメモリマップを示す。CPU901のアドレスによって指定可能なメモリ空間が911であるのに対し、メモリ904の物理メモリ空間は912である。この拡張されたメモリ904の物理メモリ空間912は、CPU901が直接アクセス可能なメモリ空間911よりも大きい。   FIG. 6 shows a memory map of the microcomputer 900 shown in FIG. The memory space that can be specified by the address of the CPU 901 is 911, whereas the physical memory space of the memory 904 is 912. The physical memory space 912 of the expanded memory 904 is larger than the memory space 911 that can be directly accessed by the CPU 901.

したがって、CPU901から出力されるアドレスによって、メモリ904の物理メモリ空間912のうち領域914に対してはアドレス変換せずに直接アクセスすることができる。しかしながら、メモリ904の物理メモリ空間912の領域915に対しては直接アクセスすることができないため、CPU901が出力するアドレスを領域915に対応するアドレスに変換する動作を必要とする。   Therefore, the area 914 in the physical memory space 912 of the memory 904 can be directly accessed without performing address conversion by the address output from the CPU 901. However, since the area 915 of the physical memory space 912 of the memory 904 cannot be directly accessed, an operation for converting the address output by the CPU 901 into an address corresponding to the area 915 is required.

図7は、マイクロコンピュータ900のメモリアクセス動作波形を示す。ここでは、図6において、物理メモリ空間912の領域914をアクセスした後に領域915をアクセスして、さらに領域914をアクセスする場合を説明する。   FIG. 7 shows a memory access operation waveform of the microcomputer 900. Here, in FIG. 6, a case will be described in which the area 915 is accessed after the area 914 of the physical memory space 912 is accessed, and the area 914 is further accessed.

CPU901は、アドレス変換せずにアクセスできる領域914の例えばメモリアドレスA0、A1にアクセスした後、制御レジスタ902のアドレスD0にアクセスし、アドレス変換制御信号906をHighレベルにする。   The CPU 901 accesses, for example, the memory addresses A0 and A1 of the area 914 that can be accessed without address conversion, then accesses the address D0 of the control register 902, and sets the address conversion control signal 906 to the high level.

このアドレス変換制御信号906がHighレベルの間は、CPU901から出力される例えばアドレスバス出力信号B0、B1は、アドレス変換器903で領域915をアクセスする例えばアドレスC0、C1にアドレス変換される。次に、CPU901は、制御レジスタ902のアドレスD0にアクセスし、アドレス変換制御信号906をLowレベルにする。その後、CPU901は、アドレス変換せずにアクセスできる領域914の例えばメモリアドレスA2、A3にアクセスする。   While the address conversion control signal 906 is at a high level, the address bus output signals B0 and B1 output from the CPU 901 are converted into addresses C0 and C1 for accessing the area 915 by the address converter 903, for example. Next, the CPU 901 accesses the address D0 of the control register 902 and sets the address conversion control signal 906 to the low level. Thereafter, the CPU 901 accesses, for example, the memory addresses A2 and A3 in the area 914 that can be accessed without address conversion.

このように、上述した従来の方式では、図6における物理メモリ空間912の領域915にアクセスする際には制御レジスタ902へのアクセスが必要となり、パフォーマンスの低下、コード効率の低下を招いてしまう問題があった。   As described above, the conventional method described above requires access to the control register 902 when accessing the area 915 of the physical memory space 912 in FIG. 6, resulting in a decrease in performance and a decrease in code efficiency. was there.

また、複数のメモリを異なるアドレスに割り付けるのではなく、少なくとも一部が重複するアドレスに割り付け、CPUのステータス信号を用いてメモリの選択することでパフォーマンスを低下させないようにしたメモリ拡張を行なう技術がある(例えば、特許文献1参照。)。
特開平8−63392号公報(第4頁、第1図)
Also, there is a technique for memory expansion, in which a plurality of memories are not assigned to different addresses, but at least a part of them is assigned to an overlapping address, and the memory is selected by using a CPU status signal so that the performance is not deteriorated. (For example, refer to Patent Document 1).
JP-A-8-63392 (page 4, FIG. 1)

しかしながら、特許文献1のようにメモリの総容量を増加させるメモリ拡張方式では、ステータス信号で選択する個々のメモリ容量(メモリサイズ)をシステム開発段階において必要なプログラムコードやデータコードのサイズが変動する時に柔軟に変更するのが困難となる。このため、それぞれのメモリに増設のメモリ容量を設けることになり、チップ面積の増加を招きコストアップとなる問題があった。   However, in the memory expansion method for increasing the total memory capacity as in Patent Document 1, the size of the program code and data code required for the individual memory capacity (memory size) selected by the status signal varies in the system development stage. Sometimes it becomes difficult to change flexibly. For this reason, an additional memory capacity is provided for each memory, which increases the chip area and raises the cost.

本発明は、上記問題を解決するためになされたもので、システム開発段階でプログラムコードとデータコードを格納するメモリのメモリサイズの比率変更が可能で、パフォーマンスやコード効率を低下させないでメモリ拡張を行なうマイクロコンピュータを提供することを目的とする。   The present invention has been made to solve the above problems, and it is possible to change the ratio of the memory size of the memory for storing the program code and the data code in the system development stage, and to expand the memory without degrading the performance and code efficiency. An object is to provide a microcomputer to be used.

上記目的を達成するために、本発明のマイクロコンピュータは、CPUと、前記CPUからの第1のメモリアドレスとステータス信号とが入力され、前記第1のメモリアドレスで指定できるメモリ空間よりも大きなメモリ空間を指定できる第2のメモリアドレスを前記ステータス信号に基づいて出力するアドレス変換手段と、前記アドレス変換手段から出力する前記第2のメモリアドレスによってアドレッシングされ、命令コードまたはデータコードを読み出すメモリとを備え前記第2のメモリアドレスの少なくとも一部の値は、前記第1のメモリアドレスの値と同一となることを特徴とする。   In order to achieve the above object, a microcomputer of the present invention receives a CPU, a first memory address and a status signal from the CPU, and has a memory larger than a memory space that can be specified by the first memory address. Address conversion means for outputting a second memory address that can designate a space based on the status signal, and a memory that is addressed by the second memory address output from the address conversion means and reads an instruction code or a data code The value of at least a part of the second memory address is the same as the value of the first memory address.

本発明によれば、システム開発段階でプログラムコードとデータコードを格納するメモリのメモリサイズの比率変更が可能で、メモリアクセスのパフォーマンスやコード効率を低下させないで、CPUが直接アクセスできるメモリサイズに比べてメモリサイズの拡張を可能とするマイクロコンピュータを提供することができる。   According to the present invention, it is possible to change the ratio of the memory size of the memory for storing the program code and the data code in the system development stage, and compared with the memory size that can be directly accessed by the CPU without deteriorating the memory access performance and code efficiency. A microcomputer capable of expanding the memory size can be provided.

以下、本発明の実施例を説明する。   Examples of the present invention will be described below.

本発明の実施例に係るマイクロコンピュータを、図1乃至図4を参照して説明する。   A microcomputer according to an embodiment of the present invention will be described with reference to FIGS.

図1は、本発明の実施例に係るメモリ拡張機能を有するマイクロコンピュータの回路構成を示すブロック図である。図2は、メモリ拡張機能を実現するアドレス変換回路の構成を示すブロック図である。図3は、本発明の実施例に係るマイクロコンピュータのメモリマップ図である。図4は、本発明の実施例に係るマイクロコンピュータのメモリアクセス動作の動作波形図である。この実施例に用いる図は、説明に必要な範囲に省略模式化されている。   FIG. 1 is a block diagram showing a circuit configuration of a microcomputer having a memory expansion function according to an embodiment of the present invention. FIG. 2 is a block diagram showing a configuration of an address conversion circuit for realizing the memory expansion function. FIG. 3 is a memory map diagram of the microcomputer according to the embodiment of the present invention. FIG. 4 is an operation waveform diagram of the memory access operation of the microcomputer according to the embodiment of the present invention. The drawing used in this embodiment is abbreviated to the extent necessary for explanation.

図1に示すマイクロコンピュータ100は、プログラムを実行するCPU101と、CPU101から出力されるメモリアドレスをCPU101からのステータス信号に従ってアドレス変換するアドレス変換回路102と、プログラムコードやデータコードが格納されているメモリ103から構成される。   A microcomputer 100 shown in FIG. 1 includes a CPU 101 that executes a program, an address conversion circuit 102 that converts a memory address output from the CPU 101 in accordance with a status signal from the CPU 101, and a memory that stores program codes and data codes. 103.

CPU101から出力されるCPUアドレスバス出力信号104と、命令フェッチ/データアクセスを識別するアクセス識別信号105は、アドレス変換回路102に入力される。また、アドレス変換回路102から出力されるメモリアドレスバス入力信号106は、メモリ103のアドレス入力に入力される。データバス107は、CPU101とメモリ104とに接続される。   A CPU address bus output signal 104 output from the CPU 101 and an access identification signal 105 for identifying instruction fetch / data access are input to the address conversion circuit 102. The memory address bus input signal 106 output from the address conversion circuit 102 is input to the address input of the memory 103. The data bus 107 is connected to the CPU 101 and the memory 104.

図2(A)は、アドレス変換回路102の構成を示し、加算器110と、2入力1出力のセレクタ120と、あらかじめ設定された拡張サイズを示すバイアス値130とから構成される。   FIG. 2A shows a configuration of the address conversion circuit 102, which includes an adder 110, a 2-input 1-output selector 120, and a bias value 130 indicating a preset extension size.

CPU101から出力されるアドレスバス出力信号104は、加算器110とセレクタ120のデータ入力にそれぞれ入力される。加算器110は、入力されたアドレスバス出力信号104とバイアス値130からの出力信号111とを入力して加算し、加算結果をアドレス信号112として出力する。   The address bus output signal 104 output from the CPU 101 is input to the data inputs of the adder 110 and the selector 120, respectively. The adder 110 inputs and adds the input address bus output signal 104 and the output signal 111 from the bias value 130, and outputs the addition result as an address signal 112.

セレクタ120は、加算器110からのアドレス信号112と、アドレスバス出力信号104の上位側に「0」を付加して拡張した信号113(アドレス信号112と同じビット幅)とがデータ入力され、CPU101から出力される命令フェッチ/データアクセスを識別するアクセス識別信号105により、2つのアドレスのいずれか一方のアドレスデータを選択出力して、メモリアドレスバス入力信号106としてメモリ103に出力する。アドレス変換回路102のバイアス値130には、メモリ103に対しCPU101が直接アドレス可能なメモリサイズより拡張されたサイズをアクセス出来る値があらかじめ設定される。   The selector 120 receives the address signal 112 from the adder 110 and the signal 113 (with the same bit width as the address signal 112) expanded by adding “0” to the upper side of the address bus output signal 104, and receives data from the CPU 101. The address identification signal 105 for identifying the instruction fetch / data access output from is selected and output from either one of the two addresses and output to the memory 103 as the memory address bus input signal 106. The bias value 130 of the address conversion circuit 102 is preset with a value that allows the memory 103 to access a size expanded from the memory size that the CPU 101 can directly address.

次に、図3および図4を参照しながら、CPU101がメモリ103からプログラムコードやデータコードをアクセスする時のアドレス変換回路102の動作の詳細を説明する。   Next, details of the operation of the address conversion circuit 102 when the CPU 101 accesses a program code or data code from the memory 103 will be described with reference to FIGS. 3 and 4.

ユーザが開発するアプリケーションプログラムがCPU101のアクセスできるメモリサイズより大きくなった時、そのプログラムを格納できるようにメモリ103のサイズ拡張が行われる。その結果、図3のメモリマップに示すように、CPU101が直接アクセスできるメモリ空間201より大きい物理メモリ空間202がメモリ103に形成される。   When an application program developed by the user becomes larger than the memory size accessible by the CPU 101, the size of the memory 103 is expanded so that the program can be stored. As a result, a physical memory space 202 larger than the memory space 201 that can be directly accessed by the CPU 101 is formed in the memory 103 as shown in the memory map of FIG.

このメモリ103の物理メモリ空間202には、プログラムコードが領域204に、データコードが領域205に格納される。また、この発明ではプログラムコードおよびデータコードが重複する領域206が設けられている。   In the physical memory space 202 of the memory 103, the program code is stored in the area 204 and the data code is stored in the area 205. In the present invention, an area 206 where the program code and the data code overlap is provided.

そして、CPU101から出力されるアドレスバス出力信号104によって直接アクセスできる領域は、メモリ103の物理メモリ空間202の領域204である。一方、メモリ103の物理メモリ空間202の領域205をアクセスする場合は、CPU101から出力されるアドレスバス出力信号104は、アドレス変換回路102によって領域205に対応するアドレス変換される。   An area that can be directly accessed by the address bus output signal 104 output from the CPU 101 is an area 204 in the physical memory space 202 of the memory 103. On the other hand, when accessing the area 205 of the physical memory space 202 of the memory 103, the address bus output signal 104 output from the CPU 101 is converted into an address corresponding to the area 205 by the address conversion circuit 102.

例えば、CPU101のアドレスバス出力信号104のアドレスバス幅が16ビットであり、拡張されたメモリ103のメモリ容量が96Kワード(主領域64K+拡張部32K)の時、図3のプログラムコードが格納される領域204の先頭アドレスN1は”00000”H(H:16進数を示す)であり、最終アドレスN3は”0FFFF”Hとなる。また、データコードを格納する領域205の先頭アドレスN2は例えば”08000”Hであるとすると、最終アドレスN4は”17FFF”Hとなる。したがって、この例ではバイアス値130には”8000”Hの値が設定されることになる。   For example, when the address bus width of the address bus output signal 104 of the CPU 101 is 16 bits and the memory capacity of the expanded memory 103 is 96K words (main area 64K + expansion unit 32K), the program code of FIG. 3 is stored. The leading address N1 of the area 204 is “00000” H (H: indicates a hexadecimal number), and the final address N3 is “0FFFF” H. Further, if the head address N2 of the area 205 for storing the data code is, for example, “08000” H, the final address N4 is “17FFF” H. Accordingly, in this example, a value of “8000” H is set as the bias value 130.

次に、実施例に係るマイクロコンピュータ100の動作を、図4を参照して説明する。   Next, the operation of the microcomputer 100 according to the embodiment will be described with reference to FIG.

図4のメモリアクセス動作遷移は、マイクロコンピュータ100のCPU101がメモリ103の領域204に格納されるプログラムコードの読み出しアクセスを行った後に、データコードが格納された領域205の読み出しアクセスを行って、再び領域204のプログラムコードの読み出しを行う例を示している。   In the memory access operation transition of FIG. 4, after the CPU 101 of the microcomputer 100 performs the read access of the program code stored in the area 204 of the memory 103, the read access of the area 205 in which the data code is stored is performed again. An example of reading the program code in the area 204 is shown.

まず、第1および第2サイクルでCPU101は、アドレスバス出力信号104として例えばアドレスA0、A1を出力するとともに、プログラムコードを読み出すため命令フェッチ/データアクセスを識別するLowレベルのアクセス識別信号105を出力する。   First, in the first and second cycles, the CPU 101 outputs, for example, addresses A0 and A1 as the address bus output signal 104, and outputs a low-level access identification signal 105 that identifies instruction fetch / data access for reading the program code. To do.

アドレス変換回路102のセレクタ120は、アクセス識別信号105がLowであるので、CPU101からのアドレスバス出力信号104に上位アドレスに「0」を付与した信号113を選択して、メモリアドレスバス入力信号106としてメモリ103に出力する。このため、CPU101からのアドレスバス出力信号104は、アドレス変換されることなくメモリ103のアドレス入力に入力される。そして、メモリ103ではアドレスA0,A1に従ってアドレッシングされ、領域204に格納されたプログラムコードがデータバス107を介してCPU101に読み込まれる。   Since the access identification signal 105 is Low, the selector 120 of the address conversion circuit 102 selects the signal 113 obtained by adding “0” to the higher address to the address bus output signal 104 from the CPU 101, and the memory address bus input signal 106. To the memory 103. Therefore, the address bus output signal 104 from the CPU 101 is input to the address input of the memory 103 without being subjected to address conversion. In the memory 103, the program code addressed according to the addresses A 0 and A 1 and stored in the area 204 is read into the CPU 101 via the data bus 107.

次に、第3および第4サイクルでCPU101は、例えばアドレスB0、B1を出力するとともに、データコードを読み出すため命令フェッチ/データアクセスを識別するHighレベルのアクセス識別信号105を出力する。   Next, in the third and fourth cycles, the CPU 101 outputs addresses B0 and B1, for example, and outputs a high-level access identification signal 105 for identifying instruction fetch / data access for reading the data code.

アドレス変換回路102のセレクタ120は、命令フェッチ/データアクセス識別信号105がHighであるので、CPU101からのアドレスバス出力信号104のアドレス値とバイアス値130の出力信号111の値とを入力して加算する加算器110から出力されるアドレス112を選択して、メモリアドレスバス入力106としてメモリ103に出力する。これにより、CPU101から出力されたアドレスB0、B1はアドレス変換回路102によって例えばアドレスC0、C1に変換されて、メモリ103のアドレス入力に入力される。そして、メモリ103ではアドレスC0、C1に従ってアドレッシングされ、領域205に格納されたデータコードがデータバス107を介してCPU101に読み込まれる。   Since the instruction fetch / data access identification signal 105 is High, the selector 120 of the address conversion circuit 102 inputs and adds the address value of the address bus output signal 104 from the CPU 101 and the value of the output signal 111 of the bias value 130. The address 112 output from the adder 110 is selected and output to the memory 103 as the memory address bus input 106. Thus, the addresses B0 and B1 output from the CPU 101 are converted into, for example, addresses C0 and C1 by the address conversion circuit 102 and input to the address input of the memory 103. In the memory 103, the data code addressed according to the addresses C 0 and C 1 and stored in the area 205 is read into the CPU 101 via the data bus 107.

また、第5および第6サイクルでCPU101は、例えばアドレスA2、A3を出力するとともに、プログラムコードを読み出すため命令フェッチ/データアクセスを識別するLowレベルのアクセス識別信号105を出力する。   In the fifth and sixth cycles, the CPU 101 outputs addresses A2 and A3, for example, and outputs a low-level access identification signal 105 for identifying instruction fetch / data access for reading the program code.

アドレス変換回路102のセレクタ120は、命令フェッチ/データアクセスを識別するアクセス識別信号105がLowであるので、第1および第2サイクルと同様にCPU101からのアドレスバス出力信号104のアドレスA2,A3は、アドレス変換せずにメモリ103のアドレス入力に入力される。そして、メモリ103ではアドレスA2、A3に従ってアドレッシングされ、領域204に格納されたプログラムコードがデータバス107を介してCPU101に読み込まれる。   In the selector 120 of the address conversion circuit 102, since the access identification signal 105 for identifying instruction fetch / data access is Low, the addresses A2 and A3 of the address bus output signal 104 from the CPU 101 are the same as in the first and second cycles. The address is input to the memory 103 without address conversion. In the memory 103, the program code addressed according to the addresses A 2 and A 3 and stored in the area 204 is read into the CPU 101 via the data bus 107.

このようにして、マイクロコンピュータ100は、プログラムコード領域とデータコード領域にアクセスする時、アドレス変換回路102に対して特別な設定のための命令実行やその為のアクセスサイクルを必要とせずにメモリ103をアクセスすることができ、パフォーマンスの低下やコード効率の低下を回避できる。   In this way, when accessing the program code area and the data code area, the microcomputer 100 does not require execution of a special instruction for the address conversion circuit 102 or an access cycle for the memory 103. Can be accessed and performance degradation and code efficiency degradation can be avoided.

また上述した本実施例のアドレス変換回路102を備えるマイクロコンピュータ100を用いると、ユーザはプログラム開発で、プログラム(命令)コード領域とデータコード領域を区別してアプリケーションプログラムを開発することで、CPU101の直接アクセスするメモリサイズを越えたサイズのアプリケーションプログラムをメモリ103に格納することが可能になる。   In addition, when the microcomputer 100 including the address conversion circuit 102 of this embodiment described above is used, a user can directly access the CPU 101 by developing an application program by distinguishing a program (instruction) code area and a data code area by program development. The application program having a size exceeding the memory size to be stored can be stored in the memory 103.

また、ユーザが開発段階でプログラムを変更してプログラムコードの領域サイズが変更となっても、データコードの領域との総和がメモリ103のメモリ容量のサイズを越えない限りアドレス変換回路などを変更する必要がなく、ユーザのプログラム開発が容易になる。   Also, even if the user changes the program at the development stage and the area size of the program code is changed, the address conversion circuit and the like are changed as long as the sum of the area with the data code area does not exceed the memory capacity size of the memory 103. This eliminates the need for user program development.

データコード領域に音声データ、文字コードの画像データなどの定数やパターンデータを格納するだけでなく、たとえばサイン波のテーブル(時間と振幅値)を格納すれば、モータ制御における電流値を計算する時などに参照することで高速応答を実現するとともに、計算のためのプログラムコードを減らすことができて、プログラムコードとデータコードの領域比率調整が容易になる。   In addition to storing constants and pattern data such as voice data and character code image data in the data code area, for example, if a sine wave table (time and amplitude value) is stored, when calculating the current value in motor control By referring to the above, it is possible to realize a high-speed response, to reduce the program code for calculation, and to easily adjust the area ratio between the program code and the data code.

本発明は、上記実施例に限定されるものではなく、発明の要旨を逸脱しない範囲で、種々、変形して実施できることは勿論である。   The present invention is not limited to the above-described embodiments, and it is needless to say that various modifications can be made without departing from the spirit of the invention.

たとえば、図2(B)に示すアドレス変換回路102のように、セレクタ120を、加算器110の入力側に設け、セレクタ120にはバイアス値130の出力信号111と値が0(ゼロ)である信号114とが入力され、命令フェッチ/データアクセスを識別するアクセス識別信号105によってどちらか一方の入力を選択して信号115に出力させ、加算器110に入力させるようにしてもよい。この場合、加算器110の出力はメモリアドレスバス入力106となりメモリ103のメモリアドレスに入力される。このようにすることでCPUアドレスバス出力信号104の入力先がアドレス変換回路102内では加算器110の1箇所となってCPU101のアドレス出力ドライバの負荷が減ってマイクロプロセッサの高速化や低消費電力化が図れるとともに、セレクタ120のビット幅が1ビット減って回路規模が削減できる。   For example, like the address conversion circuit 102 shown in FIG. 2B, a selector 120 is provided on the input side of the adder 110, and the selector 120 has an output signal 111 of a bias value 130 and a value of 0 (zero). The signal 114 is input, and either one of the inputs may be selected by the access identification signal 105 for identifying the instruction fetch / data access, and the signal 115 may be output and input to the adder 110. In this case, the output of the adder 110 becomes the memory address bus input 106 and is input to the memory address of the memory 103. By doing so, the input destination of the CPU address bus output signal 104 is one place in the adder 110 in the address conversion circuit 102, and the load on the address output driver of the CPU 101 is reduced, thereby speeding up the microprocessor and reducing the power consumption. In addition, the circuit width can be reduced by reducing the bit width of the selector 120 by 1 bit.

本発明に係るマイクロコンピュータの実施例の構成を示すブロック図。The block diagram which shows the structure of the Example of the microcomputer which concerns on this invention. 本実施例のアドレス変換回路の第1および第2の構成を示すブロック図。FIG. 3 is a block diagram showing first and second configurations of an address conversion circuit according to the present embodiment. 本実施例のマイクロコンピュータのメモリマップを示す図。The figure which shows the memory map of the microcomputer of a present Example. 本実施例のマイクロコンピュータの動作遷移の一例を示す図。The figure which shows an example of the operation | movement transition of the microcomputer of a present Example. 従来のマイクロコンピュータの構成を示すブロック図。The block diagram which shows the structure of the conventional microcomputer. 従来のマイクロコンピュータのメモリマップを示す図。The figure which shows the memory map of the conventional microcomputer. 従来のマイクロコンピュータの動作遷移の一例を示す図。The figure which shows an example of the operation | movement transition of the conventional microcomputer.

符号の説明Explanation of symbols

100、900 マイクロコンピュータ
101、901 CPU
102 アドレス変換回路
103、904 メモリ
104、905 CPUアドレスバス出力信号
105 命令フェッチ/データアクセス識別信号
106、907 メモリアドレスバス入力信号
107、908 データバス信号
902 制御レジスタ
903 アドレス変換器
906 アドレス変換制御信号
110 加算器
120 セレクタ
130 バイアス値
201 CPUのメモリ空間
202 メモリのメモリ空間
203 CPUが直接アクセスできるメモリ空間
204 プログラムコード領域
205 データコード領域
100, 900 Microcomputer 101, 901 CPU
102 Address conversion circuit 103, 904 Memory 104, 905 CPU address bus output signal 105 Instruction fetch / data access identification signal 106, 907 Memory address bus input signal 107, 908 Data bus signal 902 Control register 903 Address converter 906 Address conversion control signal 110 Adder 120 Selector 130 Bias Value 201 CPU Memory Space 202 Memory Memory Space 203 Memory Space 204 Directly Accessible by CPU 204 Program Code Area 205 Data Code Area

Claims (5)

CPUと、
前記CPUからの第1のメモリアドレスとステータス信号とが入力され、前記第1のメモリアドレスで指定できるメモリ空間よりも大きなメモリ空間を指定できる第2のメモリアドレスを前記ステータス信号に基づいて出力するアドレス変換手段と、
前記アドレス変換手段から出力される前記第2のメモリアドレスによってアドレッングされ、命令コードまたはデータコードを読み出すメモリと
を備え前記第2のメモリアドレスの少なくとも一部の値は、前記第1のメモリアドレスの値と同一となることを特徴とするマイクロコンピュータ。
CPU,
A first memory address and a status signal from the CPU are input, and a second memory address that can designate a memory space larger than a memory space that can be designated by the first memory address is output based on the status signal. Address translation means;
A memory that is addressed by the second memory address output from the address converting means and reads an instruction code or a data code, and at least a part of the value of the second memory address is a value of the first memory address A microcomputer characterized by having the same value.
前記アドレス変換手段は、
前記第1のメモリアドレスとあらかじめ定められた値とを加算する加算回路と、
前記第1のメモリアドレスの上位側に1桁以上のビット「0」を付加してビット幅を拡張したメモリアドレスと前記加算回路の加算出力であるメモリアドレスとが入力され、前記ステータス信号によって前記入力された2つのメモリアドレスのいずれか一方が前記第2のメモリアドレスとして出力されるセレクタと
を備えることを特徴とする請求項1に記載のマイクロコンピュータ。
The address conversion means includes
An adder circuit for adding the first memory address and a predetermined value;
A memory address obtained by adding one or more digits “0” to the upper side of the first memory address to expand the bit width and a memory address that is an addition output of the adder circuit are input. The microcomputer according to claim 1, further comprising: a selector that outputs one of the two input memory addresses as the second memory address.
前記アドレス変換手段は、
あらかじめ定められた値と「0」とが入力され、前記ステータス信号によって前記入力された2つの値のいずれか一方が出力されるセレクタと、
前記セレクタの出力値と前記第1のメモリアドレスとを加算して前記第2のメモリアドレスを生成する加算回路と、
を備えることを特徴とする請求項1に記載のマイクロコンピュータ。
The address conversion means includes
A selector that receives a predetermined value and “0”, and outputs one of the two input values according to the status signal;
An adder circuit for adding the output value of the selector and the first memory address to generate the second memory address;
The microcomputer according to claim 1, further comprising:
前記CPUから出力される前記ステータス信号は、命令フェッチであるかデータアクセスであるかが識別可能な信号であることを特徴とする請求項2又は請求項3に記載のマイクロコンピュータ。   4. The microcomputer according to claim 2, wherein the status signal output from the CPU is a signal capable of identifying whether it is instruction fetch or data access. CPUと、
前記CPUから出力される第1のメモリアドレスと、0より大きく前記第1のメモリアドレスの最大値より小さな固定値とを加算して生成されたメモリアドレスと、前記第1のメモリアドレスの上位側に少なくとも1桁以上のビット「0」を付加してビット幅を拡張したメモリアドレスのいずれか一方を前記CPUから出力される命令フェッチであるかデータアクセスであるかが識別可能なステータス信号によって選択するか、または前記固定値と「0」のいずれか一方を前記ステータス信号によって選択し、その出力値と前記第1のメモリアドレスと加算するかして前記第2のメモリアドレスを生成する変換回路と、
前記変換回路から出力された前記第2のメモリアドレスによってアドレッシングされ、前記第1のメモリアドレスで指定できるメモリ容量よりも大きなメモリ容量のメモリと、を備え、
前記CPUが前記命令フェッチ時にアクセスできる前記メモリのアドレス領域と、前記データアクセス時にアクセスできる前記メモリのアドレス領域が一部重複することを特徴とするマイクロコンピュータ。
CPU,
A memory address generated by adding the first memory address output from the CPU and a fixed value greater than 0 and less than the maximum value of the first memory address; and the upper side of the first memory address One of the memory addresses in which the bit width is expanded by adding at least one digit bit “0” to the memory is selected by a status signal that can identify whether the instruction fetch or data access is output from the CPU. Or one of the fixed value and “0” is selected by the status signal, and the output value and the first memory address are added to generate the second memory address. When,
A memory having a memory capacity larger than a memory capacity that is addressed by the second memory address output from the conversion circuit and can be specified by the first memory address;
A microcomputer in which an address area of the memory accessible by the CPU at the time of fetching an instruction partially overlaps an address area of the memory accessible at the time of data access.
JP2006173053A 2006-06-22 2006-06-22 Microcomputer Withdrawn JP2008003867A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006173053A JP2008003867A (en) 2006-06-22 2006-06-22 Microcomputer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006173053A JP2008003867A (en) 2006-06-22 2006-06-22 Microcomputer

Publications (1)

Publication Number Publication Date
JP2008003867A true JP2008003867A (en) 2008-01-10

Family

ID=39008191

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006173053A Withdrawn JP2008003867A (en) 2006-06-22 2006-06-22 Microcomputer

Country Status (1)

Country Link
JP (1) JP2008003867A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018106547A (en) * 2016-12-27 2018-07-05 キヤノン株式会社 Information processing device and information processing method

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2018106547A (en) * 2016-12-27 2018-07-05 キヤノン株式会社 Information processing device and information processing method

Similar Documents

Publication Publication Date Title
US20050198471A1 (en) Micro-controller for reading out compressed instruction code and program memory for compressing instruction code and storing therein
EP0945783A2 (en) Variable length register device
US6158046A (en) Computer device and method for processing data utilizing pseudoinstruction words
JP3863544B1 (en) Arithmetic processing device and arithmetic processing method
JP2008003867A (en) Microcomputer
KR100517765B1 (en) Cache memory and control method thereof
US20070150641A1 (en) Bus Address Selecting Circuit and Bus Address Selecting Method
JPH0246970B2 (en) MEMORIKA KUCHOHOSHIKI
JP4015867B2 (en) Address signal output device
US8255672B2 (en) Single instruction decode circuit for decoding instruction from memory and instructions from an instruction generation circuit
JP2004021422A (en) Microcomputer
JP2008065377A (en) Information processor
JP2005004643A (en) Microcomputer
JPH1040165A (en) Data read method and read buffer
JP2000132491A (en) Method and system for device control
JPH09305398A (en) Arithmetic processor and instruction converter
JPS5856885B2 (en) Address control method
EP0755000A2 (en) Microcomputer and address generation method
JP2002116951A (en) Address generation circuit
JP2000056969A (en) Register file
JP2002358236A (en) Information processing equipment, memory management unit, address translation device
JP2009015580A (en) Information processor
JPH05127903A (en) Parallel processing micro processor
JP2001100991A (en) Digital signal processor
JP2000163315A (en) Memory control system

Legal Events

Date Code Title Description
A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20081226

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20090210

A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20090901