JPH02245934A - Data processor - Google Patents

Data processor

Info

Publication number
JPH02245934A
JPH02245934A JP6831889A JP6831889A JPH02245934A JP H02245934 A JPH02245934 A JP H02245934A JP 6831889 A JP6831889 A JP 6831889A JP 6831889 A JP6831889 A JP 6831889A JP H02245934 A JPH02245934 A JP H02245934A
Authority
JP
Japan
Prior art keywords
program
conditional
translation
object program
source
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
JP6831889A
Other languages
Japanese (ja)
Inventor
Sakae Tanabe
田辺 栄
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 JP6831889A priority Critical patent/JPH02245934A/en
Publication of JPH02245934A publication Critical patent/JPH02245934A/en
Pending legal-status Critical Current

Links

Landscapes

  • Devices For Executing Special Programs (AREA)

Abstract

PURPOSE:To simplify control over a source program and an object program and to reduce the use quantity of a disk by providing a condition translation part for the source program as the object program. CONSTITUTION:Each source program containing the condition translation part is translated by a translating means (a) to generate a conditioned object program and a main object program. Then a coupling means (c) links the conditioned object program and main object program according to the condition indication of an indicating means (b) so that the resulting program corresponds to a specific target system, thus generating a load module. Therefore, the source program is translated once to generate the main object program and conditioned object and linkage processing according with the condition is only performed to shorten the time required for the load module generation. Consequently, the control over the source program and object program is simplified and the use quantity of the disk is reduced.

Description

【発明の詳細な説明】 〔概要〕 データ処理装置に関し、 翻訳時間の削減、ソースプログラムおよびオブジェクト
プログラムの管理の簡略化、ディスク使用量の低減を図
ることのできるデータ処理装置を提供することを目的と
し、 条件付きアセンブル又は条件付きコンパイルによって翻
訳を制御される条件翻訳部を有する複数のソースプログ
ラムに対し、各ソースプログラム毎に条件翻訳部を翻訳
して条件付きオブジェクトプログラムを生成するととも
に、該条件翻訳部以外の部分を翻訳して主オブジェクト
プログラムを生成する翻訳手段と、翻訳手段によって翻
訳された条件付きオブジェクトプログラムおよび主オブ
ジェクトプログラムを所定の目標システムに従って結合
させるための条件を指示する指示手段と、指示手段から
の条件指示に基づき前記条件付きオブジェクトプログラ
ムおよび主オブジェクトプログラムを結合させて目標シ
ステムに対応するロードモジュールを生成する結合手段
と、を備えるように構成する。
[Detailed Description of the Invention] [Summary] An object of the present invention is to provide a data processing device that can reduce translation time, simplify management of source programs and object programs, and reduce disk usage. Then, for a plurality of source programs each having a conditional translation section whose translation is controlled by conditional assembly or conditional compilation, the conditional translation section is translated for each source program to generate a conditional object program, and the conditional object program is generated by translating the conditional translation section for each source program. a translation means for translating parts other than the translation part to generate a main object program; and an instruction means for instructing conditions for combining the conditional object program and the main object program translated by the translation means according to a predetermined target system. and a coupling means for coupling the conditional object program and the main object program to generate a load module corresponding to the target system based on a condition instruction from the instruction means.

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

本発明は、データ処理装置に係り、詳しくは、コンピュ
ータシステムにおけるロードモジュールの生成を効率良
く行うデータ処理装置に関する。
The present invention relates to a data processing device, and more particularly, to a data processing device that efficiently generates a load module in a computer system.

コンピュータにおいてシステムを考える際に大きな助け
となるものの1つが、モジュール化である。この考え方
は、ソフトウェア開発における構造プログラミング(s
tructured programing)と同様な
手法である。すなわち、1つのシステムを開発しようと
するときに、システムの果たすべき仕事をいくつかの機
能部分(モジュール)にあらかじめ分割し、この機能モ
ジュールを組み立てることによってシステムを構築する
方法である。本発明では、このような機能モジュールを
ロードモジュールと称している。
One of the things that greatly helps when thinking about computer systems is modularization. This idea is based on structural programming (s) in software development.
This method is similar to structured programming. That is, when developing one system, the system is constructed by dividing the work to be performed by the system into several functional parts (modules) in advance and assembling the functional modules. In the present invention, such a functional module is referred to as a load module.

各機能モジュールは、可能な限り個々のモジュールごと
に開発されデパックされた後、組合わされてシステム機
能の確認が行われる。各機能モジュールのインタフェー
スの標準化を進めておけば、−度デバックされた機能モ
ジュールは、システムの構成要素として他の多くのシス
テムで使用することが可能になる。このような機能モジ
ュールの組合わせでシステムを構成する方法をモジュー
ル化されたシステム構成と呼ぶ。モジュール化されたシ
ステム構成とすることにより、システム開発の期間を短
縮し、拡張性と柔軟性に冨んだシステムを構築すること
が可能になる。
Each functional module is developed individually as much as possible, depacked, and then combined to confirm system functionality. If the interface of each functional module is standardized, a functional module that has been debugged can be used in many other systems as a system component. A method of configuring a system by combining such functional modules is called a modular system configuration. By having a modular system configuration, it is possible to shorten the system development period and build a system that is highly expandable and flexible.

一方、近年ソフトウェアの開発効率向上のため、効率的
なソースプログラムおよびオブジェクトプログラムの作
成、翻訳および結合時間の短縮、作成物の管理の簡略化
、またディスク容量の少ないパーソナル・コンピュータ
等においてはディスク使用の効率化等が要求されている
。このため、ソースプログラムおよびオブジェクトプロ
グラムの共通化を図り、翻訳および結合処理等のロード
モジュール作成に費やす時間を最小限に抑える必要があ
る。
On the other hand, in recent years, efforts have been made to improve the efficiency of software development by creating efficient source programs and object programs, shortening translation and combination times, simplifying the management of created products, and increasing the use of disks for personal computers with limited disk space. There is a need to improve efficiency. Therefore, it is necessary to standardize source programs and object programs and minimize the time spent on creating load modules such as translation and combination processing.

なお、ソースプログラムとは高級言語で記述されたプロ
グラムであり、オブジェクトプログラムとは機械語によ
る言語処理プログラムによって得る機械語のプログラム
をいう、また、翻訳とは前段階で作成されたソースプロ
グラムを、言語処理プログラムを使用して、再配置可能
なモジュール形式または絶対番地形式のオブジェクトプ
ログラムに変換する作業である。通常、言語処理プログ
ラムは、その作業の最終段階でリストファイルとオブジ
ェクトファイルを出力する。リストファイルは、翻訳し
た結果を考察するために帳票として印刷できる形式を持
ったファイルでディスクの中に収容しておき、後に任意
の時点で出力する。この中の情報としては記述文、マシ
ンコード、エラー文、デパック文などが含まれる。一方
、オブジェクトファイルは、実際のマシンコードが再配
置可能な、または全体番地形式で収容されている。
Note that a source program is a program written in a high-level language, an object program is a machine language program obtained by a machine language language processing program, and translation is a program written in a high-level language. This is the process of using a language processing program to convert an object program into a relocatable module format or absolute address format. Usually, a language processing program outputs a list file and an object file at the final stage of its work. The list file is a file in a format that can be printed as a form in order to examine the translated results, and is stored on the disk and output at any time later. This information includes descriptive statements, machine codes, error statements, depack statements, etc. Object files, on the other hand, contain the actual machine code in relocatable or whole address format.

〔従来の技術〕[Conventional technology]

従来の演算処理装置においてソースプログラムおよびオ
ブジェクトプログラム(以下、単にオブジェクトという
)の共通化の手段として機能の一部のみが異なるソフト
ウェアを作成する場合には、条件付きアセンブルおよび
条件付きコンパイルを用いて条件を指定して再翻訳する
方法を取っている。なお、アセンブラとはアセンブリ言
語で記述されたソースプログラムを翻訳し、オブジェク
トプログラムを出力する言語処理プログラムであり、コ
ンパイラとは入力されたあるプログラミング言語を処理
し、目的とするプログラミング言語であるアセンブリ言
語か機械語を出力する言語処理プログラムをいう。また
、条件付きアセンブル(c。
When creating software that differs only in some functions as a means of standardizing source programs and object programs (hereinafter simply referred to as objects) in conventional arithmetic processing units, conditional assembling and conditional compilation are used to create The method is to specify and retranslate. An assembler is a language processing program that translates a source program written in assembly language and outputs an object program, and a compiler is a language processing program that processes an input programming language and produces the target programming language, assembly language. A language processing program that outputs machine language. Also, conditional assembly (c.

nditional assemble)とは、同じソ
ースプログラムのアセンブル条件を、ハードウェア構成
などの変更に適応させる機能であり、ある条件を評価し
、成立する場合にのみソースプログラムのある区間のア
センブルを実行し、不一致の場合はスキップする0条件
付きコンパイルも同様である。したがって、上記従来の
方法では、必要なオブジェクト数の回数だけ、翻訳が行
われる。
ndional assembly) is a function that adapts the assembling conditions of the same source program to changes in the hardware configuration, etc. It evaluates a certain condition, executes assembling of a certain section of the source program only if it holds, and eliminates mismatches. The same goes for 0 conditional compilation, which is skipped if . Therefore, in the conventional method described above, translation is performed as many times as the number of objects required.

のロードモジュールを作成できるようにすることにより
、翻訳時間の削減、ソースプログラムおよびオブジェク
トの管理の簡略化、ディスク使用量の低減を図ることの
できるデータ処理°装置を提供することを目的としてい
る。
The object of the present invention is to provide a data processing device that can reduce translation time, simplify source program and object management, and reduce disk usage by making it possible to create load modules.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

しかしながら、このような従来のデータ処理装置にあっ
ては、ソースプログラムおよび大部分のオブジェクトの
共通化を図ることができるものの、機能の一部のみが異
なるロードモジュールを複数作成する場合に各ロードモ
ジュールで異なるオブジェクトを得るため、条件付アセ
ンブルなどを用い条件を指定して再翻訳をする必要があ
ることから、翻訳に多大の時間を費やさねばならなくな
って、オブジェクトの数が増え、管理に手間がかかり、
また、ディスク使用量も増大するという問題点があった
However, in such conventional data processing devices, although it is possible to standardize the source program and most objects, when creating multiple load modules that differ only in part of their functions, each load module In order to obtain different objects, it is necessary to re-translate by specifying conditions using conditional assembly, etc., which requires a large amount of time to translate, increases the number of objects, and requires time and effort to manage them. It takes,
Furthermore, there is a problem that the amount of disk usage increases.

そこで本発明は、ソースプログラムを1回だけ翻訳すれ
ば、その後は結合処理を行うだけで目的〔課題を解決す
るための手段〕 本発明によるデータ処理装置は上記目的達成のため、そ
の基本概念図を第1図に示すように、条件付きアセンブ
ル又は条件付きコンパイルによって翻訳を制御される条
件翻訳部を有する複数のソースプログラムに対し、各ソ
ースプログラム毎に条件翻訳部を翻訳して条件付きオブ
ジェクトプログラムを生成するとともに、該条件翻訳部
以外の部分を翻訳して主オブジェクトプログラムを生成
する翻訳手段aと、翻訳手段aによって翻訳された条件
付きオブジェクトプログラムおよび主オブジェクトプロ
グラムを所定の目標システムに従って結合させるための
条件を指示する指示手段すと、指示手段すからの条件指
示に基づき前記条件付きオブジェクトプログラムおよび
主オブジェクトプログラムを結合させて目標システムに
対応するロードモジュールを生成する結合手段Cと、を
備えている。
Therefore, the present invention provides that a source program can be translated only once, and then only a combination process can be performed. As shown in Figure 1, for multiple source programs each having a conditional translation section whose translation is controlled by conditional assembly or conditional compilation, the conditional translation section is translated for each source program to create a conditional object program. and a translation means a that generates a main object program by translating parts other than the conditional translation part, and the conditional object program and the main object program translated by the translation means a are combined according to a predetermined target system. the instruction means for instructing the conditions for the target system, and a combination means C for combining the conditional object program and the main object program to generate a load module corresponding to the target system based on the condition instruction from the instruction means. ing.

〔作用〕[Effect]

本発明では、条件翻訳部を含む各ソースプログラムが翻
訳手段により翻訳されて条件付きオブジェクトおよび主
オブジェクトが生成され、その後指示手段からの条件指
示に基づき結合手段によって所定の目標システムに対応
するように条件付きオブジェクトおよび主オブジェクト
が結合され、ロードモジュールが生成される。
In the present invention, each source program including the condition translation unit is translated by the translation means to generate a conditional object and a main object, and then, based on the condition instruction from the instruction means, the source program is translated to correspond to a predetermined target system by the combination means. The conditional object and the main object are combined to generate a load module.

したがって、1回ソースプログラムの翻訳を行い、主オ
ブジェクトおよび条件付きオブジェクトを生成しておけ
ば、条件に応じた結合処理を行うだけでよ(、従来に比
べるとロードモジュール生成に要する時間が短縮し、ソ
ースプログラムおよびオブジェクトの管理の簡略化ディ
スク使用量の低減が図られる。
Therefore, by translating the source program once and generating the main object and conditional objects, all you need to do is perform the combination process according to the conditions (the time required to generate a load module is shorter than in the past). , management of source programs and objects is simplified, and disk usage is reduced.

(実施例〕 以下、本発明を図面に基づいて説明する。(Example〕 Hereinafter, the present invention will be explained based on the drawings.

第2〜5図は本発明に係るデータ処理装置の一実施例を
示す図である。第2図はデータ処理装置のハード構成図
であり、この図において、lはコンピュータ本体で内部
にCPU、メモリ等を有し、ソースプログラムの翻訳、
結合等の必要な演算処理を行って所定の目標システム(
例えば、各種の工業用の制御、画像処理など)に対応す
るロードモジエールを作成する。なお、コンピュータ本
体lの内部メモリには上記翻訳処理に必要な情報が取り
込まれ、演算処理はCPUによって実行される。2はキ
ーボードであり、翻訳および結合処理を行うための指示
をコンピュータ本体1に入力するものである。3は表示
装置で、例えばCRTを含んで構成され、コンピュータ
本体1の処理内容を外部に表示する。4は補助記憶装置
であり、ソースプログラム、オブジェクトプログラムお
よびロードモジュールを保存する。
2 to 5 are diagrams showing an embodiment of a data processing device according to the present invention. Fig. 2 is a hardware configuration diagram of a data processing device.
A predetermined target system (
For example, a load module corresponding to various industrial controls, image processing, etc.) is created. Note that the information necessary for the above-mentioned translation process is taken into the internal memory of the computer main body l, and the arithmetic processing is executed by the CPU. Reference numeral 2 denotes a keyboard, which is used to input instructions for translation and combination processing into the computer main body 1. Reference numeral 3 denotes a display device, which includes, for example, a CRT, and displays the processing contents of the computer main body 1 to the outside. 4 is an auxiliary storage device that stores source programs, object programs, and load modules.

コンピュータ本体1は内部のCPUにより後述の第4図
に示す、フローチャートに従って処理を行うが、この処
理の具体的な概念は第3図のように示され、先に第3図
から説明する。
The computer main body 1 performs processing by an internal CPU according to a flowchart shown in FIG. 4, which will be described later.The specific concept of this processing is shown in FIG. 3, and will be explained first starting from FIG.

第3図において、Sl〜Snはロードモジュールを生成
するために必要なソースプログラムであり、条件翻訳部
■〜nを含んでいる。ここで、条件翻訳部とは、条件付
きアセンブル又は条件付きコンパイルによって翻訳を制
御するコード部のことである* T 1 ” T nは
CPUによって実行される機能により具現化される翻訳
装置(翻訳手段に相当)であり、翻訳装置TI−Tnは
ソースプログラム81〜Snをそれぞれ翻訳し、主オブ
ジェクト01〜Onおよび条件付きオブジェクト01〜
Cnを生成する。主オブジェク1−Of〜Onは条件翻
訳部以外の翻訳結果であり、条件付きオブジェクト01
〜Cnは条件翻訳部の翻訳結果である。また、C1−■
〜Cn−nは条件翻訳部■〜nのそれぞれの主オブジェ
クトである。には結合指示を与える指示手段であり、所
定の目標システムに対応したロードモジュールとなるよ
うにはキーボード2からの指示に従って結合装置(結合
手段に相当)Lに条件を指示する。結合装置りは指示手
段Kからの条件指示に基づき主オブジェクト01〜On
および条件付きオブジェクト01〜Cnのうち必要なも
のを結合させてロードモジュールLMを生成する。
In FIG. 3, Sl-Sn are source programs necessary to generate a load module, and include conditional translation sections 1-n. Here, the conditional translation section is a code section that controls translation by conditional assembly or conditional compilation. (corresponding to
Generate Cn. Main object 1-Of~On is the translation result other than the conditional translation part, and conditional object 01
~Cn is the translation result of the condition translation unit. Also, C1-■
~Cn-n are the main objects of each of the condition translation units ① to n. is an instructing means for giving a coupling instruction, and instructs the coupling device (corresponding to the coupling means) L to specify conditions in accordance with instructions from the keyboard 2 so that the load module corresponds to a predetermined target system. The coupling device turns the main objects 01 to On based on the condition instruction from the instruction means K.
A load module LM is generated by combining necessary conditional objects 01 to Cn.

第4図はロードモジュール生成処理のプログラムを示す
フローチャートであり、PL=Pnはプログラムの各ス
テップを示し、また同図中左側ははキーボード2の入力
処理、右側はCPUが行う処理に区分している。
FIG. 4 is a flowchart showing a program for load module generation processing, where PL=Pn indicates each step of the program, and the left side of the figure is divided into keyboard 2 input processing, and the right side is processing performed by the CPU. There is.

まず、P、で翻訳装置T1〜TnにソースプログラムS
1を入力し、翻訳を指示する。これによ、Ptで翻訳処
理が行われ、P、で主オブジェクト01および条件付き
オブジェクトC1が結合装置りに出力される。次いで、
P4で全ソースプログラム81〜Snの翻訳を終了した
か否かを判別し、最初はソースプログラムS1の翻訳を
終了したのみであるからP、に戻ってソースプログラム
82以下の翻訳を順次実行する。そして、全ソースプロ
グラム51xSnの翻訳を終了すると、次いでP、でキ
ーボード2から入力指示に基づき指示手段Kにより結合
装置りに対して主オブジェクト01〜Onおよび条件付
きオブジェクトを結合させるための条件指示を与える。
First, P sends the source program S to the translation devices T1 to Tn.
Enter 1 to instruct translation. As a result, translation processing is performed at Pt, and at P, the main object 01 and the conditional object C1 are output to the coupling device. Then,
At P4, it is determined whether or not the translation of all the source programs 81 to Sn has been completed, and since the translation of the source program S1 has only been completed at first, the process returns to P and the translation of the source program 82 and subsequent ones is sequentially executed. When the translation of all the source programs 51xSn is completed, the instruction means K sends a conditional instruction to the combining device to combine the main objects 01 to On and the conditional object based on the input instruction from the keyboard 2 at P. give.

これにより、結合装置りでは、まずP6で条件指示があ
るか否かが判別され、条件指示があるときにはP7で主
オブジェクト01〜Onおよび条件指示に該当する条件
付きオブジェクトC1−Cnが結合される。一方、条件
指示がないときはP、で主オブジェク)01〜Onのみ
が結合され、Pw又はpHを経ると、P9で結合装置り
からロードモジュールが出力される0次いで、他にロー
ドモジュールを作成する場合にはpsに戻って同様の処
理を繰り返し、作成しない場合には処理を終了する。
As a result, the combining device first determines whether or not there is a conditional instruction at P6, and if there is a conditional instruction, the main objects 01 to On and the conditional objects C1 to Cn corresponding to the conditional instruction are combined at P7. . On the other hand, if there is no condition instruction, only the main object (01 to On) is combined with P, and after passing through Pw or pH, the load module is output from the combining device at P9.0Then, create another load module. If so, return to ps and repeat the same process, and if not create, end the process.

上記フローチャートにより実行される処理の具体例、は
第5図(a)〜(d)のように示される。
Specific examples of the processing executed according to the above flowchart are shown in FIGS. 5(a) to 5(d).

同図に示すものは機能が異なる3つのロードモジュール
LMI〜LM3の生成過程であり、特に第5図(a)は
翻訳処理を、第5図(b)(C)(d)は結合処理を示
している。また、ソースプログラム5L=SnはC言語
で記述され、同言語中の■〜nは条件付きコンパイルで
処理される文である。特に条件翻訳部に相当する。例え
ば、条件翻訳部のうち■はソースプログラムS1の「A
」が、■およびnはrBJが、■rCJが定義された場
合に翻訳される。なお、翻訳装置T1〜Tnおよび結合
装置りは共にいわゆるO8上で動作するプログラムによ
って実現される。
What is shown in the figure is the generation process of three load modules LMI to LM3 with different functions. In particular, Figure 5(a) shows the translation process, and Figures 5(b), (C, and d) show the combination process. It shows. Further, the source program 5L=Sn is written in C language, and in the same language, ■ to n are statements processed by conditional compilation. In particular, it corresponds to the conditional translation section. For example, ■ in the conditional translation section is "A" in the source program S1.
” is translated when ■ and n are defined as rBJ and ■ rCJ is defined. Note that the translation devices T1 to Tn and the coupling device are both realized by a program running on a so-called O8.

所望のロードモジュールを生成するには、まず、翻訳装
置T1〜TnによってソースプログラムSl〜Snを翻
訳し、主オブジェクト01〜Onおよび条件付きオブジ
ェクト01〜Cnを生成する。
To generate a desired load module, first, source programs Sl to Sn are translated by translation devices T1 to Tn to generate main objects 01 to On and conditional objects 01 to Cn.

このとき、主オブジェクト01〜Onは条件翻訳部■〜
n以外の部分の主オブジェクトであり、条件付きオブジ
ェクトC1−■〜Cn−nは条件翻訳部■〜nのオブジ
ェクトである。次に、結合処理を行う。条件翻訳部■を
含み、■、■、nを含まないロードモジュールLMIを
生成する場合、第5図(b)中のリンクLNIに示すよ
うに、口−ドモジュールを構成する全土オブジェクト0
1〜Onおよびロードモジュールに条件翻訳部■の機能
を含ませるために指示手段Kから与えられる条件指示O
Pとして条件Aを結合装置L1に入力する。これにより
、条件翻訳部■のオブジェクトであるC1−■が主オブ
ジェクト01と結合される。全ての主オブジェクト01
〜Onが結合されてロードモジュールLMIが生成され
る0次に、条件翻訳部■、■およびnを含み、■を含ま
ないロードモジュールLM2を生成するには、第5図に
(C)に示すように、すでに生成された主オブジェクト
01〜On sおよび条件付きオブジェクト01〜Cn
を使用してリンクLN2に示す結合処理を行えばよい、
リンクLN2の結合処理は条件指示OPとして条件B、
Cを結合装置L2に与え、条件翻訳部■のオブジェクト
C1−■および条件翻訳部■のオブジェクトC2−■を
主オブジェクトと結合させてロードモジュールLM2を
生成する。
At this time, the main object 01~On is the condition translation part ■~
This is the main object of the part other than n, and the conditional objects C1-■ to Cn-n are objects of the conditional translation parts 2 to n. Next, a combination process is performed. When generating a load module LMI that includes the condition translation part ■ but does not include ■, ■, and n, as shown in the link LNI in FIG.
1 to On and the condition instruction O given from the instruction means K in order to include the function of the condition translation section ■ in the load module.
Condition A is input as P to the coupling device L1. As a result, C1-■, which is the object of the condition translation section ■, is combined with the main object 01. All main objects 01
~On is combined to generate the load module LMI 0 Next, to generate the load module LM2 that includes the condition translation parts ■, ■, and n, but does not include ■, as shown in FIG. 5 (C). , the already generated main objects 01~On s and conditional objects 01~Cn
You can perform the joining process shown in link LN2 using
The link LN2 connection process uses condition B as the condition instruction OP,
C is given to the combining device L2, and the object C1-■ of the conditional translation section 2 and the object C2-2 of the conditional translation section 2 are combined with the main object to generate a load module LM2.

また、条件翻訳部■、■、■、nの何れも含まないロー
ドモジュールLM3を生成するには第5図(d)に示す
ように、リンクLN3において条件指示を与えずに結合
処理を行う。
Furthermore, in order to generate a load module LM3 that does not include any of the condition translation units ①, ②, ②, and n, as shown in FIG. 5(d), a linking process is performed without giving a condition instruction in link LN3.

このように、本実施例では一回翻訳を行い主オブジェク
トおよび条件付きオブジェクトを生成しておけば、その
後は結合処理だけでロードモジュールを生成できる。し
たがって、条件付きコンパイル等のように翻訳からやり
直すことなく、翻訳時間の削減、ソースプログラムおよ
びオブジェクトの管理の簡略化、ディスク使用量の低減
を図ることができ、コンピュータシステム上でのソフト
ウェア開発の効率向上に寄与するところが大きい。
In this way, in this embodiment, once the main object and conditional object are generated by performing translation, a load module can be generated by only the linking process. Therefore, it is possible to reduce translation time, simplify the management of source programs and objects, and reduce disk usage without having to start over from translation as in conditional compilation, etc., and improve the efficiency of software development on computer systems. It greatly contributes to improvement.

なお、上記実施例ではソースプログラムSl〜SnにC
言語を用いているが、これに限らず、他のプログラミン
グ言語でもよい。また、ソースプログラムは条件翻訳部
のみでもよく、あるいは条件翻訳部を含んでいなくても
よい。
Note that in the above embodiment, the source programs Sl to Sn include C.
Although this language is used, the present invention is not limited to this, and other programming languages may be used. Further, the source program may include only the conditional translation section, or may not include the conditional translation section.

さらに、ソースプログラム中に条件指示OPを記述して
おき、結合時に条件指示OPが指定されない場合に採用
してもよい。また、翻訳装置と結合装置を別々に設けて
いるが、1つのプログラムとしてもよい。
Furthermore, a condition instruction OP may be written in the source program and may be employed when the condition instruction OP is not specified at the time of combination. Further, although the translation device and the combination device are provided separately, they may be integrated into one program.

第5図(a)〜(d)はそのロードモジュール生成の具
体例を示すブロック図である。
FIGS. 5(a) to 5(d) are block diagrams showing specific examples of load module generation.

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

本発明によれば、ソースプログラムについて条件翻訳部
をオブジェクトプログラムとしておくことで、その後は
結合処理のみで目的のロードモジュールを生成すること
ができ、1回の翻訳で済み、翻訳時間の削減、ソースプ
ログラムおよびオブジェクトプログラムの管理の簡略化
、ディスク使用量の低減を図ることができる。
According to the present invention, by making the conditional translation part of the source program an object program, the target load module can be generated by only the combination process after that, only one translation is required, reducing the translation time, and Management of programs and object programs can be simplified and disk usage can be reduced.

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

第1図は本発明の基本概念図、 第2図〜5図は本発明に係るデータ処理装置の一実施例
を示す図であり、 第2図はそのハード構成図、 第3図はその実現機能を示すブロック図、第4図はその
ロードモジュール生成のフローチャート、 1・・・・・・コンピュータ本体、 2・・・・・・キーボード、 3・・・・・・表示装置、 4・・・・・・補助記憶装置、 Tl”−Tn・・・・・・翻訳装置、 LSLl−L3・・・・・・結合装置、K・・・・・・
指示手段。 S1〜Sn・・・・・・ソースプログラム、01〜On
・・・・・・主オブジェクトプログラム、C1〜Cn・
・・・・・条件付きオブジェクトプログラム、 LM、LMI NLM3・・・・・・ロードモジュール
、OP・・・・・・条件指示。
Figure 1 is a basic conceptual diagram of the present invention, Figures 2 to 5 are diagrams showing an embodiment of a data processing device according to the present invention, Figure 2 is a diagram of its hardware configuration, and Figure 3 is its implementation. A block diagram showing the functions, and FIG. 4 is a flowchart for generating the load module. 1...Computer body, 2...Keyboard, 3...Display device, 4... ...Auxiliary storage device, Tl"-Tn...Translation device, LSLl-L3...Coupling device, K...
means of instruction. S1~Sn... Source program, 01~On
・・・・・・Main object program, C1 to Cn・
...Conditional object program, LM, LMI NLM3...Load module, OP...Condition instruction.

Claims (1)

【特許請求の範囲】 a)条件付きアセンブル又は条件付きコンパイルによっ
て翻訳を制御される条件翻訳部を有する複数のソースプ
ログラムに対し、各ソースプログラム毎に条件翻訳部を
翻訳して条件付きオブジェクトプログラムを生成すると
ともに、該条件翻訳部以外の部分を翻訳して主オブジェ
クトプログラムを生成する翻訳手段と、b)翻訳手段に
よって翻訳された条件付きオブジェクトプログラムおよ
び主オブジェクトプログラムを所定の目標システムに従
って結合させるための条件を指示する指示手段と、 c)指示手段からの条件指示に基づき前記条件付きオブ
ジェクトプログラムおよび主オブジェクトプログラムを
結合させて目標システムに対応するロードモジュールを
生成する結合手段と、 を備えたことを特徴とするデータ処理装置。
[Claims] a) For a plurality of source programs each having a conditional translation section whose translation is controlled by conditional assembly or conditional compilation, the conditional translation section is translated for each source program to create a conditional object program. b) for combining the conditional object program and the main object program translated by the translation means in accordance with a predetermined target system; c) a coupling means for coupling the conditional object program and the main object program to generate a load module corresponding to the target system based on the condition instruction from the instruction means; A data processing device characterized by:
JP6831889A 1989-03-20 1989-03-20 Data processor Pending JPH02245934A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6831889A JPH02245934A (en) 1989-03-20 1989-03-20 Data processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6831889A JPH02245934A (en) 1989-03-20 1989-03-20 Data processor

Publications (1)

Publication Number Publication Date
JPH02245934A true JPH02245934A (en) 1990-10-01

Family

ID=13370353

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6831889A Pending JPH02245934A (en) 1989-03-20 1989-03-20 Data processor

Country Status (1)

Country Link
JP (1) JPH02245934A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016143378A (en) * 2015-02-05 2016-08-08 株式会社デンソー Parallelization compilation method, parallelization compiler, and electronic device
JP2016143377A (en) * 2015-02-05 2016-08-08 株式会社デンソー Parallelization compilation method, parallelization compiler, and electronic device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016143378A (en) * 2015-02-05 2016-08-08 株式会社デンソー Parallelization compilation method, parallelization compiler, and electronic device
JP2016143377A (en) * 2015-02-05 2016-08-08 株式会社デンソー Parallelization compilation method, parallelization compiler, and electronic device

Similar Documents

Publication Publication Date Title
US4672532A (en) Software/hardware integration control system
JPH08202545A (en) Object-oriented system and method for generation of target language code
US6467082B1 (en) Methods and apparatus for simulating external linkage points and control transfers in source translation systems
US5812854A (en) Mechanism for integrating user-defined instructions with compiler-generated instructions and for optimizing the integrated instruction stream
JPH08339304A (en) Method and apparatus for generation of platform standard object file containing machine independence code
JPH02238527A (en) Execution of program between target computer system and different computer systems
CA2081473A1 (en) Analyzing inductive expressions in a multilanguage optimizing compiler
US6175935B1 (en) Software debugging method and recording medium to which debugging program has been recorded
JPH02245934A (en) Data processor
GB2127188A (en) Software/hardware integration control system
WO2010029812A1 (en) Programming system in multi-core, and method and program of the same
JP2007226358A (en) Application generation device, application generation method, and application generation program
JPS62205431A (en) Branching instruction processing system
JP2977642B2 (en) FORTRAN compilation processor
JPH08137684A (en) Program transfer method, system and device, for program development, and program execution device
JPH11154093A (en) Program compiler and storage medium recording compiler program
JPH03135630A (en) Instruction scheduling system
JPH02253443A (en) Program generating method
JPH01267731A (en) System for preparing segment overlay program
JP3041919B2 (en) Program combination processor
JP2001014185A (en) Compiling and debugging method
JP2003076547A (en) System and method for automatically generating control software
KR100293932B1 (en) A technology for post image processig of compiled s/w code
JPS58169637A (en) Compile processing system
JPS6320546A (en) Source program level branch tracing system