JPH0822421A - Memory diagnostic method - Google Patents

Memory diagnostic method

Info

Publication number
JPH0822421A
JPH0822421A JP6158750A JP15875094A JPH0822421A JP H0822421 A JPH0822421 A JP H0822421A JP 6158750 A JP6158750 A JP 6158750A JP 15875094 A JP15875094 A JP 15875094A JP H0822421 A JPH0822421 A JP H0822421A
Authority
JP
Japan
Prior art keywords
area
memory
address
page
diagnostic
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
Application number
JP6158750A
Other languages
Japanese (ja)
Other versions
JP3171364B2 (en
Inventor
Toshinori Iwawaki
俊典 岩脇
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.)
PFU Ltd
Original Assignee
PFU 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 PFU Ltd filed Critical PFU Ltd
Priority to JP15875094A priority Critical patent/JP3171364B2/en
Publication of JPH0822421A publication Critical patent/JPH0822421A/en
Application granted granted Critical
Publication of JP3171364B2 publication Critical patent/JP3171364B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Abstract

PURPOSE:To diagnose the whole memory area including a system area, an area accessed directly with a physical address, etc., on an OS. CONSTITUTION:For a memory diagnosis, the OS 1 acquires the mount state of a memory 4, an address value pointing an address conversion table 2, and the area accessed with the physical address, generates an address conversion table 3 for diagnostic area access, and also generates an in-use page map M1 showing a page currently in use and an undiagnosed area map M2 indicating an address conversion table area and the area accessed directly with the physical address. Then the in-use page map M1 is searched to save the page in use in a free page outside the area to be diagnosed, and a diagnostic program 5 diagnoses the memory outside the area to be diagnosed in order. To diagnose the undiagnosed area on the memory 4, the operation of an address converting mechanism is stopped and the undiagnosed area is all diagnosed with the physical address.

Description

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

【0001】[0001]

【産業上の利用分野】本発明はメモリの診断方法に関
し、特に本発明は、OS(オペレーティングシステム、
以下OSという)上から全メモリの診断を行うことがで
きるメモリ診断方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a memory diagnostic method, and more particularly, the present invention relates to an OS (operating system,
The present invention relates to a memory diagnosis method capable of diagnosing all memories from above.

【0002】[0002]

【従来の技術】図7は従来のメモリ診断の方法を示す図
である。従来、メモリの全領域の診断を行うには、同図
に示すように、例えば、OSの立ち上げ前に、メモリM
Sの所定の領域Aに診断プログラムTPを格納し次の手
順により診断を行っていた。 領域Aに格納された診断プログラムTPにより、領
域A以外の領域にデータをライトしたのちそのデータを
リードし、正常にライト/リードが行われるか否かによ
りをメモリの領域Bの診断を行う。 診断プログラムTPが自分自身を領域A以外の領域
に複写して、上記と同様に診断プログラムTPが格納さ
れていた領域Aの診断を行う。 システムリセットを行い、OSを立ち上げる。
2. Description of the Related Art FIG. 7 is a diagram showing a conventional memory diagnosis method. Conventionally, in order to diagnose the entire area of the memory, as shown in FIG.
The diagnostic program TP is stored in the predetermined area A of S and the diagnosis is performed by the following procedure. The diagnostic program TP stored in the area A writes data in an area other than the area A, then reads the data, and diagnoses the area B of the memory depending on whether or not writing / reading is normally performed. The diagnostic program TP copies itself to an area other than the area A, and diagnoses the area A in which the diagnostic program TP was stored in the same manner as above. Reset the system and start up the OS.

【0003】[0003]

【発明が解決しようとする課題】ところで、上記した従
来のメモリ診断方法は、OS上で診断プログラムを動作
させることができず、また、メモリ診断を行うために、
診断プログラムをロード/実行させる機構を必要とし
た。また、診断プログラムの処理を簡単にするため、診
断プログラムを全て同じページに格納するか、あるい
は、連続した領域に格納しなければならなかった。
By the way, in the above-mentioned conventional memory diagnosis method, the diagnosis program cannot be operated on the OS, and in order to perform the memory diagnosis,
Needed a mechanism to load / execute the diagnostic program. Further, in order to simplify the processing of the diagnostic program, it is necessary to store all the diagnostic programs in the same page or in continuous areas.

【0004】本発明は上記した問題点を解決するために
なされたものであって、本発明の第1の目的は、診断プ
ログラムが異なったページに分散して配置されている場
合であっても、OS上において診断プログラムにより、
システム領域等を含めたメモリの診断を容易に行うこと
ができるメモリの診断方法を提供することである。本発
明の第2の目的は、OS上において診断プログラムによ
り、アドレス変換テーブル、物理アドレスで直接アクセ
スされている領域を含めた全メモリ領域を診断すること
ができるメモリの診断方法を提供することである。
The present invention has been made to solve the above-mentioned problems, and the first object of the present invention is even when the diagnostic programs are distributed and arranged in different pages. , The diagnostic program on the OS
An object of the present invention is to provide a memory diagnosing method capable of easily diagnosing a memory including a system area and the like. A second object of the present invention is to provide a memory diagnosing method capable of diagnosing an entire memory area including an area directly accessed by an address conversion table and a physical address by a diagnostic program on an OS. .

【0005】[0005]

【課題を解決するための手段】図1は本発明の原理図で
ある。同図において、1はOS、2はシステムのアドレ
ス変換テーブル、3は診断域用アドレス変換テーブル、
4は診断対象となるメモリ、5は診断プログラム、M1
は使用中ページマップ、M2は未診断域マップである。
FIG. 1 is a diagram illustrating the principle of the present invention. In the figure, 1 is an OS, 2 is a system address conversion table, 3 is a diagnostic area address conversion table,
4 is a memory to be diagnosed, 5 is a diagnostic program, M1
Is a used page map, and M2 is an undiagnosed area map.

【0006】上記課題を解決するため、本発明の請求項
1の発明は、同図に示すように、オペレーティング・シ
ステム1に、少なくともメモリ4の実装状態を獲得する
手段と、アドレス変換テーブル2をポイントするアドレ
ス値を獲得する手段と、物理アドレスにより直接アクセ
スされる領域を獲得する手段とを設け、また、ユーザモ
ードでシステム域をアクセスする機能を設け、メモリ診
断プログラム5によりメモリを診断する際、使用中の物
理ページを認識するための使用中ページマップM1と、
アドレス変換テーブルで使用している領域および物理ア
ドレスで直接アクセスしている領域を認識するための未
診断域マップM2を作成し、上記使用中ページマップM
1から、診断対象領域における使用中の物理ページをサ
ーチして使用中の物理ページを診断対象領域外の空きペ
ージに退避し、上記メモリ診断プログラム5により上記
診断対象領域のメモリを診断する処理を繰り返すことに
より、オペレーティング・システム上で未診断領域外の
全メモリを診断するようにしたものである。
In order to solve the above-mentioned problems, according to the invention of claim 1 of the present invention, as shown in the figure, the operating system 1 is provided with a means for acquiring at least the mounted state of the memory 4 and an address conversion table 2. A means for acquiring an address value to be pointed and a means for acquiring an area directly accessed by a physical address are provided, and a function of accessing a system area in a user mode is provided. A page map in use M1 for recognizing a physical page in use,
An undiagnosed area map M2 for recognizing the area used in the address translation table and the area directly accessed by the physical address is created, and the in-use page map M is used.
The process of diagnosing the physical page in use in the diagnostic target area from 1 to save the physical page in use to an empty page outside the diagnostic target area, and diagnose the memory in the diagnostic target area by the memory diagnostic program 5. By repeating this, all the memory outside the undiagnosed area is diagnosed on the operating system.

【0007】本発明の請求項2の発明は、請求項1の発
明において、診断域用アドレス変換テーブル3を作成
し、診断域用アドレス変換テーブル3により論理アドレ
スによるアクセスを可能とし、診断プログラムによりオ
ペレーティング・システム上で未診断領域外の全メモリ
を診断するようにしたものである。本発明の請求項3の
発明は、請求項1または請求項2の発明において、未診
断域マップM2をサーチして未診断域の物理ページを求
め、アドレス変換機構の動作を停止させて論理アドレス
と物理アドレスを一致させた状態でメモリ診断プログラ
ム5により未診断域を診断することにより、未診断域を
含めたメモリの全領域を診断するようにしたものであ
る。
According to a second aspect of the present invention, in the first aspect of the invention, the diagnostic area address conversion table 3 is created, and the diagnostic area address conversion table 3 enables access by a logical address. All the memory outside the undiagnosed area is diagnosed on the operating system. According to a third aspect of the present invention, in the first or second aspect of the invention, the undiagnosed area map M2 is searched for a physical page in the undiagnosed area, and the operation of the address translation mechanism is stopped to set the logical address. By diagnosing the undiagnosed area by the memory diagnosis program 5 in a state where the physical addresses are matched with each other, the entire area of the memory including the undiagnosed area is diagnosed.

【0008】[0008]

【作用】図1において、メモリ診断を行う際、OS1に
よりメモリ4の実装状態、アドレス変換テーブル2をポ
イントするアドレス値、物理アドレスでアクセスされる
領域を獲得し、また必要に応じて診断域アクセス用アド
レス変換テーブル3を生成し、使用中ページマップM
1、未診断域マップM2を作成する。
In FIG. 1, when the memory diagnosis is performed, the OS 1 acquires the mounting state of the memory 4, the address value pointing to the address conversion table 2, and the area to be accessed by the physical address, and access to the diagnostic area as necessary. Generate the address conversion table 3 for use, and use page map M
1. Create an undiagnosed area map M2.

【0009】ついで、使用中ページマップM1によりサ
ーチして、使用中のページを診断対象域外の空ページに
退避して、診断プログラム5により未診断対象域外のメ
モリを順次診断する。また、メモリ4上の上記未診断域
を診断する場合には、アドレス変換機構の動作を停止さ
せて、物理アドレスにより全未診断域を診断する。
Then, the in-use page map M1 is searched to save the in-use page to an empty page outside the diagnosis target area, and the diagnostic program 5 sequentially diagnoses the memory outside the non-diagnosis target area. When diagnosing the undiagnosed area on the memory 4, the operation of the address conversion mechanism is stopped and the entire undiagnosed area is diagnosed by the physical address.

【0010】本発明の請求項1の発明においては、上記
のように、使用中の物理ページを認識するための使用中
ページマップM1と、アドレス変換テーブルで使用して
いる領域および物理アドレスで直接アクセスしている領
域を認識するための未診断域マップM2を作成し、上記
使用中ページマップM1から、診断対象領域における使
用中の物理ページをサーチして使用中の物理ページを診
断対象領域外の空きページに退避し、上記メモリ診断プ
ログラム5により上記診断対象領域のメモリを診断して
いるので、OS上において診断プログラムにより、シス
テム領域等を含めたメモリの診断を行うことができる。
According to the first aspect of the present invention, as described above, the in-use page map M1 for recognizing the in-use physical page and the area and physical address used in the address translation table are directly accessed. An undiagnosed area map M2 for recognizing an area being used is created, and a physical page in use in the diagnosis target area is searched from the in-use page map M1 to find the physical page in use outside the diagnosis target area. Since the memory in the diagnostic target area is diagnosed by the memory diagnostic program 5 by evacuating to an empty page, the diagnostic program on the OS can diagnose the memory including the system area.

【0011】本発明の請求項2の発明においては、請求
項1の発明において、診断域用アドレス変換テーブル3
を作成してメモリの診断を行うようにしているので、シ
ステム用のアドレス変換テーブルを書き換えることなく
メモリの診断を行うことができる。本発明の請求項3の
発明においては、請求項1または請求項2の発明におい
て、アドレス変換機構の動作を停止させて論理アドレス
と物理アドレスを一致させた状態でメモリ診断プログラ
ム5により未診断域を診断するようにしているので、ア
ドレス変換テーブル、物理アドレスで直接アクセスされ
ている領域を含めた全メモリ領域を診断することができ
る。
According to a second aspect of the present invention, in the first aspect of the invention, the diagnostic area address conversion table 3 is used.
Is created to diagnose the memory, the memory can be diagnosed without rewriting the address conversion table for the system. According to a third aspect of the present invention, in the first or second aspect of the present invention, an undiagnosed area is detected by the memory diagnostic program 5 in a state where the operation of the address translation mechanism is stopped and the logical address and the physical address are matched. Therefore, the entire memory area including the area directly accessed by the address conversion table and the physical address can be diagnosed.

【0012】[0012]

【実施例】次に本発明の実施例について説明する。な
お、本実施例においては、メモリ診断プログラムによ
り、様々なメモリテストパターンを用いてメモリ診断を
行うが、OS上でシステム域等を含めた全メモリ領域を
診断するため、OSに次の機能を設ける。 メモリの実装状態を獲得する機能。
EXAMPLES Next, examples of the present invention will be described. In the present embodiment, the memory diagnostic program executes the memory diagnostics using various memory test patterns. However, the following functions are added to the OS in order to diagnose the entire memory area including the system area on the OS. Set up. A function to acquire the mounting status of the memory.

【0013】すなわち、メモリの第何番目のスロットに
何MBのメモリが実装されているかを獲得する機能であ
り、メモリの実装状態に基づき、後述する診断プログラ
ムによる診断範囲を設定する。 論理アドレスではなく、物理アドレスで直接アクセ
スされているページを獲得する機能。
That is, it is a function of acquiring how many MB of memory is mounted in the numbered slot of the memory, and sets a diagnostic range by a diagnostic program, which will be described later, based on the mounted state of the memory. A function to acquire the page that is directly accessed by the physical address instead of the logical address.

【0014】通常のOSでは論理アドレスによりプログ
ラムが動作するため、物理アドレスにより直接アクセス
されるページは殆ど存在いないと考えられるが、例え
ば、OSがクラッシュし、ROMを使用する場合等、R
OMルーチンから物理アドレスにより直接アクセスされ
るページが存在する場合もあり、メモリ診断によりこの
領域が破壊されると、上記ROMルーチンは使用できな
くなる。そこで、物理アドレスにより直接アクセスされ
るページが存在する場合には、そのページ位置を獲得す
る必要がある。
Since a program operates by a logical address in a normal OS, it is considered that there are almost no pages directly accessed by a physical address. For example, when the OS crashes and ROM is used, R
There may be a page directly accessed by the physical address from the OM routine, and if this area is destroyed by the memory diagnosis, the ROM routine cannot be used. Therefore, when there is a page directly accessed by the physical address, it is necessary to acquire the page position.

【0015】なお、物理アドレスによりアクセスされる
ページの内、システムの立ち上げ時(ブート時)にRO
Mに格納されたプログラムから物理アドレスにより直接
アクセスされる領域については、メモリ診断プログラム
により破壊されても支障がない。したがって、物理アド
レスにより直接アクセスされるページがこのような領域
の場合には、メモリ診断が可能であり、このようなペー
ジは意識する必要がない。
Of the pages accessed by the physical address, RO is set at system startup (boot time).
The area directly accessed by the physical address from the program stored in M can be destroyed by the memory diagnostic program without any problem. Therefore, when the page directly accessed by the physical address is such an area, memory diagnosis is possible, and it is not necessary to be aware of such a page.

【0016】また、ディスプレイ表示ルーチンがROM
に格納され、物理アドレスでアクセスされている場合に
は、この領域が破壊されると表示ができなくなる。した
がって、診断プログラム中で診断結果を表示させる必要
がある場合には、ディスプレイ表示ルーチンを、診断プ
ログラム内に持たせて置く必要がある。 アドレス変換テーブルをポイントするコンテキスト
・ポイント・レジスタ(以下CXRという)の値を獲得
する機能。
Further, the display display routine is ROM
If the area is destroyed and is accessed by the physical address, it becomes impossible to display. Therefore, when it is necessary to display the diagnosis result in the diagnostic program, the display display routine needs to be included in the diagnostic program. A function to acquire the value of the context point register (hereinafter referred to as CXR) that points to the address conversion table.

【0017】複数のアドレス変換テーブルがある場合、
CXR値を獲得し、ポイントされているアドレス変換テ
ーブルを獲得する機能であり、ポイントされているアド
レス変換テーブルのアドレスを獲得することによりメモ
リ上の診断域を定める。 ユーザモードでシステム域をアクセスする機能。一
般に、ユーザモードではシステム域をアクセスできない
ようにプロテクトされている場合が多いが、本実施例に
おいては、上記のようにユーザモードで動作する診断プ
ログラムによりシステム域を含めた全メモリ領域を診断
している。このため、上記プロテクトをはずしてユーザ
モードでシステム域をアクセスする機能を設ける必要が
ある。
When there are a plurality of address conversion tables,
This is a function of acquiring the CXR value and acquiring the pointed address conversion table. By acquiring the address of the pointed address conversion table, the diagnostic area on the memory is determined. Ability to access the system area in user mode. Generally, in many cases, the system area is protected so that it cannot be accessed in the user mode. However, in the present embodiment, the entire memory area including the system area is diagnosed by the diagnostic program operating in the user mode as described above. ing. Therefore, it is necessary to remove the protection and provide a function for accessing the system area in the user mode.

【0018】図2〜図4は本発明におけるメモリの診断
方法の実施例を示す図であり、図2は全体の構成、図3
は図2におけるシステムのアドレス変換テーブル、図4
は図2における診断域アクセス用のアドレス変換テーブ
ルを示している。同図において、11はシステムのアド
レス変換テーブルであり、システムのアドレス変換テー
ブル11は前記したCRXによりポイントされるコンテ
キストテーブルT1とリージョンテーブルT2とセグメ
ントテーブルT3とページテーブルT4から構成されて
いる。12はメモリ診断時に生成される診断域アクセス
用アドレス変換テーブルであり、セグメントテーブルT
5とページテーブルT6から構成され、一つのセグメン
トテーブルで16MBの領域を指し、セグメントテーブ
ル4つで64MBの領域を指す。
2 to 4 are views showing an embodiment of a memory diagnosing method according to the present invention. FIG.
Is the address conversion table of the system in FIG. 2, and FIG.
Shows an address conversion table for accessing the diagnostic area in FIG. In the figure, 11 is a system address conversion table, and the system address conversion table 11 is composed of a context table T1, a region table T2, a segment table T3, and a page table T4 pointed by the CRX. Reference numeral 12 is a diagnostic area access address conversion table generated during memory diagnosis, and is a segment table T
5 and a page table T6, one segment table points to a 16 MB area, and four segment tables point to a 64 MB area.

【0019】13は診断の対象となるメモリであり、メ
モリ13の物理ページはROM、アドレス変換テーブ
ル、モニタ、スケジューラ、本実施例のメモリ診断用プ
ログラム等により使用されている。次に図2〜図4によ
り本実施例について説明する。なお、同図中に付されて
いる括弧付き数字は下記の括弧付き数字に対応してい
る。 (1) 図2において、メモリ診断を開始する時点において
は、メモリ13の各スロットの物理ページは、ROM、
アドレス変換テーブル、モニタ、スケジューラ、メモリ
診断用プログラムにより使用されており、図2、図3の
(1) に示すようにシステムのアドレス変換テーブルはそ
れらの物理ページをポイントしている。
Reference numeral 13 is a memory to be diagnosed, and physical pages of the memory 13 are used by a ROM, an address conversion table, a monitor, a scheduler, a memory diagnostic program of this embodiment, and the like. Next, this embodiment will be described with reference to FIGS. The numbers in parentheses in the figure correspond to the numbers in parentheses below. (1) In FIG. 2, at the time of starting the memory diagnosis, the physical page of each slot of the memory 13 is a ROM,
It is used by the address translation table, monitor, scheduler, and memory diagnostic program.
As shown in (1), the system address translation table points to those physical pages.

【0020】なお、以下のメモリ診断を実行中は他のプ
ロセスにディスパッチしない(実行権を与えない)状態
とする必要があり、例えば、割り込みを制御するレジス
タにアクセスして、NMI以外の割り込みをマスクして
おく。 (2) システム用アドレス変換テーブルをアクセスするた
め、各アドレス変換テーブルの論理アドレスを求める。
すなわち、前記したの機能により、図3に示すCXR
の値を得てコンテキストテーブルT1の論理アドレスを
得るとともに、リージョンテーブルT2、セグメントテ
ーブルT3、ページテーブルT4の論理アドレスを求め
る。なお、物理アドレスにより直接アドレス変換テーブ
ルをアクセスする場合には、この処理は不用である。 (3) メモリ13に格納されている診断プログラムによ
り、診断対象域を論理アドレスでアクセスするため、診
断域用アドレス変換テーブル12の領域を確保し、その
初期化を行う。
During execution of the following memory diagnosis, it is necessary to set a state in which other processes are not dispatched (execution right is not given). For example, by accessing a register for controlling interrupts, interrupts other than NMI are generated. Keep a mask. (2) Obtain the logical address of each address translation table to access the system address translation table.
That is, the CXR shown in FIG.
Is obtained to obtain the logical address of the context table T1 and the logical addresses of the region table T2, the segment table T3 and the page table T4. If the physical address directly accesses the address translation table, this process is unnecessary. (3) The diagnostic program stored in the memory 13 accesses the diagnostic target area with a logical address, so that an area of the diagnostic area address conversion table 12 is secured and initialized.

【0021】なお、システムアドレス変換テーブルを使
用して診断を行うことも可能であるが、そのためにはシ
ステム用アドレス変換テーブルを書き換える必要があ
り、診断後システムアドレス変換テーブルを書き戻す必
要がででくる。また、空いているアドレス変換テーブル
を使用することもできるが、この場合には、空きアドレ
ス変換テーブルをサーチする必要がある。このため、本
実施例においては、上記のように診断用アドレス変換テ
ーブルを別途作成している。 (4) アドレス変換テーブルで使用している物理ページを
認識するためのマップMP1(未診断域マップという)
を作成する。また、ページテーブルT4からポイントさ
れておらず、物理アドレスで直接アクセスされているペ
ージがあれば、OSに追加されたの機能により物理ア
ドレスで直接アクセスされているページを獲得し、上記
未診断域マップMP1に反映させる。 (5) リージョンテーブルT2に診断域用アドレス変換テ
ーブル12を登録するための領域を確保する。 (6) 使用している全ての物理ページを認識するための使
用中ページマップMP2を作成する。 (7) リージョンテーブルT2に診断域用アドレス変換テ
ーブル12を登録し、診断域用アドレス変換テーブル1
2により診断対象域を論理アドレスでアクセスできるよ
うにする。 (8) メモリの診断対象域に、使用中の物理ページがあれ
ば、診断域以外の空いている物理ページをマップMP2
よりサーチし、ページの中身をその空いているページに
複写する。
It is possible to make a diagnosis by using the system address conversion table, but for that purpose, the system address conversion table needs to be rewritten, and the system address conversion table needs to be written back after the diagnosis. come. It is also possible to use an empty address conversion table, but in this case it is necessary to search the empty address conversion table. Therefore, in this embodiment, the diagnostic address conversion table is separately created as described above. (4) Map MP1 (known as undiagnosed area map) for recognizing the physical page used in the address translation table
Create If there is a page that is not directly pointed to by the page table T4 and is directly accessed by the physical address, the page that is directly accessed by the physical address is acquired by the function added to the OS, and the undiagnosed area map MP1 is acquired. To reflect. (5) An area for registering the diagnostic area address conversion table 12 is secured in the region table T2. (6) Create an in-use page map MP2 for recognizing all used physical pages. (7) Register the diagnostic area address conversion table 12 in the region table T2, and execute the diagnostic area address conversion table 1
2 enables the diagnosis target area to be accessed by a logical address. (8) If there is a physical page in use in the diagnostic target area of the memory, map a free physical page other than the diagnostic area to MP2
Search more and copy the contents of the page to the empty page.

【0022】例えば、図2に示すようにメモリ13のス
ロット2がメモリ診断対象域のとき、その領域に使用中
のページがある場合には、使用中のページをスロット1
の未使用のページにコピーする。 (9) 物理ページを移動したので、システムのアドレス変
換テーブル11を書き換えるため、アドレス変換テーブ
ル11およびキャッシュのデータをフラッシュ(消去)
する。 (10)移動した物理ページに合わせてシステムのアドレス
変換テーブル11を書き換える。 (11)診断プログラムにより、上記診断対象域のメモリの
診断を行う。但し、マップMP1にはシステムのアドレ
ス変換テーブル11が格納されているページおよび診断
域用アドレス変換テーブル12が格納されているペー
ジ、および物理アドレスで直接アクセスされるページが
登録されているので、上記マップMP1を参照して上記
ページを獲得し、そのページは診断対象からはずす(こ
の領域を未診断領域とする)。
For example, as shown in FIG. 2, when the slot 2 of the memory 13 is the memory diagnostic target area, and if there is a page in use in that area, the page in use is set to the slot 1
Copy to an unused page in. (9) Since the physical page has been moved, the address translation table 11 and cache data are flushed (erased) in order to rewrite the system address translation table 11.
To do. (10) The address translation table 11 of the system is rewritten according to the moved physical page. (11) The diagnostic program diagnoses the memory in the above diagnostic target area. However, since the page storing the system address conversion table 11 and the page storing the diagnostic area address conversion table 12 and the page directly accessed by the physical address are registered in the map MP1, the above map The page is acquired by referring to MP1, and the page is removed from the diagnosis target (this area is defined as an undiagnosed area).

【0023】なお、アドレス変換テーブル域を診断しな
い場合の、診断しない領域のサイズの一例を以下に示
す。これらの数値はプロセッサの違いにより当然変化す
る。 a.システムのアドレス変換テーブル域 ・コンテキストテーブル 65536*4 =256KB ・リージョンテーブル 256*4 =1KB ・セグメントテーブル 256*64*4 =64KB(全領域を
使用している場合) ・ページテーブル 256*64*64*4 =4MB (全領域を
使用している場合) b.診断域用アドレス変換テーブル域 ・セグメントテーブル 64*64*4 =1KB ・ページテーブル 64*64*4*4 =64KB なお、システムのアドレス変換テーブルにおけるセグメ
ントテーブルおよびページテーブルは、通常、全領域を
使用しておらず、実際に使用している領域は次の程度で
ある。
An example of the size of the non-diagnosing area when the address translation table area is not diagnosed is shown below. These numbers naturally change depending on the processor. a. System address translation table area ・ Context table 65536 * 4 = 256KB ・ Region table 256 * 4 = 1KB ・ Segment table 256 * 64 * 4 = 64KB (when using all areas) ・ Page table 256 * 64 * 64 * 4 = 4MB (when using all areas) b. Address translation table area for diagnostic area ・ Segment table 64 * 64 * 4 = 1KB ・ Page table 64 * 64 * 4 * 4 = 64KB Note that the segment table and page table in the system address translation table normally use the entire area. The area that is actually used is as follows.

【0024】 ・セグメントテーブル 3*64*4 =768KB ・ページテーブル 3*64*64*4 =48KB すなわち、実際に使用している領域を考慮すると、アド
レス変換テーブルで使用している領域は約435KB程
度と考えられる。したがって、アドレス変換テーブルが
使用している領域を診断しなくても、事実上はメモリの
ほぼ全域を診断できることになるが、この領域を含めて
診断を行う必要がある場合には、後述する方法で診断す
る。
-Segment table 3 * 64 * 4 = 768KB-Page table 3 * 64 * 64 * 4 = 48KB In other words, considering the area actually used, the area used in the address translation table is about 435KB. It is considered to be the degree. Therefore, virtually all the memory can be diagnosed without diagnosing the area used by the address translation table. However, if the diagnosis needs to be performed including this area, the method described later will be used. Diagnose with.

【0025】なお、アドレス変換テーブル域の診断は、
前記したようにアドレス変換テーブルが使用している物
理ページを移動することにより診断することは可能であ
るが、アドレス変換テーブルが使用している物理ページ
を移動すると、それに影響する全てのアドレス変換テー
ブル域を書き換える必要があり、処理が複雑となる。こ
のため、アドレス変換テーブル域は未診断域としてお
き、後述するように物理アドレスで直接アクセスされて
いるページと同様な方法により診断する。 (12)アドレス変換テーブル、キャッシュデータをフラッ
シュ(消去)する。 (13)移動した物理ページを元に戻す。 (14)物理ページを復元したので、システムのアドレス変
換テーブルを書き換える。 (15)後述する方法によりアドレス変換テーブル域および
物理アドレスで直接アクセスしている未診断域を診断す
る。
The address translation table area is diagnosed as follows.
As mentioned above, it is possible to diagnose by moving the physical page used by the address translation table, but if the physical page used by the address translation table is moved, all the address translation tables that affect it can be diagnosed. It is necessary to rewrite the area, which complicates the processing. For this reason, the address conversion table area is set as an undiagnosed area, and the diagnosis is performed by the same method as the page directly accessed by the physical address as described later. (12) Flush (erase) the address translation table and cache data. (13) Restore the moved physical page. (14) Since the physical page was restored, rewrite the system address translation table. (15) The undiagnosed area directly accessed by the address conversion table area and the physical address is diagnosed by the method described later.

【0026】図5は上記処理手順をフローチャートで示
した図であり、同図における各丸付き数字は上記(1) 〜
(15)の処理に対応している。同図のステップS1におい
て、上記(1) 〜(3),(5)(7)で説明した準備処理を行う。
ステップS2において未診断域のマップMP1を作成
し、ステップS3において使用中ページのマップMP2
を作成する。
FIG. 5 is a flow chart showing the above-mentioned processing procedure. The numbers in circles in FIG.
It corresponds to the processing of (15). In step S1 of the figure, the preparation process described in the above (1) to (3), (5), and (7) is performed.
In step S2, the map MP1 of the undiagnosed area is created, and in step S3, the map MP2 of the in-use page is created.
Create

【0027】ステップS4において、全スロットの診断
をしたか否かを判別し、全スロットの診断が終わるま
で、ステップS5からステップS8の処理を繰り返す。
すなわち、ステップS5において、上記(8) 〜(10)で説
明したように診断対象スロットから使用ページを別のス
ロットの空きページに退避し、ステップS6で周知な様
々なメモリテストパターンでスロット内の全てを診断
し、エラーがあるか否かを調べる。そしてエラーが発生
した場合には、ステップS7でエラーアドレス、ステー
タスレジスタ等のエラー情報を表示する。
In step S4, it is determined whether all slots have been diagnosed, and the processes of steps S5 to S8 are repeated until the diagnosis of all slots is completed.
That is, in step S5, as described in (8) to (10) above, the used page is saved from the diagnosis target slot to an empty page in another slot, and the various memory test patterns known in step S6 are used to save the used page in the slot. Diagnose everything and see if there are any errors. When an error occurs, error information such as the error address and status register is displayed in step S7.

【0028】そして、ステップS8において、(12)〜(1
4)で説明したように退避ページの復元処理を行いステッ
プS4に戻る。全スロットの診断が終わると、後述する
方法により未診断域の診断を行い終了する。次に上記し
た未診断域を診断する方法について説明する。図6は上
記した未診断域を診断する処理手順を示すフローチャー
トであり、同図により本実施例について説明する。
Then, in step S8, (12) to (1
As described in 4), the save page restoration process is performed, and the process returns to step S4. When the diagnosis of all the slots is completed, the undiagnosed area is diagnosed by the method described later and the operation is completed. Next, a method for diagnosing the above undiagnosed area will be described. FIG. 6 is a flowchart showing a processing procedure for diagnosing the above-mentioned undiagnosed region, and this embodiment will be described with reference to FIG.

【0029】なお、次のフローチャートでは、アドレス
変換を行うハードウェアとしてMMU(メモリ・マネー
ジメント・ユニット)を用いる場合について説明する
が、MMUを用いない場合であっても、アドレス変換機
構の動作を停止させる機能をOSに持たせれば同様に行
うことができる。図7のステップT1において、使用中
の物理ページを示すマップMP2より、論理アドレスが
空でかつ物理アドレスが空なページをサーチし、ステッ
プT2においてそのページに診断プログラム自身を複写
する。
In the following flow chart, the case where an MMU (memory management unit) is used as the hardware for performing the address conversion will be described. However, even when the MMU is not used, the operation of the address conversion mechanism is stopped. If the OS is provided with the function to perform, the same operation can be performed. In step T1 of FIG. 7, a page having a logical address and an empty physical address is searched from the map MP2 showing the physical page in use, and the diagnostic program itself is copied to the page in step T2.

【0030】ステップT3においてMMUをデセーブル
にする。これにより、論理アドレス=物理アドレスでプ
ログラムが実行されるようになる。ステップT4におい
て、未診断域のマップMP1から未診断域を求め、未診
断域を全て診断する。未診断域の診断は、前記図5と同
様であり、様々なメモリテストパターンでページ単位に
全ての未診断域を診断し、エラーがあるか否かを調べ
る。
At step T3, the MMU is disabled. As a result, the program is executed with logical address = physical address. At step T4, an undiagnosed area is obtained from the map MP1 of the undiagnosed area, and all the undiagnosed areas are diagnosed. Diagnosis of the undiagnosed area is similar to that of FIG. 5, and all the undiagnosed areas are diagnosed page by page with various memory test patterns to check whether or not there is an error.

【0031】そして、エラーが発生するとステップT5
においてエラー情報を決められた領域に格納し、ステッ
プT6において、MMUをイネーブルとする。これによ
り、論理アドレスによりアクセスが可能となる。ステッ
プS7においてエラー情報を上記決められた領域から取
得し終了する。その後OS上において、上記エラー情報
を読み出し、表示等を行う。
When an error occurs, step T5
In step T6, the error information is stored in the determined area, and the MMU is enabled in step T6. This makes it possible to access using the logical address. In step S7, the error information is acquired from the above-mentioned determined area, and the process ends. After that, the error information is read out and displayed on the OS.

【0032】[0032]

【発明の効果】以上説明したように、本発明において
は、使用中の物理ページを認識するための使用中ページ
マップと、アドレス変換テーブルで使用している領域お
よび物理アドレスで直接アクセスしている領域を認識す
るための未診断域マップを作成し、上記使用中ページマ
ップから、診断対象領域における使用中の物理ページを
サーチして使用中の物理ページを診断対象領域外の空き
ページに退避し、メモリ診断プログラムによりメモリの
診断を行うようにしているので、OS上においてシステ
ム領域等を含めたメモリの診断を行うことができる。
As described above, in the present invention, the in-use page map for recognizing the in-use physical page, the area used in the address translation table and the area directly accessed by the physical address are used. Create a non-diagnostic area map for recognizing, and search the physical page in use in the diagnostic target area from the above used page map and save the physical page in use to a free page outside the diagnostic target area, Since the memory is diagnosed by the memory diagnostic program, the memory including the system area can be diagnosed on the OS.

【0033】また、診断域用アドレス変換テーブルを作
成してメモリの診断を行うことにより、システム用にア
ドレス変換テーブルを書き換えることなくメモリの診断
を行うことができる。さらに、アドレス変換機構の動作
を停止させて論理アドレスと物理アドレスを一致させた
状態で未診断域を診断することにより、アドレス変換テ
ーブル、物理アドレスで直接アクセスされている領域を
含めた全メモリ領域を診断することが可能となる。
Further, by creating the address translation table for the diagnostic area and diagnosing the memory, the memory can be diagnosed without rewriting the address translation table for the system. Furthermore, by stopping the operation of the address translation mechanism and diagnosing the undiagnosed area with the logical address and the physical address matched, the entire memory area including the address translation table and the area directly accessed by the physical address can be detected. It becomes possible to diagnose.

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

【図1】本発明の原理図である。FIG. 1 is a principle diagram of the present invention.

【図2】本発明におけるメモリの診断方法の実施例を示
す図である。
FIG. 2 is a diagram showing an embodiment of a memory diagnosis method according to the present invention.

【図3】本発明におけるメモリの診断方法の実施例を示
す図(続き)である。
FIG. 3 is a diagram (continuation) showing an embodiment of a memory diagnosing method in the present invention.

【図4】本発明におけるメモリの診断方法の実施例を示
す図(続き)である。
FIG. 4 is a diagram (continuation) showing an embodiment of a memory diagnosing method in the present invention.

【図5】本発明の実施例におけるメモリ診断処理手順を
示す図である。
FIG. 5 is a diagram showing a memory diagnosis processing procedure in the embodiment of the present invention.

【図6】本発明の実施例における未診断域の診断方法を
示す図である。
FIG. 6 is a diagram showing a method of diagnosing an undiagnosed region in the embodiment of the present invention.

【図7】従来のメモリ診断方法を示す図である。FIG. 7 is a diagram showing a conventional memory diagnostic method.

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

1 OS 2 システムのアドレス変換テ
ーブル 3 診断域用アドレス変換テー
ブル 4 メモリ 5 診断プログラム 11 システムのアドレス変換テ
ーブル 12 診断域アクセス用アドレス
変換テーブル 13 メモリ M1,MP2 使用中ページマップ M2,MP1 未診断域マップ T1 コンテキストテーブル T2 リージョンテーブル T3,T5 セグメントテーブル T4,T6 ページテーブル CXR コンテキスト・ポイント・
レジスタ
1 OS 2 System address conversion table 3 Diagnostic area address conversion table 4 Memory 5 Diagnostic program 11 System address conversion table 12 Diagnostic area access address conversion table 13 Memory M1, MP2 Busy page map M2, MP1 Non-diagnostic area map T1 context table T2 region table T3, T5 segment table T4, T6 page table CXR context point
register

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 オペレーティング・システムに、少なく
ともメモリの実装状態を獲得する手段と、アドレス変換
テーブルをポイントするアドレス値を獲得する手段と、
物理アドレスにより直接アクセスされる領域を獲得する
手段とを設け、また、ユーザモードでシステム域をアク
セスする機能を設け、 メモリ診断プログラムによりメモリを診断する際、 使用中の物理ページを認識するための使用中ページマッ
プと、アドレス変換テーブルで使用している領域および
物理アドレスで直接アクセスしている領域を認識するた
めの未診断域マップを作成し、 上記使用中ページマップから、診断対象領域における使
用中の物理ページをサーチして使用中の物理ページを診
断対象領域外の空きページに退避し、上記メモリ診断プ
ログラムにより上記診断対象領域のメモリを診断する処
理を繰り返すことにより、 オペレーティング・システム上で未診断領域外の全メモ
リを診断することを特徴とするメモリの診断方法。
1. An operating system, at least means for obtaining a mounted state of a memory, and means for obtaining an address value pointing to an address conversion table,
Use to recognize the physical page being used when diagnosing the memory with the memory diagnostic program, by providing the means to acquire the area directly accessed by the physical address and the function to access the system area in the user mode. Create an undiagnosed area map for recognizing the medium page map, the area used in the address translation table, and the area directly accessed by the physical address. By searching the physical page, saving the used physical page to an empty page outside the diagnostic target area, and repeating the process of diagnosing the memory in the diagnostic target area by the memory diagnostic program, no diagnosis is made on the operating system. A method of diagnosing a memory, which comprises diagnosing all memories outside the area.
【請求項2】 診断域用アドレス変換テーブルを作成
し、診断域用アドレス変換テーブルにより論理アドレス
によるアクセスを可能とし、 診断プログラムによりオペレーティング・システム上で
未診断領域外の全メモリを診断することを特徴とする請
求項1のメモリの診断方法。
2. An address translation table for a diagnostic area is created, access by a logical address is made possible by the address translation table for a diagnostic area, and a diagnostic program diagnoses all memories outside the undiagnosed area on the operating system. The method for diagnosing a memory according to claim 1, wherein:
【請求項3】 未診断域マップをサーチして未診断域の
物理ページを求め、アドレス変換機構の動作を停止させ
て論理アドレスと物理アドレスを一致させた状態でメモ
リ診断プログラムにより未診断域を診断することによ
り、未診断域を含めたメモリの全領域を診断することを
特徴とする請求項1または請求項2のメモリの診断方
法。
3. The undiagnosed area is searched by the memory diagnostic program in a state where the physical page of the undiagnosed area is searched for by searching the undiagnosed area map and the operation of the address translation mechanism is stopped so that the logical address and the physical address match. 3. The method of diagnosing a memory according to claim 1, wherein the entire area of the memory including the undiagnosed area is diagnosed by performing the diagnosis.
JP15875094A 1994-07-11 1994-07-11 Memory diagnosis method Expired - Fee Related JP3171364B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP15875094A JP3171364B2 (en) 1994-07-11 1994-07-11 Memory diagnosis method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP15875094A JP3171364B2 (en) 1994-07-11 1994-07-11 Memory diagnosis method

Publications (2)

Publication Number Publication Date
JPH0822421A true JPH0822421A (en) 1996-01-23
JP3171364B2 JP3171364B2 (en) 2001-05-28

Family

ID=15678519

Family Applications (1)

Application Number Title Priority Date Filing Date
JP15875094A Expired - Fee Related JP3171364B2 (en) 1994-07-11 1994-07-11 Memory diagnosis method

Country Status (1)

Country Link
JP (1) JP3171364B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014147735A1 (en) * 2013-03-19 2014-09-25 株式会社日立製作所 Recording device and method for controlling recording device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2014147735A1 (en) * 2013-03-19 2014-09-25 株式会社日立製作所 Recording device and method for controlling recording device
JP5956675B2 (en) * 2013-03-19 2016-07-27 株式会社日立製作所 Storage device and storage device control method

Also Published As

Publication number Publication date
JP3171364B2 (en) 2001-05-28

Similar Documents

Publication Publication Date Title
JP5021190B2 (en) Memory dump generation with fast restart
JP3501336B2 (en) System and method for enabling write-on-load of dynamic ROM data
EP1638000B1 (en) Method, apparatus and program for performing panic memory dump
US6205450B1 (en) Computer system capable of restarting system using disk image of arbitrary snapshot
US6742148B1 (en) System and method for testing memory while an operating system is active
US5155844A (en) Background memory test during system start up
JPH0754463B2 (en) BIOS protection device and method, system protection program protection device, and access prevention device
JPH0812605B2 (en) Operational interface loading device and method, and computer system
US7711914B2 (en) Debugging using virtual watchpoints
US5386522A (en) Dynamic physical address aliasing during program debugging
JP2006196018A (en) Method and arrangement for providing bios to host computer
JPH0756631B2 (en) Personal computer system
JP3171364B2 (en) Memory diagnosis method
JP3766339B2 (en) I / O control device and computer system
JP2001356971A (en) System and method for testing multiprocessor memory
JP3426216B2 (en) Fault-tolerant computer system
JP2002149444A (en) Software testing system and software testing method, and computer-readable program recording medium with program for realizing the same method by computer recorded thereon, and program for realizing the same method by computer
JP4471274B2 (en) How to boot OS from hard disk image file
JP3183398B2 (en) Resource configuration information management method
JPH1031620A (en) Diagnostic device for cache memory
JPH0784893A (en) Method for diagnosing memory
JP2003323341A (en) Cashe miss avoiding device
JP2000010837A (en) File protecting method and machine-readable recording medium where program has been recorded
JPH09212380A (en) Highly reliabile computer system
JPS63228355A (en) System disk load system

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees