JP2013149164A - Software verification support device, software verification support method, and software verification support program - Google Patents

Software verification support device, software verification support method, and software verification support program Download PDF

Info

Publication number
JP2013149164A
JP2013149164A JP2012010333A JP2012010333A JP2013149164A JP 2013149164 A JP2013149164 A JP 2013149164A JP 2012010333 A JP2012010333 A JP 2012010333A JP 2012010333 A JP2012010333 A JP 2012010333A JP 2013149164 A JP2013149164 A JP 2013149164A
Authority
JP
Japan
Prior art keywords
instruction
source code
inspection
conditional branch
satisfied
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
JP2012010333A
Other languages
Japanese (ja)
Other versions
JP5865091B2 (en
Inventor
Fumio Narisawa
文雄 成沢
Hiroshi Ishigooka
祐 石郷岡
Tsunamichi TSUKIDATE
統宙 月舘
Wataru Nagaura
永浦  渉
Kohei Sakurai
康平 櫻井
Masahiro Matsubara
正裕 松原
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.)
Hitachi Astemo Ltd
Original Assignee
Hitachi Automotive Systems 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 Hitachi Automotive Systems Ltd filed Critical Hitachi Automotive Systems Ltd
Priority to JP2012010333A priority Critical patent/JP5865091B2/en
Priority to PCT/JP2013/050503 priority patent/WO2013108730A1/en
Publication of JP2013149164A publication Critical patent/JP2013149164A/en
Application granted granted Critical
Publication of JP5865091B2 publication Critical patent/JP5865091B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/40Transformation of program code
    • G06F8/41Compilation
    • G06F8/44Encoding
    • G06F8/443Optimisation
    • G06F8/4434Reducing the memory space required by the program code
    • G06F8/4435Detection or removal of dead or redundant code
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3664Environments for testing or debugging software
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3692Test management for test results analysis

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Software Systems (AREA)
  • Stored Programmes (AREA)
  • Debugging And Monitoring (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide a software verification support technique for providing software which has high safety and reusability and is capable of suppressing a program size.SOLUTION: In the case in which a condition described by a conditional branch instruction is always satisfied, a software verification support device allows instructions executed when the condition is satisfied to remain within a source code, while deleting instructions executed when the condition is not satisfied from the source code.

Description

本発明は、ソフトウェアのソースコードを検証する作業を支援する技術に関する。   The present invention relates to a technique for supporting a task of verifying software source code.

自動車などの制御装置は、マイクロコントローラ(以下マイコンと表記)を用いて制御動作を実行する。マイコンに搭載されるソフトウェアは、一般的には制御処理を実施するアプリケーションプログラムとデータ入出力を実施するデバイスドライバやオペレーティングシステム(OS)などによって構成されている。車両制御装置は、車両乗員の安全性に直接関わる制御を実施するため、高い安全性を要求されている。そのため、制御装置の故障診断を実施し、故障が検出された場合には制御装置を安全な状態へ遷移させる、フェールセーフ処理が用いられている。   A control device such as an automobile executes a control operation using a microcontroller (hereinafter referred to as a microcomputer). The software installed in the microcomputer is generally configured by an application program that performs control processing, a device driver that performs data input / output, an operating system (OS), and the like. The vehicle control device is required to have high safety in order to perform control directly related to the safety of the vehicle occupant. Therefore, fail-safe processing is used in which failure diagnosis of the control device is performed and the control device is transitioned to a safe state when a failure is detected.

また、近年制御の高度化と規模の増大にともない、車両の安全に関わる入出力装置の数が増大し、その診断ソフトウェアの開発工数が課題となっている。   In recent years, with the advancement of control and the increase in scale, the number of input / output devices related to vehicle safety has increased, and the development man-hours of diagnostic software has become a problem.

車両制御に用いるソフトウェアは、多くの製品バリエーションに対応するため、複数の製品に亘って再利用することができるように構成されており、これによりソフトウェアの開発効率を高めている。   Software used for vehicle control is configured to be reusable across a plurality of products in order to cope with many product variations, thereby improving software development efficiency.

例えば、ソフトウェアが搭載される環境に依拠して処理内容が異なる部分については、モジュールとして切り離しておき、環境に依拠せず共通する部分を再利用することができるように構成する。また、環境に依拠する部分を切り離したモジュールについても、実行時に引き渡すパラメータを変えることによって各環境に対応した処理を実行することができるように構成し、再利用性を高めている。   For example, a part having different processing contents depending on the environment in which the software is installed is separated as a module so that a common part can be reused without depending on the environment. Further, the module from which the part depending on the environment is separated is configured such that processing corresponding to each environment can be executed by changing a parameter delivered at the time of execution, thereby improving reusability.

上記のようにパラメータによって動作を変えるソフトウェアモジュールは、環境に応じて様々なパラメータを受け取る場合があるため、当該モジュールが想定していないパラメータを受け取る可能性がある。この場合、想定外のパラメータによって当該モジュールが想定外の動作を引き起こさないようにするため、受け取ったパラメータに関連する動作を実行する前に、そのパラメータが適正であるか否かを判定する必要がある。   As described above, the software module whose operation is changed depending on the parameter may receive various parameters depending on the environment, and thus may receive a parameter that the module does not assume. In this case, in order to prevent the module from causing an unexpected operation due to an unexpected parameter, it is necessary to determine whether or not the parameter is appropriate before performing the operation related to the received parameter. is there.

このようなパラメータの事前検証を実施するためのソフトウェア設計手法として、「防御的プログラミング」と呼ばれる手法がある。防御的プログラミングとは、当該モジュールが想定外の動作条件で呼び出されるかもしれない、との考えに立ち、モジュールが目的とする機能を実施する前に動作条件をチェックし、条件に合致しない場合にはエラー処理などの例外処理を実施する設計手法である。   As a software design technique for performing such parameter pre-verification, there is a technique called “defensive programming”. Defensive programming is based on the belief that the module may be called under unexpected operating conditions, and checks the operating conditions before the module performs the intended function. Is a design method that performs exception handling such as error handling.

下記特許文献1には、エンジン制御用ソフトウェアの動作検証に関する技術として、ソースコードにアサーション命令を挿入することにより、ソフトウェアの動作を検証する技術が記載されている。   Patent Document 1 listed below describes a technique for verifying the operation of software by inserting an assertion instruction into a source code as a technique for verifying the operation of engine control software.

特開2008−276556号公報JP 2008-276556 A

スティーブ・マコネル著,コードコンプリート第2版, 日経BPソフトプレス,2005年Steve McConnell, Code Complete 2nd Edition, Nikkei BP Soft Press, 2005

車両制御のようにリアルタイム制御を実施する必要があるソフトウェアは、安全の観点から制御処理の内容が正しいことが要求されるのはもちろんであるが、その制御処理が適正なタイミングで実施されることも同時に求められる。そのため、数マイクロ秒程度の僅かな処理遅延も許されない場合も多い。   Software that needs to perform real-time control, such as vehicle control, is required to have the correct control processing contents from the viewpoint of safety, but the control processing must be performed at an appropriate timing. Is also required at the same time. Therefore, there are many cases where a slight processing delay of about several microseconds is not allowed.

一方、上述の防御的プログラミングを採用したソフトウェアモジュールは、想定外のパラメータを用いて呼び出された場合にも想定外の動作をしないように、条件分岐命令を用いてパラメータが所定の条件に合致しているか否かを判定し、条件に合致する場合のみ処理を実行するように構成される。そのため、条件分岐命令に係る条件判定、条件に合致しないときの処理等を記述する必要があり、ソースコードの量が増大する傾向がある。その結果、プログラム容量の増大と実行速度の低下を招きやすい。   On the other hand, software modules that employ the above-mentioned defensive programming use conditional branch instructions to ensure that the parameters match a predetermined condition so that they do not operate unexpectedly when called with unexpected parameters. It is configured to execute the process only when the condition is met. For this reason, it is necessary to describe the condition determination related to the conditional branch instruction, the processing when the condition is not met, and the amount of source code tends to increase. As a result, the program capacity increases and the execution speed tends to decrease.

本発明は、上記のような課題を解決するためになされたものであり、高い安全性と再利用性を備え、プログラムサイズを抑えることのできるソフトウェアを得るためのソフトウェア検証支援技術を得ることを目的とする。   The present invention has been made in order to solve the above-described problems, and it is an object of the present invention to obtain a software verification support technique for obtaining software that has high safety and reusability and can reduce the program size. Objective.

本発明に係るソフトウェア検証支援装置は、条件分岐命令が記述している条件が必ず成立する場合は、条件が成立したときに実行される命令をソースコード内に残した上で、条件が成立しなかったときに実行される命令をソースコードから削除する。   When the condition described by the conditional branch instruction is always satisfied, the software verification support apparatus according to the present invention leaves the instruction to be executed when the condition is satisfied in the source code, and then the condition is satisfied. The instruction executed when there is not is deleted from the source code.

本発明に係るソフトウェア検証支援装置によれば、不要な条件分岐命令をソースコードから削除することができるので、元のソースコードの再利用性を確保しつつプログラムサイズを抑えることができる。また、必ず成立する条件分岐命令を削除するので、想定外のパラメータが条件分岐命令に引き渡されて不測の結果を生じることはなく、安全性を確保することができる。   According to the software verification support apparatus of the present invention, unnecessary conditional branch instructions can be deleted from the source code, so that the program size can be suppressed while ensuring reusability of the original source code. Further, since the conditional branch instruction that is always satisfied is deleted, an unexpected parameter is not transferred to the conditional branch instruction, causing an unexpected result, and safety can be ensured.

本発明に係るソフトウェア検証支援装置が対象とするソフトウェアを搭載する自動車エンジン制御システムの構成例を示す図である。It is a figure which shows the structural example of the motor vehicle engine control system carrying the software which the software verification assistance apparatus which concerns on this invention mounts. 本発明に係るソフトウェア検証支援装置100の構成を示す図である。It is a figure which shows the structure of the software verification assistance apparatus 100 which concerns on this invention. ソフトウェア検証支援装置100が検証対象とするソースコードの例である。It is an example of the source code which the software verification assistance apparatus 100 makes into verification object. 図3のソースコードに検査命令を挿入した例を示す図である。It is a figure which shows the example which inserted the test instruction | indication into the source code of FIG. 検査命令生成部120が条件分岐命令1711から条件式部分を抽出する際に用いる条件式パターン1720の例を示す図である。FIG. 10 is a diagram illustrating an example of a conditional expression pattern 1720 used when the test instruction generation unit 120 extracts a conditional expression part from a conditional branch instruction 1711. 検査命令生成部120が生成する検査命令のパターンを示す図である。It is a figure which shows the pattern of the test | inspection command which the test | inspection command production | generation part 120 produces | generates. ソフトウェア検査支援装置100が条件分岐命令を削除した後のソースコード例を示す図である。It is a figure which shows the example of source code after the software test | inspection assistance apparatus 100 deletes a conditional branch instruction. ソフトウェア検査支援装置100が検査命令を生成する処理の動作フローを示す図である。It is a figure which shows the operation | movement flow of the process in which the software test | inspection assistance apparatus 100 produces | generates a test | inspection command. ソフトウェア検査支援装置100がソースコードから条件分岐命令を削除する処理の動作フローを示す図である。It is a figure which shows the operation | movement flow of the process which the software inspection assistance apparatus 100 deletes a conditional branch instruction from a source code. 実施形態2において検査実行部140が検査対象のソースコードをコンパイルして実行する際の動作フローである。10 is an operation flow when the inspection execution unit 140 compiles and executes a source code to be inspected in the second embodiment.

<実施の形態1>
図1は、本発明に係るソフトウェア検証支援装置が対象とするソフトウェアを搭載する自動車エンジン制御システムの構成例を示す図である。コントロールユニット200は、エンジンの動作を制御する制御ソフトウェアを実行する装置であり、マイクロコントローラ210、駆動回路220、通信回路230、信号入出力回路240を備える。
<Embodiment 1>
FIG. 1 is a diagram showing a configuration example of an automobile engine control system in which software targeted by a software verification support apparatus according to the present invention is installed. The control unit 200 is a device that executes control software for controlling the operation of the engine, and includes a microcontroller 210, a drive circuit 220, a communication circuit 230, and a signal input / output circuit 240.

信号入出力回路240は、加速度センサ311とヨーレートセンサ312からそれぞれ検出結果を取得し、マイクロコントローラ210に出力する。駆動回路220は、マイクロコントローラ210からの指示にしたがってアクチュエータ320を駆動制御し、これによりエンジンの動作を制御する。通信回路230は、通信線350を介して診断端末330および制御装置340と通信する。   The signal input / output circuit 240 acquires detection results from the acceleration sensor 311 and the yaw rate sensor 312, and outputs them to the microcontroller 210. The drive circuit 220 drives and controls the actuator 320 according to instructions from the microcontroller 210, thereby controlling the operation of the engine. The communication circuit 230 communicates with the diagnostic terminal 330 and the control device 340 via the communication line 350.

診断端末330は、通信線350を介してコントロールユニット200を診断するための端末である。制御装置340は、コントロールユニット200とは別の制御処理を実施する装置である。   The diagnosis terminal 330 is a terminal for diagnosing the control unit 200 via the communication line 350. The control device 340 is a device that performs control processing different from the control unit 200.

マイクロコントローラ210は、入力回路211、演算装置212、RAM(Random Access Memory)213、ROM(Read Only Memory)214、出力回路215、通信制御装置216を備える。   The microcontroller 210 includes an input circuit 211, an arithmetic unit 212, a RAM (Random Access Memory) 213, a ROM (Read Only Memory) 214, an output circuit 215, and a communication control device 216.

入力回路211は、信号入出力回路240から各センサの検出結果を受け取り、演算装置212に出力する。演算装置212は、制御処理を記述した制御ソフトウェアを実行する。RAM213は、演算装置212が制御ソフトウェアを実行する際に一時的に使用するデータなどを格納する。ROM214は、演算装置212が実行する制御ソフトウェアを格納している。出力回路215は、駆動回路220に対して制御信号を出力する。通信制御装置216は、通信回路230を介して外部と通信する。   The input circuit 211 receives the detection result of each sensor from the signal input / output circuit 240 and outputs it to the arithmetic device 212. The arithmetic device 212 executes control software describing the control process. The RAM 213 stores data temporarily used when the arithmetic device 212 executes the control software. The ROM 214 stores control software executed by the arithmetic device 212. The output circuit 215 outputs a control signal to the drive circuit 220. The communication control device 216 communicates with the outside via the communication circuit 230.

上述の加速度センサ311、ヨーレートセンサ312は、コントロールユニット200に接続されるセンサの1例でありその他のセンサ、例えば温度、電流、その他の物理量を検知するセンサの検出結果を用いて車両を制御するコントロールユニットについても、本発明に係るソフトウェア検証支援装置が対象とするソフトウェアを実行することができることはいうまでもない。   The acceleration sensor 311 and the yaw rate sensor 312 described above are examples of sensors connected to the control unit 200, and control the vehicle using detection results of other sensors, for example, sensors that detect temperature, current, and other physical quantities. Needless to say, the control unit can also execute software targeted by the software verification support apparatus according to the present invention.

図2は、本発明に係るソフトウェア検証支援装置100の構成を示す図である。ソフトウェア検証支援装置100は、制御部110、検査命令生成部120、検査命令挿入部130、検査実行部140、検査結果取得部150、条件分岐削除部160、記憶部170を備える。   FIG. 2 is a diagram showing the configuration of the software verification support apparatus 100 according to the present invention. The software verification support apparatus 100 includes a control unit 110, a test command generation unit 120, a test command insertion unit 130, a test execution unit 140, a test result acquisition unit 150, a conditional branch deletion unit 160, and a storage unit 170.

制御部110は、例えばCPU(Central Processing Unit)などの演算装置で構成され、各機能部を制御する。   The control unit 110 is configured by an arithmetic device such as a CPU (Central Processing Unit), and controls each functional unit.

検査命令生成部120は、ソフトウェアソースコード内の条件分岐命令(典型的には、if−else文)が必ず成立するか否かを検査するための検査命令を生成する。例えば後述するassert命令を、検査命令として用いることができる。検査命令挿入部130は、ソースコード内の条件分岐命令の直前または直後に、検査命令生成部120が生成した検査命令を挿入する。   The check instruction generation unit 120 generates a check instruction for checking whether or not a conditional branch instruction (typically an if-else statement) in the software source code is always satisfied. For example, an assert instruction to be described later can be used as the inspection instruction. The inspection instruction insertion unit 130 inserts the inspection instruction generated by the inspection instruction generation unit 120 immediately before or after the conditional branch instruction in the source code.

検査実行部140は、検査命令を挿入したソースコードをコンパイルして実行し、その結果を記憶部170に格納する。検査命令は、検査実行部140が実行すると、条件分岐命令内の条件式が成立するか否かを示すログを記憶部170に格納するように構成されている。したがって、検査実行部140が検査命令を含むソースコードをコンパイルして実行すると、条件分岐命令内の条件式が成立するか否かを示すログが記憶部170に格納される。   The inspection execution unit 140 compiles and executes the source code in which the inspection instruction is inserted, and stores the result in the storage unit 170. When the inspection instruction is executed by the inspection execution unit 140, a log indicating whether or not the conditional expression in the conditional branch instruction is satisfied is stored in the storage unit 170. Therefore, when the test execution unit 140 compiles and executes the source code including the test instruction, a log indicating whether the conditional expression in the conditional branch instruction is satisfied is stored in the storage unit 170.

検査結果取得部150は、検査実行部140の実行結果を記憶部170から取得し、上述のログにしたがって、条件分岐命令内の条件式が必ず成立するか否かを判定する。   The inspection result acquisition unit 150 acquires the execution result of the inspection execution unit 140 from the storage unit 170, and determines whether the conditional expression in the conditional branch instruction is always satisfied according to the log described above.

条件分岐削除部160は、条件分岐命令内の条件式が必ず成立する場合は、条件が成立したときに実行される命令(if文内に含まれる命令)をソースコード内に残した上で、条件が成立しなかったときに実行される命令(else文に含まれる命令)をソースコードから削除する。条件分岐命令内の条件式が必ずしも成立しない場合は、上記いずれもソースコード内に残す。   If the conditional expression in the conditional branch instruction is always satisfied, the conditional branch deletion unit 160 leaves the instruction to be executed when the condition is satisfied (the instruction included in the if statement) in the source code. An instruction (an instruction included in an else statement) that is executed when the condition is not satisfied is deleted from the source code. If the conditional expression in the conditional branch instruction does not necessarily hold, both of the above are left in the source code.

記憶部170は、ソースコード記憶部171、条件式パターン記憶部172、検査命令記憶部173、検査対象ソースコード記憶部174、検査結果記憶部175、資源制約条件記憶部176を備える。   The storage unit 170 includes a source code storage unit 171, a conditional expression pattern storage unit 172, an inspection instruction storage unit 173, an inspection target source code storage unit 174, an inspection result storage unit 175, and a resource constraint condition storage unit 176.

ソースコード記憶部171は、ソフトウェア検査支援装置100が検査対象とするソースコードを記憶する。条件式パターン記憶部172は、検査命令生成部120が検査命令を生成する際に、条件分岐命令から条件式部分を抽出するために用いる抽出パターンを記憶する。詳細は後述する。検査命令記憶部173は、検査命令生成部120が生成した検査命令を記憶する。検査対象ソースコード記憶部174は、検査命令挿入部130が検査命令を挿入したソースコードを記憶する。検査結果記憶部175は、検査実行部140が検査命令を挿入したソースコードをコンパイルして実行した結果を記憶する。資源制約条件記憶部176は、検査実行部140がソースコードをコンパイルして実行する際に必要となるハードウェアリソースなどの制約条件を記述したデータを記憶する。   The source code storage unit 171 stores a source code to be inspected by the software inspection support apparatus 100. The conditional expression pattern storage unit 172 stores an extraction pattern used for extracting a conditional expression part from a conditional branch instruction when the check instruction generation unit 120 generates a check instruction. Details will be described later. The inspection instruction storage unit 173 stores the inspection instruction generated by the inspection instruction generation unit 120. The inspection source code storage unit 174 stores the source code into which the inspection instruction insertion unit 130 has inserted the inspection instruction. The inspection result storage unit 175 stores a result obtained by compiling and executing the source code into which the inspection instruction is inserted by the inspection execution unit 140. The resource constraint storage unit 176 stores data describing constraint conditions such as hardware resources required when the inspection execution unit 140 compiles and executes the source code.

以上、ソフトウェア検証支援装置100の構成について説明した。次に、ソースコードに検査命令を挿入する処理について、ソースコードの例とともに説明する。   The configuration of the software verification support apparatus 100 has been described above. Next, a process for inserting a test instruction into the source code will be described together with an example of the source code.

図3は、ソフトウェア検証支援装置100が検証対象とするソースコードの例である。本ソースコードには、条件分岐命令(if{)1711、条件不成立時命令(else{)1712、条件分岐終了命令(})1713が含まれている。   FIG. 3 is an example of source code to be verified by the software verification support apparatus 100. This source code includes a conditional branch instruction (if {) 1711, an instruction when condition is not satisfied (else {) 1712, and a conditional branch end instruction (}) 1713.

本ソースコードでは、条件分岐命令1711に含まれる部分において、サイズLINITHの配列を確保し、この配列の最初の要素からパラメータiParamが指定する番号の要素までを初期化している。これらの処理は、配列を初期化すべきサイズがソフトウェアを実行する環境によって異なるため、これをパラメータiParamとして汎用化し、任意サイズの配列を初期化することができるように構成して、環境に依拠しない再利用可能なモジュールとすることを図ったものである。   In this source code, an array of the size LINETH is secured in the portion included in the conditional branch instruction 1711, and the elements from the first element of this array to the element of the number specified by the parameter iParam are initialized. In these processes, since the size of the array to be initialized differs depending on the environment in which the software is executed, this is generalized as a parameter iParam so that an array of an arbitrary size can be initialized and does not depend on the environment. It is intended to be a reusable module.

これらの処理においては、パラメータiParamが配列サイズLINITH未満であることを前提としているため、条件分岐命令1711によって、LINITH以上の値を有するiParamを排除している。すなわち、本ソースコードが作成された時点では、いかなる環境を対象として本ソースコードが用いられるか確定していないため、ソフトウェアの動作を不安定にしないように、不確定なパラメータをあらかじめチェックするようにしたものである。これにより、本ソースコードの再利用性を確保しつつ、動作の安全性を確保することができる。このような手法を、前述の防御的プログラミングと呼ぶ。   In these processes, since it is assumed that the parameter iParam is less than the array size LIMITIT, the conditional branch instruction 1711 excludes iParam having a value greater than or equal to LINETH. In other words, at the time this source code is created, it is not determined what kind of environment this source code will be used for, so indeterminate parameters should be checked in advance so as not to make the operation of the software unstable. It is a thing. As a result, it is possible to ensure the safety of the operation while ensuring the reusability of the source code. Such a technique is referred to as the defensive programming described above.

一方、本ソースコードを利用する環境が確定した以降は、パラメータiParamの値が実行時にとり得る値も確定している場合がある。このような場合には、条件分岐命令1711、条件不成立時命令1712、条件分岐終了命令1713は冗長な記載となり、却ってソフトウェア容量を不要に増大させる原因となる。   On the other hand, after the environment in which the source code is used is determined, there are cases where the value of the parameter iParam can be determined at the time of execution. In such a case, the conditional branch instruction 1711, the condition non-satisfied instruction 1712, and the conditional branch end instruction 1713 are redundantly described, and on the contrary, cause a software capacity to be increased unnecessarily.

そこで本発明では、図3に例示するような条件分岐命令のうち、条件式が必ず成立するものについては、条件分岐命令1711、条件不成立時命令1712、および条件分岐終了命令1713をソースコードから削除し、さらには条件不成立時命令1712内に含まれるエラー処理などの不要な命令も併せて削除することとした。   Therefore, in the present invention, the conditional branch instruction 1711, the condition non-satisfied instruction 1712, and the conditional branch end instruction 1713 are deleted from the source code for the conditional branch instructions such as those illustrated in FIG. In addition, unnecessary instructions such as error processing included in the instruction 1712 when the condition is not satisfied are also deleted.

具体的には、ソフトウェア検証支援装置100は、本ソースコードを利用する環境に固有のパラメータを組み込んだ上で、本ソースコードをコンパイルして実際に実行し、条件分岐命令1711が記述している条件式が実際に成立するか否かを検証する。以下、そのための具体的な手法を説明する。   Specifically, the software verification support apparatus 100 incorporates parameters specific to the environment in which the source code is used, compiles and actually executes the source code, and the conditional branch instruction 1711 is described. It is verified whether or not the conditional expression is actually satisfied. Hereinafter, a specific method for this will be described.

なお、本ソースコードを利用する環境に固有のパラメータは、例えばC言語のヘッダファイルなどのデータファイルに記述することもできるし、環境固有のパラメータを一括して記述したソースコードを本ソースコードとともにコンパイルして実行モジュール内に組み込むことによって本ソースコード内に取り込むこともできる。   The parameters specific to the environment using this source code can be described in a data file such as a C language header file, or the source code describing the parameters specific to the environment together with this source code. It can also be incorporated into this source code by compiling and incorporating it into an execution module.

一般にソースコードには、条件分岐命令が複数含まれている。必ずしも全ての条件分岐命令が、上述のような冗長命令であるわけではないので、ソースコードが利用される環境に依拠して変わる可能性がある条件式を記述した部分のみ、削除するか否かを判定すればよい。そこで図3に示すソースコードには、削除するか否かを判定する対象とする条件分岐命令を識別するため、ソースコードの内容に影響しないコメント文として、条件分岐命令識別コメント1714、条件不成立時命令識別コメント1715、条件分岐終了命令識別コメント1716が付与されている。   In general, a source code includes a plurality of conditional branch instructions. Since not all conditional branch instructions are redundant instructions as described above, whether or not to delete only the part describing conditional expressions that may change depending on the environment in which the source code is used Can be determined. Therefore, in the source code shown in FIG. 3, in order to identify the conditional branch instruction to be determined whether or not to delete, the conditional branch instruction identification comment 1714, a condition not satisfied, is used as a comment statement that does not affect the contents of the source code. An instruction identification comment 1715 and a conditional branch end instruction identification comment 1716 are given.

条件分岐命令識別コメント1714、条件不成立時命令識別コメント1715、条件分岐終了命令識別コメント1716はそれぞれ、条件分岐命令1711、条件不成立時命令1712、および条件分岐終了命令1713が記述されている箇所をソフトウェア検証支援装置100が識別するためのものである。コメント文の形式は任意でよいが、図3では例として、「@CC_if_識別番号」「@CC_else_識別番号」「@CC_endif_識別番号」という形式でコメントを付与した。   A conditional branch instruction identification comment 1714, a condition identification failure instruction identification comment 1715, and a conditional branch termination instruction identification comment 1716 are software locations where the conditional branch instruction 1711, conditional branch failure instruction 1712, and conditional branch termination instruction 1713 are described, respectively. This is for the verification support apparatus 100 to identify. The format of the comment sentence may be arbitrary, but in FIG. 3, as an example, comments are given in the form of “@CC_if_identification number”, “@CC_else_identification number”, and “@CC_endif_identification number”.

条件分岐命令1711が記述している条件式が実際に成立するか否かを検証するためには、ソースコードをコンパイルして実行することに加えて、条件式が成立した際にその旨を何らかのログとして記録することが望ましい。例えば、条件分岐命令1711内に、適当なログを記録する命令を新たに挿入することが考えられる。条件分岐命令1711内の命令は、その条件式が成立した場合に限って実行されるので、条件分岐命令1711内にログ記録命令を挿入しておけば、その命令が実行されたということは条件式が成立したということと等価だからである。   In order to verify whether or not the conditional expression described in the conditional branch instruction 1711 is actually satisfied, in addition to compiling and executing the source code, when the conditional expression is satisfied It is desirable to record as a log. For example, it is conceivable to newly insert an instruction for recording an appropriate log in the conditional branch instruction 1711. The instruction in the conditional branch instruction 1711 is executed only when the conditional expression is satisfied. Therefore, if a log recording instruction is inserted in the conditional branch instruction 1711, it means that the instruction is executed. This is equivalent to the fact that the formula is established.

本実施形態1では、これと同様の機能を備えた関数として、ソフトウェアの動作検証においてよく用いられるassert命令を用いる。assert命令は、指定した条件式が成立したときはtrueを返し、成立しなかったときはfalseを返す、またはこれと同様の動作をする関数である。本実施形態1では、次の図4に示す_CPROVER_assertという検査命令を用いることとする。これは、指定した条件式が成立したか否かを示すログを、検査結果記憶部175に格納するように構成された命令である。   In the first embodiment, an assert instruction often used in software operation verification is used as a function having the same function. The assert instruction is a function that returns true when a specified conditional expression is satisfied, and returns false when the specified conditional expression is not satisfied, or performs a similar operation. In the first embodiment, it is assumed that a check instruction called _COVER_assert shown in FIG. 4 is used. This is an instruction configured to store in the inspection result storage unit 175 a log indicating whether or not a specified conditional expression is satisfied.

図4は、図3のソースコードに検査命令を挿入した例を示す図である。図4において、条件分岐命令1711の直前に、検査命令1717が新たに挿入されている。   FIG. 4 is a diagram showing an example in which a test instruction is inserted into the source code of FIG. In FIG. 4, a check instruction 1717 is newly inserted immediately before the conditional branch instruction 1711.

検査命令挿入部130は、条件分岐命令識別コメント1714をソースコード内に見つけると、対応する条件分岐命令1711が必ず成立するか否かを検証するための検査命令1717を、条件分岐命令1711の直前(または直後)に挿入する。   When the check instruction insertion unit 130 finds the conditional branch instruction identification comment 1714 in the source code, the check instruction insertion unit 130 generates a check instruction 1717 for verifying whether or not the corresponding conditional branch instruction 1711 is always established, immediately before the conditional branch instruction 1711. Insert (or immediately after).

検査命令1717は、条件分岐命令1711が成立するか否かを検証するためのものであるため、検査命令1717が指定する条件式は条件分岐命令1711内の条件式と同一である必要がある。検査命令生成部120は、条件分岐命令1711から条件式部分を抽出し、これを条件式として指定した検査命令1717を生成する。   Since the check instruction 1717 is for verifying whether or not the conditional branch instruction 1711 is established, the conditional expression specified by the check instruction 1717 needs to be the same as the conditional expression in the conditional branch instruction 1711. The check instruction generation unit 120 extracts a conditional expression part from the conditional branch instruction 1711 and generates a check instruction 1717 that specifies this as a conditional expression.

図5は、検査命令生成部120が条件分岐命令1711から条件式部分を抽出する際に用いる条件式パターン1720の例を示す図である。条件式パターンとは、プログラムコード内において条件式が開始または終了する旨を指定する文字列と、条件式そのものを記述した文字列とを抽出するための文字列テンプレートであり、条件式パターン記憶部172内にデータとして記憶されている。例えば正規表現を用いて条件式パターン1720を記述することができるが、これに限られるものではなく、指定した文字列表現に合致する文字列を抽出することができればよい。図5では、正規表現を用いて条件式パターン1720を構成した例を示した。   FIG. 5 is a diagram illustrating an example of a conditional expression pattern 1720 used when the test instruction generation unit 120 extracts a conditional expression portion from the conditional branch instruction 1711. The conditional expression pattern is a character string template for extracting a character string that specifies that the conditional expression starts or ends in the program code and a character string that describes the conditional expression itself, and a conditional expression pattern storage unit. 172 is stored as data. For example, the conditional expression pattern 1720 can be described using a regular expression. However, the present invention is not limited to this, and it is only necessary to extract a character string that matches a specified character string expression. FIG. 5 shows an example in which the conditional expression pattern 1720 is configured using regular expressions.

図5に示す条件式パターン1720は、条件式が開始または終了する旨を指定する文字列を抽出するための定型パターン1721と、定型パターン1721の間に記述されている任意の文字列を抽出するための任意パターン1722とを有する。検査命令生成部120は、条件式パターン1720を用いて、if文内に記述されている条件式(図3〜図4の例では、iParam<LINITH)を抽出することができる。   The conditional expression pattern 1720 shown in FIG. 5 extracts an arbitrary character string described between a fixed pattern 1721 for extracting a character string specifying that the conditional expression starts or ends and a fixed pattern 1721. And an optional pattern 1722. Using the conditional expression pattern 1720, the test instruction generation unit 120 can extract a conditional expression described in the if statement (iParam <LINETH in the examples of FIGS. 3 to 4).

なお、条件式パターン1720は、複数の抽出パターンを記述することもできる。検査命令生成部120は、いずれかの抽出パターンに合致する文字列を発見したときはその条件式を用いて検査命令1717を生成し、全ての抽出パターンに合致しない条件分岐命令については空の条件を指定して検査命令1717を生成する。   The conditional expression pattern 1720 can also describe a plurality of extraction patterns. When the check instruction generation unit 120 finds a character string that matches any of the extraction patterns, the check instruction generation unit 120 generates the check instruction 1717 using the conditional expression, and the conditional branch instruction that does not match all the extraction patterns has an empty condition. Is specified, and the inspection instruction 1717 is generated.

図6は、検査命令生成部120が生成する検査命令のパターンを示す図である。検査命令生成部120は、図6に示す検査命令パターン1730に準じて検査命令を生成し、検査命令記憶部173に格納する。検査命令挿入部130は、検査命令記憶部173が格納している検査命令を読み出し、ソースコードに挿入する。   FIG. 6 is a diagram illustrating a pattern of inspection instructions generated by the inspection instruction generation unit 120. The inspection instruction generation unit 120 generates an inspection instruction according to the inspection instruction pattern 1730 shown in FIG. 6 and stores it in the inspection instruction storage unit 173. The inspection instruction insertion unit 130 reads the inspection instruction stored in the inspection instruction storage unit 173 and inserts it into the source code.

検査命令パターン1730は、行番号部1731、挿入箇所指示部1732、検査命令固定部1733、条件式部1734を有する。   The inspection instruction pattern 1730 includes a line number portion 1731, an insertion location instruction portion 1732, an inspection instruction fixing portion 1733, and a conditional expression portion 1734.

行番号部1731は、検査命令を挿入すべきソースコード内の行番号を指定する。挿入箇所指示部1732は、行番号部1731が指定する行の直前に検査命令を挿入するか、直後に挿入するかを指定する。検査命令固定部1733は、検査命令を記述した文字列のうち、条件式を除いた固定部分である。条件式部1734は、検査命令生成部120が条件式パターン1720を用いて条件分岐命令から抽出する条件式を埋め込む部分である。   The line number part 1731 designates a line number in the source code into which the inspection instruction is to be inserted. The insertion location instruction unit 1732 specifies whether the inspection instruction is inserted immediately before or immediately after the line designated by the line number part 1731. The inspection instruction fixing unit 1733 is a fixed part excluding the conditional expression in the character string describing the inspection instruction. The conditional expression unit 1734 is a part in which the conditional expression extracted from the conditional branch instruction by the check instruction generation unit 120 using the conditional expression pattern 1720 is embedded.

図7は、ソフトウェア検査支援装置100が条件分岐命令を削除した後のソースコード例を示す図である。図3〜図4で例示したソースコードのうち、条件分岐命令1711、条件不成立時命令1712、条件分岐終了命令1713、条件分岐命令識別コメント1714、条件不成立時命令識別コメント1715、条件分岐終了命令識別コメント1716、検査命令1717がソースコードから削除され、さらには条件不成立時命令1712内に含まれるエラー処理などの不要な命令も併せて削除されている。この結果、削除した部分に対応するオブジェクトコードは生成されないので、プログラム容量およびプログラム実行負荷を低減することができる。   FIG. 7 is a diagram illustrating an example of source code after the software inspection support apparatus 100 deletes the conditional branch instruction. 3 to 4, the conditional branch instruction 1711, the condition unsatisfied instruction 1712, the conditional branch end instruction 1713, the conditional branch instruction identification comment 1714, the condition unsatisfied instruction identification comment 1715, and the conditional branch end instruction identification. The comment 1716 and the inspection instruction 1717 are deleted from the source code, and unnecessary instructions such as error processing included in the instruction 1712 when the condition is not satisfied are also deleted. As a result, the object code corresponding to the deleted part is not generated, so that the program capacity and the program execution load can be reduced.

以上、ソフトウェア検査支援装置100がソースコードから条件分岐命令を削除する際の基本的な考え方について説明した。以下では、ソフトウェア検査支援装置100の具体的な動作手順を説明する。   The basic concept when the software inspection support apparatus 100 deletes the conditional branch instruction from the source code has been described above. Hereinafter, a specific operation procedure of the software inspection support apparatus 100 will be described.

図8は、ソフトウェア検査支援装置100が検査命令を生成する処理の動作フローを示す図である。以下、図8の各ステップについて説明する。
(図8:ステップS800)
ソフトウェア検査支援装置100は、検査対象であるソースコードをコンパイルして実行する前に、本動作フローを実行して検査命令を生成する。
(図8:ステップS801)
検査命令生成部120は、ソースコード記憶部171から検査対象であるソースコードを1行分読み出す。また、図6で説明した行番号部1731の値を1加算して更新する。
FIG. 8 is a diagram illustrating an operation flow of processing in which the software inspection support apparatus 100 generates an inspection instruction. Hereinafter, each step of FIG. 8 will be described.
(FIG. 8: Step S800)
The software inspection support apparatus 100 executes this operation flow and generates an inspection instruction before compiling and executing the source code to be inspected.
(FIG. 8: Step S801)
The inspection instruction generation unit 120 reads one line of source code to be inspected from the source code storage unit 171. Further, the value of the row number portion 1731 described with reference to FIG.

(図8:ステップS802)
検査命令生成部120は、ステップS801で読み込んだ1行分のソースコード内に、条件分岐命令識別コメント1714(@CC_if_識別番号)が含まれているか否かを判定する。含まれている場合はステップS803へ進み、含まれていない場合はステップS805へスキップする。
(図8:ステップS803)
検査命令生成部120は、条件分岐命令に含まれる条件式を、図5で説明した条件式パターンにしたがって抽出する。
(FIG. 8: Step S802)
The test instruction generation unit 120 determines whether or not the conditional branch instruction identification comment 1714 (@CC_if_identification number) is included in the source code for one line read in step S801. If it is included, the process proceeds to step S803. If it is not included, the process skips to step S805.
(FIG. 8: Step S803)
The test instruction generation unit 120 extracts the conditional expression included in the conditional branch instruction according to the conditional expression pattern described with reference to FIG.

(図8:ステップS804)
検査命令生成部120は、ステップS803で抽出した条件式と、図6で説明した検査命令パターンにしたがって、検査命令を生成し、検査命令記憶部173に格納する。行番号部1731には、ステップS801で更新した行番号を用いる。挿入箇所指示部1732の値は、例えばあらかじめ指定しておけばよい。また、条件分岐命令識別コメント1714に含まれている識別番号を記憶しておき、検査命令の実行結果を検査結果記憶部175に格納する際に、併せて格納する。
(図8:ステップS805)
ステップS801で読み込んだソースコードの終端に達している場合はステップS806へ進み、読み込んでいない行が残っている場合はステップS801に戻って同様の処理を繰り返す。
(FIG. 8: Step S804)
The inspection instruction generation unit 120 generates an inspection instruction according to the conditional expression extracted in step S803 and the inspection instruction pattern described in FIG. 6 and stores the inspection instruction in the inspection instruction storage unit 173. The line number updated in step S801 is used for the line number portion 1731. The value of the insertion location instruction unit 1732 may be specified in advance, for example. Further, the identification number included in the conditional branch instruction identification comment 1714 is stored, and stored together with the execution result of the inspection instruction in the inspection result storage unit 175.
(FIG. 8: Step S805)
If the end of the source code read in step S801 has been reached, the process proceeds to step S806, and if a line that has not been read remains, the process returns to step S801 and the same processing is repeated.

(図8:ステップS806)
本動作フローが終了した後、検査命令挿入部130は、検査命令生成部120が生成して検査命令記憶部173に格納した検査命令を、行番号部1731が指定する行の直前または直後に挿入し、検査対象ソースコード記憶部174に格納する。検査実行部140は、検査命令が挿入されたソースコードをコンパイルして実行し、検査命令の実行結果を検査結果記憶部175に格納する。また、必要に応じて資源制約条件記憶部176からハードウェアリソースに関する制約条件を取得し、これを満たす範囲内で検査を実施する。
(FIG. 8: Step S806)
After this operation flow ends, the test instruction insertion unit 130 inserts the test command generated by the test command generation unit 120 and stored in the test command storage unit 173 immediately before or after the line specified by the line number unit 1731. And stored in the inspection source code storage unit 174. The inspection execution unit 140 compiles and executes the source code in which the inspection instruction is inserted, and stores the execution result of the inspection instruction in the inspection result storage unit 175. Moreover, the restriction condition regarding the hardware resource is acquired from the resource restriction condition storage unit 176 as necessary, and the inspection is performed within a range satisfying the restriction condition.

図9は、ソフトウェア検査支援装置100がソースコードから条件分岐命令を削除する処理の動作フローを示す図である。以下、図9の各ステップについて説明する。
(図9:ステップS900)
ソフトウェア検査支援装置100は、検査対象であるソースコードをコンパイルして実行した後に本動作フローを実行し、条件分岐命令をソースコードから削除する。
(図9:ステップS901)
検査結果取得部150は、検査結果記憶部175から検査命令の実行結果を取得する。検査命令の実行結果は、ソースコード内に複数存在する検査命令それぞれの条件式が成立したか否か、および検査命令の識別番号(条件分岐命令識別コメント1714に含まれている識別番号)を含む。検査結果取得部150は、各検査命令を識別番号によって区別した上で、それぞれの検査結果をリストアップする。
FIG. 9 is a diagram illustrating an operation flow of processing in which the software inspection support apparatus 100 deletes the conditional branch instruction from the source code. Hereinafter, each step of FIG. 9 will be described.
(FIG. 9: Step S900)
The software inspection support apparatus 100 executes this operation flow after compiling and executing the source code to be inspected, and deletes the conditional branch instruction from the source code.
(FIG. 9: Step S901)
The inspection result acquisition unit 150 acquires the execution result of the inspection instruction from the inspection result storage unit 175. The execution result of the check instruction includes whether or not a conditional expression of each of the check instructions existing in the source code is satisfied, and the check instruction identification number (the identification number included in the conditional branch instruction identification comment 1714). . The inspection result acquisition unit 150 lists each inspection result after distinguishing each inspection instruction by an identification number.

(図9:ステップS902)
条件分岐削除部160は、検査命令を挿入したソースコードを、検査対象ソースコード記憶部174から1行ずつ読み出す。
(図9:ステップS903)
条件分岐削除部160は、ステップS902で読み込んだ1行分のソースコード内に、条件分岐命令識別コメント1714が含まれているか否かを判定する。含まれている場合はステップS904に進み、含まれていない場合はステップS911へ進む。
(FIG. 9: Step S902)
The conditional branch deletion unit 160 reads the source code into which the inspection instruction is inserted from the inspection target source code storage unit 174 line by line.
(FIG. 9: Step S903)
The conditional branch deletion unit 160 determines whether or not the conditional branch instruction identification comment 1714 is included in the source code for one line read in step S902. If it is included, the process proceeds to step S904. If it is not included, the process proceeds to step S911.

(図9:ステップS904)
条件分岐削除部160は、条件分岐命令識別コメント1714に含まれている識別番号をキーにして、検査結果記憶部175から当該条件分岐命令に対応する検査命令の検査結果を取得する。
(図9:ステップS905)
ステップS904で取得した検査結果が検査成功である場合はステップS906へ進み、検査失敗である場合はステップS911へ進む。
(図9:ステップS905:補足)
本ステップにおける検査結果が検査成功である場合は、対応する条件分岐命令内の条件文が成立していることを示しているので、ステップS906以降のステップに進んで冗長な命令文を削除する。本ステップにおける検査結果が失敗である場合は、ステップS902で読み込んだ条件分岐命令内の条件文が必ずしも成立するとは限らないことを示しているので、ステップS911に進んでその条件分岐命令はソースコード内に残す。
(FIG. 9: Step S904)
The conditional branch deletion unit 160 acquires the inspection result of the inspection instruction corresponding to the conditional branch instruction from the inspection result storage unit 175 using the identification number included in the conditional branch instruction identification comment 1714 as a key.
(FIG. 9: Step S905)
If the inspection result acquired in step S904 is a successful inspection, the process proceeds to step S906, and if the inspection is unsuccessful, the process proceeds to step S911.
(FIG. 9: Step S905: Supplement)
If the check result in this step is a check success, it indicates that the conditional statement in the corresponding conditional branch instruction is established, and thus the process proceeds to the steps after step S906 to delete the redundant instruction statement. If the check result in this step is failure, it indicates that the conditional statement in the conditional branch instruction read in step S902 does not necessarily hold, so the process proceeds to step S911, where the conditional branch instruction is the source code. Leave in.

(図9:ステップS906)
条件分岐削除部160は、直前に読み込んだソースコード行の次行を、検査対象ソースコード記憶部174から読み出す。
(図9:ステップS907)
条件分岐削除部160は、ステップS906で読み込んだ1行分のソースコード内に、条件不成立時命令識別コメント1715が含まれているか否かを判定する。含まれている場合はステップS909に進み、含まれていない場合はステップS908へ進む。
(FIG. 9: Step S906)
The conditional branch deletion unit 160 reads the next line of the source code line read immediately before from the inspection source code storage unit 174.
(FIG. 9: Step S907)
The conditional branch deletion unit 160 determines whether or not the instruction identification comment 1715 when the condition is not satisfied is included in the source code for one line read in step S906. If it is included, the process proceeds to step S909. If it is not included, the process proceeds to step S908.

(図9:ステップS908)
条件分岐削除部160は、ステップS906で読み込んだ1行分のソースコードを、そのまま検査対象ソースコード記憶部174に書き戻す。本ステップの後はステップS906に戻り、同様の処理を繰り返す。
(図9:ステップS909)
条件分岐削除部160は、直前に読み込んだソースコード行の次行を、検査対象ソースコード記憶部174から読み出す。
(FIG. 9: Step S908)
The conditional branch deletion unit 160 writes the source code for one line read in step S906 as it is into the inspection source code storage unit 174. After this step, the process returns to step S906 and the same processing is repeated.
(FIG. 9: Step S909)
The conditional branch deletion unit 160 reads the next line of the source code line read immediately before from the inspection source code storage unit 174.

(図9:ステップS910)
条件分岐削除部160は、ステップS909で読み込んだ1行分のソースコード内に、条件分岐終了命令識別コメント1716が含まれているか否かを判定する。含まれていない場合はステップS909へ戻って同様の処理を繰り返す。含まれている場合はステップS902に戻って同様の処理を繰り返す。
(図9:ステップS911)
条件分岐削除部160は、ステップS902で読み込んだ1行分のソースコードを、そのまま検査対象ソースコード記憶部174に書き戻す。
(図8:ステップS912)
ソースコードの終端に達している場合は本動作フローを終了し、読み込んでいない行が残っている場合はステップS902に戻って同様の処理を繰り返す。
(FIG. 9: Step S910)
The conditional branch deletion unit 160 determines whether or not the conditional branch end instruction identification comment 1716 is included in the source code for one line read in step S909. If not included, the process returns to step S909 to repeat the same processing. If it is included, the process returns to step S902 and the same processing is repeated.
(FIG. 9: Step S911)
The conditional branch deletion unit 160 writes the source code for one line read in step S902 back to the inspection source code storage unit 174 as it is.
(FIG. 8: Step S912)
If the end of the source code has been reached, this operation flow is terminated. If there are any unread lines remaining, the process returns to step S902 to repeat the same processing.

<実施の形態1:まとめ>
以上のように、本実施形態1に係るソフトウェア検証支援装置100は、検査命令を挿入したソースコードをコンパイルして実行し、条件分岐命令内の条件式が必ず成立することが判明した場合は、冗長な条件分岐命令などをソースコード内から削除する。これにより、不要な条件分岐命令、条件不成立時命令、条件分岐終了命令、および条件不成立時命令内に含まれる命令を除去し、コンパイル後のプログラム容量を抑えることができる。また、冗長な命令を削除することにより、処理負荷を軽減して制御処理のリアルタイム性を高めることができる。
<Embodiment 1: Summary>
As described above, the software verification support apparatus 100 according to the first embodiment compiles and executes the source code in which the check instruction is inserted, and when it is found that the conditional expression in the conditional branch instruction is always satisfied, Delete redundant conditional branch instructions from the source code. As a result, unnecessary conditional branch instructions, conditional failure instructions, conditional branch end instructions, and instructions included in conditional failure instructions can be removed, and the program capacity after compilation can be reduced. Also, by deleting redundant instructions, the processing load can be reduced and the real-time performance of the control processing can be improved.

また、本実施形態1に係るソフトウェア検証支援装置100は、検査命令を挿入したソースコードをコンパイルして実行する際に、ソースコードが利用される環境に固有のパラメータを記述したデータファイルを取り込み、検証対象であるソースコードと組み合わせて実行する。これにより、検査対象のソースコードが利用される環境を模擬し、条件分岐命令内の条件式が当該環境下で確実に成立するか否かを、シミュレーション環境下で検証することができる。   Further, the software verification support apparatus 100 according to the first embodiment takes in a data file describing parameters specific to the environment in which the source code is used when compiling and executing the source code in which the inspection instruction is inserted, Execute in combination with the source code to be verified. As a result, it is possible to simulate an environment in which the source code to be inspected is used, and to verify whether the conditional expression in the conditional branch instruction is reliably established in the environment.

<実施の形態2>
実施の形態1では、検査実行部140が検査命令を埋め込んだソースコードをコンパイルして実行することを説明した。一般に、ソースコードをコンパイルして実際に実行することによりソースコードの挙動を検査する処理は、CPU負荷やメモリ使用量などのハードウェアリソースを多大に消費するため、ハードウェアリソースに関する何らかの制約条件が課される場合がある。本発明の実施形態2では、その具体例を説明する。検査実行部140の動作以外については実施形態1と概ね同様であるため、以下では差異点を中心に説明する。
<Embodiment 2>
In the first embodiment, it has been described that the inspection execution unit 140 compiles and executes the source code in which the inspection instruction is embedded. In general, the process of inspecting the behavior of source code by compiling and actually executing the source code consumes a lot of hardware resources such as CPU load and memory usage. May be imposed. In the second embodiment of the present invention, a specific example will be described. Since operations other than the operation of the inspection execution unit 140 are substantially the same as those in the first embodiment, the following description will focus on differences.

図10は、本実施形態2において検査実行部140が検査対象のソースコードをコンパイルして実行する際の動作フローである。以下、図10の各ステップについて説明する。
(図10:ステップS1000)
検査実行部140は、図8のステップS806において、本動作フローを開始する。
(図10:ステップS1001〜S1002)
検査実行部140は、検査対象ソースコード記憶部174から検査対象のソースコードを読み出す(S1001)。また、資源制約条件記憶部176からハードウェアリソースに関する制約条件を取得する(S1002)。
(図10:ステップS1002:補足)
本実施形態2において、資源制約条件記憶部176が記憶しているハードウェアリソースに関する制約条件は、使用メモリ量の最大値と、検査開始からの最大経過時間である。
FIG. 10 is an operation flow when the inspection execution unit 140 compiles and executes the source code to be inspected in the second embodiment. Hereinafter, each step of FIG. 10 will be described.
(FIG. 10: Step S1000)
The inspection execution unit 140 starts this operation flow in step S806 of FIG.
(FIG. 10: Steps S1001 to S1002)
The inspection execution unit 140 reads the inspection target source code from the inspection target source code storage unit 174 (S1001). Further, the constraint condition related to the hardware resource is acquired from the resource constraint condition storage unit 176 (S1002).
(FIG. 10: Step S1002: Supplement)
In the second embodiment, the constraint conditions related to the hardware resources stored in the resource constraint storage unit 176 are the maximum value of the used memory amount and the maximum elapsed time from the start of inspection.

(図10:ステップS1003)
検査実行部140は、ステップS1001で読み出した検査対象ソースコードをコンパイルし、実行開始する。本ステップの処理は、一般的なソフトウェア検証ツールを用いて実行することができる。例えば、CBMC(Edmund Clarke著,ANSI−C Bounded Model Checker User Manual,2006年を参照)などのツールを用いることができる。同ツールは、ソフトウェアソースコード内に記載された条件が満たされているか否かを網羅的に検証するソフトウェアである。
(図10:ステップS1004)
検査実行部140は、検査を実行しながら所定時間待機する。
(FIG. 10: Step S1003)
The inspection execution unit 140 compiles the inspection target source code read in step S1001 and starts execution. The processing in this step can be executed using a general software verification tool. For example, a tool such as CBMC (see Edmund Clarke, ANSI-C Bounded Model Checker User Manual, 2006) can be used. This tool is software that comprehensively verifies whether or not the conditions described in the software source code are satisfied.
(FIG. 10: Step S1004)
The inspection execution unit 140 waits for a predetermined time while executing the inspection.

(図10:ステップS1005)
検査実行部140は、現在のメモリ使用量を取得する。メモリ使用量を取得する具体的な方法としては、検査プログラムが動作している計算機のオペレーティングシステムのシステムコールなどを用いればよい。取得したメモリ使用量が資源制約条件記憶部176によって規定されている最大使用量を超えている場合はステップS1007へ進み、超えていない場合はステップS1006へ進む。
(図10:ステップS1006)
検査実行部140は、現在時刻を取得し、検査を開始してからの経過時間を算出する。
(FIG. 10: Step S1005)
The inspection execution unit 140 acquires the current memory usage. As a specific method for acquiring the memory usage, a system call of the operating system of the computer on which the inspection program is operating may be used. If the acquired memory usage exceeds the maximum usage specified by the resource constraint storage unit 176, the process proceeds to step S1007. If not, the process proceeds to step S1006.
(FIG. 10: Step S1006)
The inspection execution unit 140 acquires the current time and calculates the elapsed time since the start of the inspection.

(図10:ステップS1007)
検査実行部140は、ステップS1003で開始した検査を中断し、使用メモリ量超過エラー処理を実行する。例えば、検査を中断した時点で実行していたソースコードの行番号を、検査結果記憶部175に格納する。
(図10:ステップS1008)
検査実行部140は、検査を開始してからの経過時間が資源制約条件記憶部176によって規定されている最大経過時間を超えている場合はステップS1010へ進み、超えていない場合はステップS1009へ進む。
(FIG. 10: Step S1007)
The inspection execution unit 140 interrupts the inspection started in step S1003 and executes the used memory amount excess error process. For example, the line number of the source code being executed when the inspection is interrupted is stored in the inspection result storage unit 175.
(FIG. 10: Step S1008)
The inspection execution unit 140 proceeds to step S1010 if the elapsed time from the start of inspection exceeds the maximum elapsed time specified by the resource constraint storage unit 176, and proceeds to step S1009 if it does not exceed the maximum elapsed time. .

(図10:ステップS1009)
検査実行部140は、ステップS1003で開始した検査が終了している場合は本動作フローを終了し、検査途中である場合はステップS1004に戻って同様の処理を繰り返す。
(図10:ステップS1010)
検査実行部140は、ステップS1003で開始した検査を中断し、経過時間超過エラー処理を実行する。例えば、検査を中断した時点で実行していたソースコードの行番号を、検査結果記憶部175に格納する。
(FIG. 10: Step S1009)
The inspection execution unit 140 ends the operation flow when the inspection started in step S1003 is completed, and returns to step S1004 to repeat the same processing when the inspection is in progress.
(FIG. 10: Step S1010)
The inspection execution unit 140 interrupts the inspection started in step S1003 and executes an elapsed time excess error process. For example, the line number of the source code being executed when the inspection is interrupted is stored in the inspection result storage unit 175.

(図10:ステップS1011)
本動作フローが終了した後、ソフトウェア検査支援装置100は、図9で説明した動作フローを実行する。ステップS1007またはS1010においてそれぞれの超過処理を実行した旨の検査結果が記録されている場合は、検査を中断した以降のソースコード部分については無条件に残すこととする。条件式が成立するか否かを検証できていないからである。
(FIG. 10: Step S1011)
After this operation flow is completed, the software inspection support apparatus 100 executes the operation flow described with reference to FIG. If the inspection result indicating that each excess processing has been executed is recorded in step S1007 or S1010, the source code portion after the inspection is interrupted is left unconditionally. This is because it has not been verified whether the conditional expression is satisfied.

<実施の形態2:まとめ>
以上のように、本実施形態2に係るソフトウェア検査支援装置100は、検査実行部140がソースコードをコンパイルして実行するために必要なハードウェアリソース量が所定の制約条件を超過したときは、検査を中断してその旨を記録する。これにより、ハードウェア能力不足のため検査がいつまでも終了しないような事態を避けることができる。
<Embodiment 2: Summary>
As described above, in the software inspection support apparatus 100 according to the second embodiment, when the amount of hardware resources necessary for the inspection execution unit 140 to compile and execute the source code exceeds a predetermined constraint condition, Suspend the inspection and record to that effect. As a result, it is possible to avoid a situation where the inspection does not end indefinitely due to insufficient hardware capability.

また、本実施形態2に係るソフトウェア検査支援装置100は、検査実行部140が検査を途中で中断したときは、それ以降のソースコードを無条件に残す。これにより、冗長であることが確実に判明している条件分岐命令等のみをソースコードから削除することができる。   Also, the software inspection support apparatus 100 according to the second embodiment leaves the subsequent source code unconditionally when the inspection execution unit 140 interrupts the inspection halfway. As a result, only conditional branch instructions and the like that have been reliably determined to be redundant can be deleted from the source code.

以上、本発明者によってなされた発明を実施形態に基づき具体的に説明したが、本発明は前記実施の形態に限定されるものではなく、その要旨を逸脱しない範囲で種々変更可能であることは言うまでもない。   As mentioned above, the invention made by the present inventor has been specifically described based on the embodiment. However, the present invention is not limited to the embodiment, and various modifications can be made without departing from the scope of the invention. Needless to say.

また、上記各構成、機能、処理部などは、それらの全部または一部を、例えば集積回路で設計することによりハードウェアとして実現することもできるし、プロセッサがそれぞれの機能を実現するプログラムを実行することによりソフトウェアとして実現することもできる。各機能を実現するプログラム、テーブルなどの情報は、メモリやハードディスクなどの記憶装置、ICカード、DVDなどの記憶媒体に格納することができる。   In addition, each of the above-described configurations, functions, processing units, etc. can be realized as hardware by designing all or a part thereof, for example, with an integrated circuit, or the processor executes a program for realizing each function. By doing so, it can also be realized as software. Information such as programs and tables for realizing each function can be stored in a storage device such as a memory or a hard disk, or a storage medium such as an IC card or a DVD.

100:ソフトウェア検証支援装置、110:制御部、120:検査命令生成部、130:検査命令挿入部、140:検査実行部、150:検査結果取得部、160:条件分岐削除部、170:記憶部、171:ソースコード記憶部、172:条件式パターン記憶部、173:検査命令記憶部、174:検査対象ソースコード記憶部、175:検査結果記憶部、176:資源制約条件記憶部、200:コントロールユニット、210:マイクロコントローラ、211:入力回路、212:演算装置、213:RAM、214:ROM、215:出力回路、216:通信制御装置、220:駆動回路、230:通信回路、240:信号入出力回路、311:加速度センサ、312:ヨーレートセンサ、320:アクチュエータ、330:診断端末、340:制御装置、350:通信線。   DESCRIPTION OF SYMBOLS 100: Software verification assistance apparatus, 110: Control part, 120: Inspection instruction generation part, 130: Inspection instruction insertion part, 140: Inspection execution part, 150: Inspection result acquisition part, 160: Condition branch deletion part, 170: Storage part 171: Source code storage unit 172: Conditional expression pattern storage unit 173: Inspection instruction storage unit 174: Inspection target source code storage unit 175: Inspection result storage unit 176: Resource constraint condition storage unit 200: Control Unit: 210: Microcontroller, 211: Input circuit, 212: Arithmetic unit, 213: RAM, 214: ROM, 215: Output circuit, 216: Communication control device, 220: Drive circuit, 230: Communication circuit, 240: Signal input Output circuit, 311: acceleration sensor, 312: yaw rate sensor, 320: actuator, 330: diagnostic end , 340: controller, 350: communication line.

Claims (10)

ソフトウェアのソースコードを検証する作業を支援する装置であって、
前記ソースコードをコンパイルして実行した結果を取得する検査部、
前記ソースコード内の条件分岐命令が記述している条件が必ず成立するか否かを前記結果にしたがって判定する検査結果取得部、
前記条件が必ず成立する場合は、前記条件が成立したときに実行される命令を前記ソースコード内に残した上で、前記条件が成立しなかったときに実行される命令を前記ソースコードから削除する条件分岐削除部、
を備えることを特徴とするソフトウェア検証支援装置。
A device that supports the work of verifying the source code of software,
An inspection unit for acquiring a result obtained by compiling and executing the source code;
A test result acquisition unit that determines whether or not a condition described by a conditional branch instruction in the source code is satisfied, according to the result;
If the condition is always satisfied, the instruction executed when the condition is satisfied is left in the source code, and the instruction executed when the condition is not satisfied is deleted from the source code. Conditional branch deletion section
A software verification support apparatus comprising:
前記検査部は、
前記条件分岐命令が記述している条件を指定するパラメータのうち、前記ソフトウェアが搭載される環境に固有のものを記述したパラメータデータを、前記ソースコードに組み込んだ上でコンパイルして実行した結果を取得し、
前記検査結果取得部は、
前記パラメータデータを組み込んだ前記ソースコードの実行結果を取得することにより、前記環境において前記条件が必ず成立するか否かを判定する
ことを特徴とする請求項1記載のソフトウェア検証支援装置。
The inspection unit
Of the parameters that specify the conditions described by the conditional branch instruction, the parameter data describing the parameters specific to the environment in which the software is installed is incorporated into the source code, and the result of compiling and executing is obtained. Acquired,
The inspection result acquisition unit
The software verification support apparatus according to claim 1, wherein it is determined whether or not the condition is always satisfied in the environment by acquiring an execution result of the source code in which the parameter data is incorporated.
前記条件分岐命令が必ず成立するか否かを検査するための検査命令を前記ソースコード内の前記条件分岐命令の直前または直後に挿入する検査命令挿入部と、
前記ソースコードをコンパイルして実行した結果を記述したログを記憶する記憶部と、
を備え、
前記検査命令は、
前記検査部が前記検査命令を実行したとき、前記条件分岐命令が成立したか否かを示すログを前記記憶部に格納するように構成されており、
前記検査命令挿入部は、
前記検査部が前記ソースコードをコンパイルして実行前に、前記検査命令を前記ソースコード内に挿入し、
前記検査結果取得部は、
前記記憶部に格納されている前記検査命令のログに基づき、前記条件が必ず成立するか否かを判定する
ことを特徴とする請求項1記載のソフトウェア検証支援装置。
A check instruction insertion unit for inserting a check instruction for checking whether or not the conditional branch instruction is always satisfied, immediately before or after the conditional branch instruction in the source code;
A storage unit for storing a log describing a result of compiling and executing the source code;
With
The inspection instruction is:
When the inspection unit executes the inspection instruction, the storage unit is configured to store a log indicating whether or not the conditional branch instruction is satisfied,
The inspection instruction insertion unit is
Before the inspection unit compiles and executes the source code, the inspection instruction is inserted into the source code,
The inspection result acquisition unit
The software verification support apparatus according to claim 1, wherein it is determined whether or not the condition is always satisfied based on a log of the inspection instruction stored in the storage unit.
前記検査命令挿入部は、
前記検査命令を挿入すべき条件分岐命令が記述されている箇所を示す前記ソースコード内のコメント文にしたがって、前記検査命令を挿入する
ことを特徴とする請求項3記載のソフトウェア検証支援装置。
The inspection instruction insertion unit is
4. The software verification support apparatus according to claim 3, wherein the check instruction is inserted according to a comment sentence in the source code indicating a location where a conditional branch instruction to which the check instruction is to be inserted is described.
前記検査部は、
前記ソースコードをコンパイルして実行するために必要なハードウェアリソース量が所定の上限値を超えたときは前記実行を中断し、
前記検査結果取得部は、
前記条件分岐命令のうち前記中断時点で既に実行されたもの以外については、前記条件が必ず成立するか否か不確定であるものと判定し、
前記条件分岐削除部は、
前記条件が必ず成立するか否か不確定である前記条件分岐命令、その条件が成立したときに実行される命令、およびその条件が成立しなかったときに実行される命令については、前記ソースコードから削除せずに残したままにする
ことを特徴とする請求項1記載のソフトウェア検証支援装置。
The inspection unit
When the amount of hardware resources necessary for compiling and executing the source code exceeds a predetermined upper limit, the execution is interrupted,
The inspection result acquisition unit
The conditional branch instructions other than those already executed at the time of interruption are determined to be uncertain whether or not the condition is always satisfied,
The conditional branch deletion unit
For the conditional branch instruction that is uncertain whether or not the condition is satisfied, the instruction that is executed when the condition is satisfied, and the instruction that is executed when the condition is not satisfied, the source code The software verification support apparatus according to claim 1, wherein the software verification support apparatus is left without being deleted.
前記検査部は、
前記ソースコードをコンパイルして実行する際に消費するメモリ容量が所定の上限値を超えたときは前記実行を中断する
ことを特徴とする請求項5記載のソフトウェア検証支援装置。
The inspection unit
The software verification support apparatus according to claim 5, wherein the execution is interrupted when a memory capacity consumed when the source code is compiled and executed exceeds a predetermined upper limit value.
前記検査部は、
前記ソースコードをコンパイルして実行することを開始してからの経過時間が所定の上限値を超えたときは前記実行を中断する
ことを特徴とする請求項5記載のソフトウェア検証支援装置。
The inspection unit
The software verification support apparatus according to claim 5, wherein the execution is interrupted when an elapsed time from the start of compiling and executing the source code exceeds a predetermined upper limit value.
前記検査部は、
前記実行を中断したときはその時点で実行しようとしていた前記ソースコードの行番号を前記記憶部に格納する
ことを特徴とする請求項5記載のソフトウェア検証支援装置。
The inspection unit
6. The software verification support apparatus according to claim 5, wherein when the execution is interrupted, a line number of the source code which is about to be executed at that time is stored in the storage unit.
ソフトウェアのソースコードを検証する作業を支援する方法であって、
前記ソースコードをコンパイルして実行した結果を取得するステップ、
前記ソースコード内の条件分岐命令が記述している条件が必ず成立するか否かを前記結果にしたがって判定するステップ、
前記条件が必ず成立する場合は、前記条件が成立したときに実行される命令を前記ソースコード内に残した上で、前記条件が成立しなかったときに実行される命令を前記ソースコードから削除するステップ、
を有することを特徴とするソフトウェア検証支援方法。
A method for supporting the work of verifying the source code of software,
Obtaining a result of compiling and executing the source code;
Determining according to the result whether or not a condition described by a conditional branch instruction in the source code is necessarily satisfied,
If the condition is always satisfied, the instruction executed when the condition is satisfied is left in the source code, and the instruction executed when the condition is not satisfied is deleted from the source code. Step to do,
A software verification support method characterized by comprising:
請求項9記載のソフトウェア検証支援方法をコンピュータに実行させることを特徴とするソフトウェア検証支援プログラム。   A software verification support program that causes a computer to execute the software verification support method according to claim 9.
JP2012010333A 2012-01-20 2012-01-20 Software verification support apparatus, software verification support method, software verification support program Expired - Fee Related JP5865091B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2012010333A JP5865091B2 (en) 2012-01-20 2012-01-20 Software verification support apparatus, software verification support method, software verification support program
PCT/JP2013/050503 WO2013108730A1 (en) 2012-01-20 2013-01-15 Software verification support device, software verification support method, software verification support program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012010333A JP5865091B2 (en) 2012-01-20 2012-01-20 Software verification support apparatus, software verification support method, software verification support program

Publications (2)

Publication Number Publication Date
JP2013149164A true JP2013149164A (en) 2013-08-01
JP5865091B2 JP5865091B2 (en) 2016-02-17

Family

ID=48799155

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012010333A Expired - Fee Related JP5865091B2 (en) 2012-01-20 2012-01-20 Software verification support apparatus, software verification support method, software verification support program

Country Status (2)

Country Link
JP (1) JP5865091B2 (en)
WO (1) WO2013108730A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016099726A (en) * 2014-11-19 2016-05-30 株式会社エヌ・ティ・ティ・データ Specification generation method, specification generation device, and program
WO2022196219A1 (en) * 2021-03-18 2022-09-22 株式会社日立製作所 Program analysis device, program analysis method, and tracing process addition device

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3547141B1 (en) * 2016-11-22 2021-10-06 Mitsubishi Electric Corporation Information processing apparatus, information processing method, and information processing program

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0336632A (en) * 1989-06-26 1991-02-18 Internatl Business Mach Corp <Ibm> Optimizing method at time of compile
JPH0744397A (en) * 1993-07-30 1995-02-14 Nec Corp Program processing accelerating system
JP2011100420A (en) * 2009-11-09 2011-05-19 Toshiba Corp Test program creation device

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05181685A (en) * 1992-01-07 1993-07-23 Oki Electric Ind Co Ltd Compile executing method
WO2004021176A2 (en) * 2002-08-07 2004-03-11 Pact Xpp Technologies Ag Method and device for processing data
JP2006164294A (en) * 2005-12-26 2006-06-22 Fujitsu Ltd Virtual computer having jit compiler
JP4737624B2 (en) * 2006-03-06 2011-08-03 株式会社日立ソリューションズ Specific work support system for application failure causes
JP2008015665A (en) * 2006-07-04 2008-01-24 Hitachi Ltd Program analysis method and program analyzer
JP5458829B2 (en) * 2009-11-26 2014-04-02 富士通株式会社 Inspection device, server device, and inspection program

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0336632A (en) * 1989-06-26 1991-02-18 Internatl Business Mach Corp <Ibm> Optimizing method at time of compile
JPH0744397A (en) * 1993-07-30 1995-02-14 Nec Corp Program processing accelerating system
JP2011100420A (en) * 2009-11-09 2011-05-19 Toshiba Corp Test program creation device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2016099726A (en) * 2014-11-19 2016-05-30 株式会社エヌ・ティ・ティ・データ Specification generation method, specification generation device, and program
WO2022196219A1 (en) * 2021-03-18 2022-09-22 株式会社日立製作所 Program analysis device, program analysis method, and tracing process addition device
JP7447044B2 (en) 2021-03-18 2024-03-11 株式会社日立製作所 Program analysis device, program analysis method and trace processing addition device

Also Published As

Publication number Publication date
WO2013108730A1 (en) 2013-07-25
JP5865091B2 (en) 2016-02-17

Similar Documents

Publication Publication Date Title
US20160092181A1 (en) Automatic source code generation for accelerated function calls
JP5865091B2 (en) Software verification support apparatus, software verification support method, software verification support program
US9129137B2 (en) Method, computer program and device for providing security for intermediate programming code for its execution by a virtual machine
US8589734B2 (en) Verifying correctness of processor transactions
US8700380B2 (en) Method for generating performance evaluation model
JP5233355B2 (en) Property generation system and property verification system
JP4915362B2 (en) Annotation automatic insertion method of static verification tool
JP2016031622A (en) Software verification system and control device
JP2010108258A (en) Compiling method and compiling program
JP4762204B2 (en) Program development support device
US20110022373A1 (en) Model checking of liveness property in a phase abstracted model
US9632912B1 (en) Method and system for debugging a program
WO2016103229A1 (en) A method for verifying a safety logic in an industrial process
JP5755861B2 (en) Test case generation apparatus, test case generation method, and test case generation program
JP5093508B2 (en) Loop optimization system, loop optimization method, and loop optimization program
JP2010079516A (en) Simulation method and program
JP2008090699A (en) Method, apparatus and program of trace logging
JP2005174045A (en) Source program conversion device, source program conversion method, source program conversion program and program recording medium
US10534691B2 (en) Apparatus and method to improve accuracy of performance measurement for loop processing in a program code
JP6724673B2 (en) Test support program, test support method, and test support device
CN114153750B (en) Code checking method and device, code compiling method and electronic equipment
CN117236277B (en) Method and device for checking register and electronic equipment
JP5233354B2 (en) Property verification system, property verification method, and program
JP2009217720A (en) Program generating device and program generating method
JP6668808B2 (en) Untested portion detection device, untested portion detection method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140825

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20150507

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20150706

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20151208

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20151225

R150 Certificate of patent or registration of utility model

Ref document number: 5865091

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees