JPS6214243A - Program cost estimating system - Google Patents

Program cost estimating system

Info

Publication number
JPS6214243A
JPS6214243A JP60152873A JP15287385A JPS6214243A JP S6214243 A JPS6214243 A JP S6214243A JP 60152873 A JP60152873 A JP 60152873A JP 15287385 A JP15287385 A JP 15287385A JP S6214243 A JPS6214243 A JP S6214243A
Authority
JP
Japan
Prior art keywords
execution cost
vector
processing device
program
magnification
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP60152873A
Other languages
Japanese (ja)
Inventor
Shinya Miura
信也 三浦
Yukio Kamiya
幸男 神谷
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.)
Fujitsu Ltd
Original Assignee
Fujitsu 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 Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP60152873A priority Critical patent/JPS6214243A/en
Publication of JPS6214243A publication Critical patent/JPS6214243A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To estimate execution cost easily by making the execution cost in a scalar processing device on a part made to vector a base, and making the quotient obtained by dividing it by specified magnification execution cost of a vector processing device. CONSTITUTION:The magnification determining section 21 of a processing device 2 judges vector length by repetition designation value in an original program on the loop of each vector making procedure, reads out magnification from a magnification table 12 and gives it to an execution cost processing section 22. The execution cost processing section 22 calculates the quotient obtained by dividing execution cost value on the execution cost data 11 corresponding to each program statement of vector making procedure loop by magnification making execution cost data 11 on the original program 10 input, and outputs it as execution cost in the case where each program statement is executed by a vector processing device.

Description

【発明の詳細な説明】 〔概 要〕 ベクトル処理装置によるプログラム実行のコストを見積
もるための方式である。ベクトル化部分について、スカ
ラ処理装置における実行コストをベースとし、それを所
定の倍率で除した商を、ペクト、生処理装置における実
行コストとする。倍率はベクトル長の関数として定まる
ように決めておき、ベクトル長はベクトルの繰り返し演
算における繰り返し回数指定の値とする。この構成によ
り、ベクトル処理装置のプログラム実行コストを、容易
に見積もることができる。
[Detailed Description of the Invention] [Summary] This is a method for estimating the cost of program execution by a vector processing device. Regarding the vectorization part, the execution cost in the scalar processing device is used as the base, and the quotient obtained by dividing it by a predetermined magnification is defined as the execution cost in the raw processing device. The magnification is determined as a function of the vector length, and the vector length is a value specifying the number of repetitions in vector repeat operations. With this configuration, the program execution cost of the vector processing device can be easily estimated.

〔産業上の利用分野〕[Industrial application field]

本発明は、計算機システムのベクトル処理装置によるプ
ログラム実行のコストを見積もるための方式に関する。
The present invention relates to a method for estimating the cost of program execution by a vector processing device of a computer system.

プログラムの実行コストの見積は、該プログラムの性能
を評価し、又は該プログラムあるいは該プログラムのコ
ンパイラを改良等するための資料として、極めて有効で
ある。
Estimating the execution cost of a program is extremely effective as data for evaluating the performance of the program or improving the program or the compiler of the program.

ベクトル処理装置で実行する予定のプログラムについて
は、当然ベクトル処理装置における実行コストが要求さ
れるが、同時にしばしばスカラ処理装置による実行コス
トとの比較評価も必要とされる。
For a program scheduled to be executed on a vector processing device, the execution cost on the vector processing device is naturally required, but at the same time, a comparative evaluation with the execution cost on the scalar processing device is also often required.

〔従来の技術と発明が解決しようとする問題点〕プログ
ラムの実行コストは、プログラムの実行において処理装
置が占用される時間にほぼ比例すると考えてよい。
[Prior Art and Problems to be Solved by the Invention] The cost of executing a program can be considered to be approximately proportional to the time that a processing device is occupied in executing the program.

従って、処理装置の占用時間をもって、実行コストの値
とすることができるが、通常はより一般化した値とする
ために、例えば処理装置の整数加算命令の実行時間を1
として表した時間を実行コストとして使用する。
Therefore, the execution cost can be determined by the time occupied by the processing unit, but usually, in order to obtain a more generalized value, for example, the execution time of the integer addition instruction of the processing unit is
The time expressed as is used as the execution cost.

従来、スカラ処理装置(本明細書において、計算機シス
テムの通常の方式の中央処理装置等を、ベクトル処理装
置と区別してスカラ処理装置という)で実行するプログ
ラムの実行コストは、例えば次のようにして求めること
ができる。
Conventionally, the execution cost of a program executed on a scalar processing device (herein, a typical central processing unit of a computer system is referred to as a scalar processing device to distinguish it from a vector processing device) is calculated as follows, for example: You can ask for it.

すなわち、評価対象のプログラムをコンパイルして得た
、いわゆる目的プログラムについて、実行をシミュレー
トし、該目的プログラムを構成する各命令について、予
め実験的に求めである実行コストを累積することによっ
て、プログラムの実行コストを求める。
That is, by simulating the execution of a so-called target program obtained by compiling the program to be evaluated, and accumulating the execution cost, which is experimentally determined in advance, for each instruction that constitutes the target program, the program is evaluated. Find the execution cost.

その結果は、例えばFORTRAN言語TR外れたプロ
グラムの場合には、第3図に示すように、原プログラム
の各プログラム文ごとに対応する実行コストとして出力
される。
For example, in the case of a program outside the FORTRAN language TR, the result is output as an execution cost corresponding to each program statement of the original program, as shown in FIG.

ベクトル処理装置は、公知のように、ベクトル演算にお
いて発生する、同種の演算の繰り返しを連続的に効率よ
く実行するように構成された演算及び制御部を持つ処理
装置であり、比較的大容量の高速ベクトルレジスタに所
要のへクトルデータをブロック転送しておき、演算部に
データを連続して供給することによって高速性を得る。
As is well known, a vector processing device is a processing device that has an arithmetic operation and control section that is configured to continuously and efficiently execute the same type of operations that occur in vector operations, and has a relatively large capacity. High-speed performance is achieved by transferring a block of required vector data to a high-speed vector register and continuously supplying the data to the arithmetic unit.

従って、ベクトル処理装置による高速性は、演算対象の
ベクトル長くベクトル要素データの数)によって効果が
異なり、一般に比較的小さなベクトルではベクトル処理
装置を使用する効果が小さくなる。
Therefore, the effect of the high speed achieved by a vector processing device differs depending on the length of the vector to be operated on (the length of the vector and the number of vector element data), and in general, the effect of using the vector processing device is small for relatively small vectors.

このために、ベクトル処理装置で実行されるプログラム
の実行コストを、スカラ処理装置の場合のように単位命
令の実行コストの積み上げによって求めるのでは、一般
に誤差が大きくなるので、実行コストを求める場合には
、実際にベクトル処理装置で実行させて実行時間を測定
しなければならなかった。
For this reason, if the execution cost of a program executed on a vector processing device is determined by accumulating the execution cost of unit instructions as in the case of a scalar processing device, the error will generally become large. had to be actually executed on a vector processing device and measure the execution time.

〔問題点を解決するための手段〕[Means for solving problems]

第1図は、本発明の構成を示すブロック図である。 FIG. 1 is a block diagram showing the configuration of the present invention.

図において、1は原プログラム及びその他のデータを保
持する記憶装置、2は実行コストを求める処理装置であ
り、記憶装置1の10は原プログラム、11はスカラ処
理装置の実行コストデータ、12は倍率テーブルである
In the figure, 1 is a storage device that holds the original program and other data, 2 is a processing device that calculates the execution cost, 10 of the storage device 1 is the original program, 11 is the execution cost data of the scalar processing device, and 12 is the magnification It's a table.

処理装置2の20はベクトル化手続き検出部、21は倍
率決定部、22は実行コスト処理部である。
In the processing device 2, 20 is a vectorization procedure detection section, 21 is a magnification determining section, and 22 is an execution cost processing section.

〔作 用〕[For production]

ベクトル化手続き検出部20は、原プログラム10のプ
ログラム文を順次走査して、公知の一方法により、プロ
グラムを解析し、ベクトル演算のための繰り返しループ
を識別し、このループに含まれるプログラム文の並びを
、ベクトル化手続きとして摘出する。
The vectorization procedure detection unit 20 sequentially scans the program statements of the original program 10, analyzes the program using a known method, identifies a repeating loop for vector calculation, and identifies the program statements included in this loop. Extract the sequence as a vectorization procedure.

倍率決定部21は、各ベクトル化手続きのループについ
て、原プログラムにおける繰り返し指定値によってベク
トル長を判定し、倍率テーブル12から該ベクトル長判
定値をインデクスとして倍率を読み出し実行コスト処理
部22に渡す。
The magnification determination unit 21 determines the vector length for each vectorization procedure loop based on the repetition specified value in the original program, reads the magnification from the magnification table 12 using the vector length determination value as an index, and passes it to the execution cost processing unit 22.

実行コスト処理部22は、原プログラム10についての
実行コストデータ11を入力として、各ベクトル化手続
きループの各プログラム文に対応する実行コストデータ
11上の実行コスト値を、倍率によって除した商を求め
、それを各プログラム文をベクトル処理装置で実行した
場合の実行コストとして出力する。
The execution cost processing unit 22 takes the execution cost data 11 regarding the original program 10 as input and calculates a quotient by dividing the execution cost value on the execution cost data 11 corresponding to each program statement of each vectorized procedure loop by a magnification factor. , and outputs it as the execution cost when each program statement is executed by a vector processing device.

こ\で、倍率テーブル12の内容は、典型的なプログラ
ム文について、スカラ処理装置及びベクトル処理装置で
実行した場合の各実測値を基に、実行状態の解析データ
等を用いて求めた倍率により、予めテーブルを構成して
おくものとし、各ベクトル長に対し、そのようなベクト
ルの演算をベクトル処理装置で実行した場合の実行コス
トに対する、スカラ処理装置で実行した場合の実行コス
トの比を示す。
Here, the contents of the magnification table 12 are based on the magnification obtained using analysis data of the execution state, etc., based on each actual measurement value when a typical program statement is executed by a scalar processing device and a vector processing device. , a table is constructed in advance, and for each vector length, it shows the ratio of the execution cost when such a vector operation is executed on a vector processing device to the execution cost when it is executed on a scalar processing device. .

以上の構成により、プログラムをベクトル処理装置で実
行する場合の実行コストを、実際に実行することなく、
妥当な精度を維持して求めることができる。
With the above configuration, the execution cost of executing a program on a vector processing device can be reduced without actually executing it.
It can be determined while maintaining reasonable accuracy.

〔実施例〕〔Example〕

第1図において、記憶装置1は原プログラム及びその他
のデータを保持し、処理装置2は記憶装置1のデータに
よって実行コストを求める処理を実行して、要すればデ
ィスプレイ装置あるいは印刷装置等に、求めた実行コス
トの出力リスト3を出力する。
In FIG. 1, a storage device 1 holds the original program and other data, and a processing device 2 executes a process to determine the execution cost using the data in the storage device 1, and if necessary, displays it on a display device, a printing device, etc. An output list 3 of the determined execution costs is output.

処理装置2で実行されるベクトル化手続き検出部20は
、原プログラム10のプログラム文を順次走査して、公
知の一方法により、プログラムを解析し、ベクトル演算
のための繰り返しループを識別し、このループに含まれ
るプログラム文の並びを、ベクトル化手続きとして摘出
する。
A vectorization procedure detection unit 20 executed by the processing device 2 sequentially scans the program statements of the original program 10, analyzes the program using a known method, identifies a repeat loop for vector calculation, and The sequence of program statements included in the loop is extracted as a vectorization procedure.

例えば原プログラム10を、FORTRANで書かれた
プログラムとして以下の説明を行うと、このような各ル
ープは、第3図に例示したプログラム文のrDOJ文で
開始され、該「DO」文で指定される、ループの末尾を
示す文番号(第3図の例で、 fDOJに続<「10」
)のプログラム文で終わる。
For example, when the original program 10 is described below as a program written in FORTRAN, each loop starts with the rDOJ statement of the program statement illustrated in FIG. The statement number indicating the end of the loop (in the example in Figure 3, fDOJ is followed by <“10”)
) ends with the program statement.

倍率決定部21は、各ベクトル化手続きのループについ
て、原プログラムにおける繰り返し指定値を識別するこ
とによって、ベクトル長を判定する。
The magnification determining unit 21 determines the vector length for each vectorization procedure loop by identifying the repetition specified value in the original program.

すなわち、前記例の「DO」文中の、繰り返し指定[I
・1.1004は、公知のようにI=1.2.3、−.
99.100として、ループを100回実行する指定で
あることから、ベクトル長を100と判定する。
That is, the repetition specification [I
・1.1004 is I=1.2.3, -.
99.100, which specifies to execute the loop 100 times, so the vector length is determined to be 100.

倍率テーブル12の一例を下表に示す。An example of the magnification table 12 is shown in the table below.

表 このような倍率テーブルは、例えば典型的なプ0グラム
文について、スカラ処理装置及びベクトル処理装置で実
行した場合の各実測値を基に、実行状態の解析データ等
を用いて、各ベクトル長に対する倍率を設定することに
より、予め構成しておくものとし、各ベクトル長に対し
、そのようなベクトルの演算をベクトル処理装置で実行
した場合の実行コストに対する、スカラ処理装置で実行
した場合の実行コストの比を示す。
TableSuch a magnification table is created by calculating the length of each vector using analysis data of the execution state, etc., based on actual measurement values when a typical program statement is executed on a scalar processing device and a vector processing device. It is configured in advance by setting a magnification factor for each vector length. Show the cost ratio.

表において、ベクトル長が比較的短い場合には、倍率が
1より小さく、従ってベクトル処理装置で実行すると、
スカラ処理装置の場合より実行コストが大きくなること
を示している。
In the table, if the vector length is relatively short, the scaling factor is less than 1, so when executed on a vector processing device,
This indicates that the execution cost is higher than in the case of a scalar processing device.

又最大から最小までの幅があるのは、ベクトル演算内容
等により倍率の変動があることを考慮したものである。
The range from the maximum to the minimum is provided in consideration of the fact that the magnification varies depending on the contents of vector calculations.

倍率決定部21は、判定したベクトル長を使って、倍率
テーブル12から倍率を読み出し実行コスト処理部22
に渡す。
The magnification determining unit 21 reads the magnification from the magnification table 12 using the determined vector length, and the execution cost processing unit 22
give it to

実行コスト処理部22は、原プログラム10についての
スカラ処理装置の実行コストデータ11を入力として、
各ベクトル化手続きループの各プログラム文に対応する
実行コストデータ】1上の実行コスト値を、倍率によっ
て除した商を求め、それを各プログラム文をベクトル処
理装置で実行した場合の実行コストデータ13として出
力する。
The execution cost processing unit 22 inputs the execution cost data 11 of the scalar processing device regarding the original program 10, and
Execution cost data corresponding to each program statement of each vectorized procedure loop] Calculate the quotient by dividing the execution cost value above 1 by the magnification factor, and use it as execution cost data when each program statement is executed by a vector processing device 13 Output as .

この場合の個々のプログラム文に適用する倍率値として
は、例えば平均値を使用し、最大及び最小値は、例えば
各ループの実行コストの合計値に適用して、推定される
実行コストの幅を示すのに使用する。
In this case, the average value is used as the magnification value applied to each individual program statement, and the maximum and minimum values are applied, for example, to the total execution cost of each loop to calculate the range of the estimated execution cost. used to indicate

その後、出力部23は、実行コストデータ1】と実行コ
ストデータ13を編集して、ディスプレイ装置等に実行
コストの出力リスト3を出力する。
Thereafter, the output unit 23 edits the execution cost data 1] and the execution cost data 13, and outputs an output list 3 of execution costs to a display device or the like.

第2図は、出力リストの一例を示し、中央部に表示する
FORTl?ANプログラム文について、左側にベクト
ル処理装置における実行コス) (V−CO3T)を示
し、右側にスカラ処理装置における実行コスト(S−C
O3T)を示すことにより、ベクトル処理装置とスカラ
処理装置の効果を対比して検討するのに便利なようにし
ている。
Figure 2 shows an example of the output list, and the FORTl?? displayed in the center? Regarding the AN program statement, the execution cost (V-CO3T) on the vector processing device is shown on the left, and the execution cost (S-C
O3T) is shown to make it convenient to compare and examine the effects of vector processing devices and scalar processing devices.

なお、V−CO3T欄の数字の右のrVJの表示は、ベ
クトル化手続きの部分であることを示し、この表示が無
い部分はヘクトル化手続きでなく、従ってこの部分には
、5−C03Tと同し実行コストが示される。
Note that the rVJ display to the right of the number in the V-CO3T column indicates that it is a vectorization procedure part, and the part without this display is not a hectorization procedure, so this part contains the same information as 5-C03T. The execution cost is shown.

以−トの構成により、プログラムをベクトル処理装置で
実行する場合の実行コストを、実際に実行することなく
、妥当な精度を維持して求めることができ、又ベクトル
処理装置とスカラ処理装置の実行コストを対比し易いよ
うに、同時に表示することも容易になる。
With the above configuration, the execution cost when executing a program on a vector processing device can be determined while maintaining reasonable accuracy without actually executing it, and the execution cost of a vector processing device and a scalar processing device can be calculated without actually executing it. It also becomes easier to display costs at the same time to make it easier to compare costs.

〔発明の効果〕〔Effect of the invention〕

以上の説明から明らかなように、本発明によれば、ベク
トル処理装置におけるプログラムの実行コストを容易に
推定することが可能になり、更にこれをスカラ処理装置
の実行コストと対比することが容易になるので、プログ
ラムの開発効率及び情報処理システムの処理効率を向上
するという著しい工業的効果がある。
As is clear from the above description, according to the present invention, it is possible to easily estimate the execution cost of a program in a vector processing device, and it is also easy to compare this with the execution cost of a scalar processing device. Therefore, there is a significant industrial effect of improving the efficiency of program development and the processing efficiency of information processing systems.

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

第1図は本発明の実施例構成ブロック図、第2図は本発
明の実行コストの一出カ例を示す図、第3図はスカラ処
理装置の実行コストの一出カ例を示す図 である。 図において、 ■は記憶装置、     2は処理装置、3は出力リス
ト、   10は原プログラム、11.13は実行コス
トデータ、 12は倍率テーブル、 20はベクトル化手続き検出部、 21は倍率決定部、   22は実行コスト処理部、2
3は出力部 を示す。
FIG. 1 is a block diagram of the configuration of an embodiment of the present invention, FIG. 2 is a diagram showing an example of an output of the execution cost of the present invention, and FIG. 3 is a diagram showing an example of the output of the execution cost of a scalar processing device. be. In the figure, ■ is a storage device, 2 is a processing device, 3 is an output list, 10 is an original program, 11.13 is execution cost data, 12 is a magnification table, 20 is a vectorization procedure detection unit, 21 is a magnification determination unit, 22 is an execution cost processing unit;
3 indicates an output section.

Claims (1)

【特許請求の範囲】 ベクトル処理装置によって実行されるプログラム(10
)の実行コストの見積に際し、 該プログラム(10)をスカラ処理装置によって実行す
る場合の実行コスト(11)を入力する手段、該ベクト
ル処理装置と該スカラ処理装置との実行コスト比を、ベ
クトル長の関数として決定するコスト比決定手段(12
)、及び、 該プログラム(10)のベクトル演算ループの繰り返し
演算回数指定値によってベクトル長を推定し、該ベクト
ル長によって該コスト比決定手段から実行コスト比を求
め、該入力手段によって入力する該演算ループの実行コ
ストと、該求めた実行コスト比から、該ベクトル処理装
置によって実行する場合の実行コスト見積を算出する手
段(21、22)を有することを特徴とするプログラム
コスト見積方式。
[Claims] A program (10
), a means for inputting the execution cost (11) when the program (10) is executed by a scalar processing device, and an execution cost ratio of the vector processing device and the scalar processing device are calculated based on the vector length. cost ratio determination means (12) determined as a function of
), and the vector length is estimated based on the specified value of the number of repeated operations in the vector operation loop of the program (10), the execution cost ratio is determined from the cost ratio determination means based on the vector length, and the operation is inputted by the input means. A program cost estimation method comprising means (21, 22) for calculating an execution cost estimate when executed by the vector processing device from the execution cost of a loop and the determined execution cost ratio.
JP60152873A 1985-07-11 1985-07-11 Program cost estimating system Pending JPS6214243A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP60152873A JPS6214243A (en) 1985-07-11 1985-07-11 Program cost estimating system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP60152873A JPS6214243A (en) 1985-07-11 1985-07-11 Program cost estimating system

Publications (1)

Publication Number Publication Date
JPS6214243A true JPS6214243A (en) 1987-01-22

Family

ID=15549984

Family Applications (1)

Application Number Title Priority Date Filing Date
JP60152873A Pending JPS6214243A (en) 1985-07-11 1985-07-11 Program cost estimating system

Country Status (1)

Country Link
JP (1) JPS6214243A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6436885A (en) * 1987-07-30 1989-02-07 Tatsuta Densen Kk Window switchgear
JPH01102656A (en) * 1987-10-15 1989-04-20 Fujitsu Ltd Estimation processing system for system performance

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6436885A (en) * 1987-07-30 1989-02-07 Tatsuta Densen Kk Window switchgear
JPH01102656A (en) * 1987-10-15 1989-04-20 Fujitsu Ltd Estimation processing system for system performance

Similar Documents

Publication Publication Date Title
KR20100075588A (en) Apparatus and method for performing magnitude detection for arithmetic operations
JP2008176453A (en) Simulation device
JPS6214243A (en) Program cost estimating system
CN100409176C (en) Data processing device
Olbert Crossing the machine interface
JP3648286B2 (en) Eigenvector solving method for parallel machine and structural analysis simulation method using the same
JP2621555B2 (en) Vectorization processing method
Enszer et al. Verified solution method for population epidemiology models with uncertainty
JP2653880B2 (en) Program content analyzer
Langtangen et al. Numerical computing in Python
Wakefield STUDIES IN EXECUTION ARCHITECTURES.
JPH01263574A (en) Apparatus for automatically forming test pattern program
CN114217856A (en) AArch64 architecture-oriented CPU instruction micro-benchmark test method and system
JP3838279B2 (en) Computer program execution cost analysis method
JPH03230226A (en) Synchronous wait time measurement system
JP2019012324A (en) compiler
JPH04320536A (en) Method for automatically calculating performance of program
JPS6358574A (en) Vector transformation processing system
JPH0820970B2 (en) Program content analyzer
JPS6373335A (en) Information processor
JPH04273344A (en) Processing time calculation system
JPH05334391A (en) Control circuit generating device
JPH03282641A (en) Measuring method of executing time of data driving processor
Basu et al. Performance Analysis of Pipeline Architecture
JP2000194585A (en) Execution time calculating device for program