JP6954806B2 - Defect detection device and defect detection method - Google Patents

Defect detection device and defect detection method Download PDF

Info

Publication number
JP6954806B2
JP6954806B2 JP2017213735A JP2017213735A JP6954806B2 JP 6954806 B2 JP6954806 B2 JP 6954806B2 JP 2017213735 A JP2017213735 A JP 2017213735A JP 2017213735 A JP2017213735 A JP 2017213735A JP 6954806 B2 JP6954806 B2 JP 6954806B2
Authority
JP
Japan
Prior art keywords
defect
rule
defect detection
detection device
pattern
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.)
Active
Application number
JP2017213735A
Other languages
Japanese (ja)
Other versions
JP2019086953A (en
Inventor
和矢 安田
和矢 安田
伊藤 信治
信治 伊藤
文江 中屋
文江 中屋
佳範 城代
佳範 城代
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 Social Information Services Ltd
Original Assignee
Hitachi Social Information Services 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 Social Information Services Ltd filed Critical Hitachi Social Information Services Ltd
Priority to JP2017213735A priority Critical patent/JP6954806B2/en
Publication of JP2019086953A publication Critical patent/JP2019086953A/en
Application granted granted Critical
Publication of JP6954806B2 publication Critical patent/JP6954806B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Debugging And Monitoring (AREA)
  • Stored Programmes (AREA)

Description

本発明は、不具合検出装置、及び不具合検出方法に関する。 The present invention relates to a defect detection device and a defect detection method.

特許文献1には「データを共有する複数のプログラムに潜在する類似のバグを検出するために、第一に、プログラムと潜在するバグの関係を明確にすること、第二に、プログラムと潜在するバグとデータ項目の関係を明確にする。」、「データを共有する複数のプログラムに潜在するバグを検出するバグ検出システムにおいて、各プログラムとそれらの参照するデータの関係を記憶する記憶手段と、バグの種類とそのバグの発生したデータとの関係を入力する入力手段と、当該入力内容と記憶手段の内容に基づき、プログラムとバグの関係を出力する出力手段とから構成する。」と記載されている。 Patent Document 1 states, "In order to detect similar bugs latent in a plurality of programs sharing data, firstly, the relationship between the program and the latent bug is clarified, and secondly, the program and the latent bug are latent. Clarify the relationship between bugs and data items. "," In a bug detection system that detects potential bugs in multiple programs that share data, a storage means that stores the relationship between each program and the data referenced by them, and It consists of an input means for inputting the relationship between the type of bug and the data in which the bug occurred, and an output means for outputting the relationship between the program and the bug based on the contents of the input content and the storage means. " ing.

特開平11−85563号公報Japanese Unexamined Patent Publication No. 11-85563

ソフトウェアは一般に複数の機能を実現するプログラムや関数によって構成されており、これらの機能がデータベースやファイル等への入出力を介してデータを受け渡しながら動作する。各機能を実現するソースコードの作成に際しては、ソースコードに含まれている不具合(バグ)を検出して修正するデバッグ(Debug)を行うことにより不具合を取り
除く。
Software is generally composed of programs and functions that realize multiple functions, and these functions operate while passing data via input / output to a database or file. When creating the source code that realizes each function, the defect is removed by performing debugging (Debug) that detects and corrects the defect (bug) contained in the source code.

ここで上記の特許文献1では、あるデータ(変数)を参照もしくは更新する機能に不具合が検出されたとき、同じデータを参照もしくは更新する機能を特定することで、同じ不具合を含む可能性の高い機能を特定している。 Here, in the above-mentioned Patent Document 1, when a defect is detected in the function of referencing or updating a certain data (variable), it is highly possible that the same defect is included by specifying the function of referencing or updating the same data. The function is specified.

しかし特許文献1では、データの具体的な値までは考慮していないため、例えば、同じ値を取る別のデータ(変数)を参照もしくは更新する機能については特定することができない。また不具合に関係する機能とデータ(変数)が特定されるだけでは、どのような条件の下で不具合が発生するかがわからないため修正箇所の特定に時間を要する。 However, in Patent Document 1, since the specific value of the data is not considered, for example, the function of referencing or updating another data (variable) having the same value cannot be specified. In addition, it takes time to identify the corrected part because it is not possible to know under what conditions the defect will occur only by identifying the functions and data (variables) related to the defect.

本発明は、こうした背景に鑑みてなされたものであり、ソフトウェアの不具合の検出を効率よく行うことを可能とする、不具合検出装置及び不具合検出方法を提供することを目的とする。 The present invention has been made in view of such a background, and an object of the present invention is to provide a defect detection device and a defect detection method capable of efficiently detecting software defects.

上記課題を解決するための本発明のうちの一つは、不具合検出装置であって、ソフトウェアの仕様を、入力変数についての条件を示す情報と出力変数の値を示す情報とを含む一つ以上のルールにより記述した情報である、ルール仕様と、検出しようとする不具合の特徴を、ルール仕様の構文上のパターンにより表した情報を含む、不具合パターンリストと、を記憶する情報記憶部と、前記ルール仕様と前記不具合パターンリストとを照合し、前記ルール仕様から前記パターンを満たす前記ルールを抽出した情報である不具合の発生条件リストを生成する不具合検出部と、を備える。 One of the present inventions for solving the above problems is a defect detection device, which includes one or more software specifications including information indicating conditions for input variables and information indicating values of output variables. is information describing the rules, and rule specification, a problem characteristic to be detected, including information representing a pattern of syntactic rule specification, an information storage unit for storing the defect pattern list, and the It is provided with a defect detection unit that collates the rule specification with the defect pattern list and generates a defect occurrence condition list that is information obtained by extracting the rule satisfying the pattern from the rule specification.

その他、本願が開示する課題、及びその解決方法は、発明を実施するための形態の欄、
及び図面により明らかにされる。
In addition, the problems disclosed in the present application and the solutions thereof are described in the column of forms for carrying out the invention.
And the drawings reveal.

本発明によれば、ソフトウェアの不具合の検出を効率よく行うことができる。 According to the present invention, it is possible to efficiently detect software defects.

不具合検出装置のハードウェア構成例を示す図である。It is a figure which shows the hardware configuration example of the defect detection apparatus. 不具合検出装置が備える機能及び不具合検出装置が記憶する情報を示す図である。It is a figure which shows the function which the defect detection apparatus has, and the information which the defect detection apparatus stores. IF−THEN形式で記述されたルール仕様の例を示す図である。It is a figure which shows the example of the rule specification described in the IF-THEN format. 不具合パターンリストの例を示す図である。It is a figure which shows the example of the defect pattern list. IF−THEN形式で記述された不具合検出結果の例を示す図である。It is a figure which shows the example of the defect detection result described in the IF-THEN format. 不具合検出の処理を説明するフローチャートである。It is a flowchart explaining the process of defect detection. 決定表形式で記述されたルール仕様の例を示す図である。It is a figure which shows the example of the rule specification described in the decision table format. 決定表形式で記述された不具合検出結果の例を示す図である。It is a figure which shows the example of the defect detection result described in the decision table format.

以下、図面を参照しつつ実施形態について説明する。以下の説明において、同一の又は類似する構成について同一の符号を付して重複した説明を省略することがある。 Hereinafter, embodiments will be described with reference to the drawings. In the following description, the same or similar configurations may be designated by the same reference numerals and duplicate description may be omitted.

[第1実施形態]
図1に第1実施形態として示す不具合検出装置100のハードウェア構成を、図2に不具合検出装置100が備える機能及び不具合検出装置100が記憶するデータを、夫々示している。
[First Embodiment]
FIG. 1 shows the hardware configuration of the defect detection device 100 shown as the first embodiment, and FIG. 2 shows the functions included in the defect detection device 100 and the data stored in the defect detection device 100, respectively.

不具合検出装置100は、ソフトウェア(例えば、金融、保険、製造、流通、通信、教育、医療等の業務に関するもの)の開発や保守に際して利用される情報処理装置(コンピュータ)である。不具合検出装置10は、例えば、クラウドシステムにより提供されるクラウドサーバのように仮想的な情報処理資源を用いて実現されるものであってもよい。 The defect detection device 100 is an information processing device (computer) used for developing and maintaining software (for example, those related to business such as finance, insurance, manufacturing, distribution, communication, education, medical treatment, etc.). The defect detection device 10 may be realized by using virtual information processing resources such as a cloud server provided by a cloud system.

ソフトウェアは、商品やサービス等に関する法的な規制、業務上の規則、基準等。ビジネスルール、システムルール、チェックルール等(以下、これらをルールと総称する。)に従ってその仕様が決定され設計がなされる。上記ルールは、例えば「もし〜ならば〜である」といった自然文による記述や「IF A=1 AND B=2 THEN R=1」というようにコンピュータにより解釈可能な所定の規則に従った記述、条件と結果の対応関係を表形式で定義した決定表による記述などの様々な形で表現される。以下、ソフトウェアの仕様をルールの集まりとして記述したものをルール仕様と称する。ルール仕様は、例えば、記号実行などのソースコード解析技術により、ソースコードから自動的に生成することができる。 Software is legal regulations, business rules, standards, etc. regarding products and services. The specifications are determined and designed according to business rules, system rules, check rules, etc. (hereinafter, these are collectively referred to as rules). The above rule is, for example, a description in a natural sentence such as "If ... If ..." or a description according to a predetermined rule that can be interpreted by a computer such as "IF A = 1 AND B = 2 THEN R = 1". It is expressed in various forms such as a description in a decision table that defines the correspondence between conditions and results in a tabular format. Hereinafter, a software specification described as a set of rules is referred to as a rule specification. Rule specifications can be automatically generated from source code by, for example, source code analysis techniques such as symbol execution.

不具合検出装置100は、ルール仕様に含まれている不具合を検出する。不具合検出装置100は、ルール仕様と、検出しようとする不具合の特徴をルール仕様の構文(syntax)上及び意味(semantics)上のパターンにより表した情報を含む不具合パターンリスト
(後述する不具合パターンリスト260)とを記憶し、ルール仕様のルールと不具合パターンリストとを照合し、ルール仕様から不具合パターンリストのパターン(条件)を満たすルールを抽出した情報(発生条件リスト)を含む不具合検出結果(後述する不具合検出結果270)を生成する。
The defect detection device 100 detects defects included in the rule specifications. The defect detection device 100 includes a defect pattern list (defect pattern list 260 described later) including information representing the rule specifications and the characteristics of the defect to be detected by the syntax (syntax) and semantics (semantics) patterns of the rule specifications. ), The rule of the rule specification is collated with the defect pattern list, and the defect detection result (described later) including the information (occurrence condition list) that extracts the rule satisfying the pattern (condition) of the defect pattern list from the rule specification. The defect detection result 270) is generated.

不具合検出装置100が生成する不具合検出結果には、不具合の有無を表す不具合サマリ(後述する不具合サマリ510)と、検出された不具合の一覧(後述する、検出された
不具合の発生条件リスト520)とが含まれる。
The defect detection results generated by the defect detection device 100 include a defect summary (described later, defect summary 510) indicating the presence or absence of a defect, and a list of detected defects (described later, a list of conditions for occurrence of detected defects 520). Is included.

図1に示すように、不具合検出装置100は、プロセッサ110、主記憶装置120、補助記憶装置130、入力装置140、出力装置150、及び通信装置160を備える。これらは図示しないバス等の通信手段を介して互いに通信可能に接続されている。 As shown in FIG. 1, the defect detection device 100 includes a processor 110, a main storage device 120, an auxiliary storage device 130, an input device 140, an output device 150, and a communication device 160. These are communicably connected to each other via a communication means such as a bus (not shown).

プロセッサ110は、例えば、CPU(Central Processing Unit)やMPU(Micro Processing Unit)を用いて構成されている。プロセッサ110が、主記憶装置120に格納されているプログラムを読み出して実行することにより、不具合検出装置100の様々な機能が実現される。 The processor 110 is configured by using, for example, a CPU (Central Processing Unit) or an MPU (Micro Processing Unit). When the processor 110 reads and executes the program stored in the main storage device 120, various functions of the defect detection device 100 are realized.

主記憶装置120は、プログラムやデータを記憶する装置であり、例えば、ROM(Read Only Memory)、RAM(Random Access Memory)、不揮発性半導体メモリ(NVRAM(Non Volatile RAM))等である。 The main storage device 120 is a device that stores programs and data, and is, for example, a ROM (Read Only Memory), a RAM (Random Access Memory), a non-volatile semiconductor memory (NVRAM (Non Volatile RAM)), and the like.

補助記憶装置130は、例えば、ハードディスクドライブ、SSD(Solid State Drive)、光学式記憶装置(CD(Compact Disc)、DVD(Digital Versatile Disc)等)、
ストレージシステム、ICカード、SDメモリカードや光学式記録媒体等の記録媒体の読取/書込装置、クラウドサーバの記憶領域等である。補助記憶装置130に格納されているプログラムやデータは主記憶装置120に随時読み込まれる。
The auxiliary storage device 130 includes, for example, a hard disk drive, an SSD (Solid State Drive), an optical storage device (CD (Compact Disc), DVD (Digital Versatile Disc), etc.),
A storage system, an IC card, a reading / writing device for a recording medium such as an SD memory card or an optical recording medium, a storage area of a cloud server, and the like. Programs and data stored in the auxiliary storage device 130 are read into the main storage device 120 at any time.

入力装置140は、例えば、キーボード、マウス、タッチパネル、カードリーダ、音声入力装置等である。出力装置150は、ユーザに処理経過や処理結果等の各種情報を提供するユーザインタフェースであり、例えば、画面表示装置(液晶モニタ、LCD(Liquid
Crystal Display)、グラフィックカード等)、音声出力装置(スピーカ等)、印字装置等である。尚、例えば、不具合検出装置100が通信装置160を介して他の装置との間で情報の入力や出力を行う構成としてもよい。
The input device 140 is, for example, a keyboard, a mouse, a touch panel, a card reader, a voice input device, or the like. The output device 150 is a user interface that provides the user with various information such as processing progress and processing results. For example, a screen display device (liquid crystal monitor, LCD (Liquid)).
Crystal Display), graphic cards, etc.), audio output devices (speakers, etc.), printing devices, etc. In addition, for example, the defect detection device 100 may be configured to input or output information from another device via the communication device 160.

通信装置160は、LANやインターネット等の通信手段を介した他の装置との間の通信を実現する有線方式又は無線方式の通信インタフェースであり、例えば、NIC(Network Interface Card)、無線通信モジュール、USB(Universal Serial Interface)モジュール、シリアル通信モジュール等である。 The communication device 160 is a wired or wireless communication interface that realizes communication with other devices via a communication means such as LAN or the Internet. For example, a NIC (Network Interface Card), a wireless communication module, or the like. USB (Universal Serial Interface) module, serial communication module, etc.

図2に示すように、不具合検出装置100は、ルール仕様生成部210、不具合検出部220、情報記憶部230の各機能を備える。また不具合検出装置100は、ソースコード240、ルール仕様250、不具合パターンリスト260、不具合検出結果270を、補助記憶装置130に記憶する。 As shown in FIG. 2, the defect detection device 100 includes the functions of the rule specification generation unit 210, the defect detection unit 220, and the information storage unit 230. Further, the defect detection device 100 stores the source code 240, the rule specification 250, the defect pattern list 260, and the defect detection result 270 in the auxiliary storage device 130.

ルール仕様生成部210は、記号実行等のソースコード解析技術により、ソースコード240からルール仕様250を生成する。 The rule specification generation unit 210 generates the rule specification 250 from the source code 240 by a source code analysis technique such as symbol execution.

不具合検出部220は、事前に定義された不具合パターンリスト260に基づきルール仕様250の不具合を検出する。 The defect detection unit 220 detects a defect of the rule specification 250 based on a predetermined defect pattern list 260.

情報記憶部230は、不具合検出部220がルール仕様250の不具合を検出した結果を不具合検出結果270として補助記憶装置130に記憶する。不具合検出部220が行う処理の詳細については後述する。 The information storage unit 230 stores the result of the defect detection unit 220 detecting the defect of the rule specification 250 as the defect detection result 270 in the auxiliary storage device 130. Details of the processing performed by the defect detection unit 220 will be described later.

図3は、ルール仕様生成部210により生成され情報記憶部230が記憶するルール仕様250の一例である。ルール仕様250は、識別子(以下、機能IDと称する)で識別
される機能ごとにまとめられた1つ以上のルール群から構成される。尚、以下の説明において、各機能を、機能1、機能2、・・・のように表記する。各ルール群は、1つ以上のIF−THEN形式で記述されたルールを含む。各ルールは識別子(以下、ルールIDと称する。)で識別される。以下、上記ルール群のことをルールセットとも称する。
FIG. 3 is an example of the rule specification 250 generated by the rule specification generation unit 210 and stored by the information storage unit 230. The rule specification 250 is composed of one or more rule groups grouped by a function identified by an identifier (hereinafter referred to as a function ID). In the following description, each function is described as function 1, function 2, .... Each rule group contains one or more rules described in IF-THEN format. Each rule is identified by an identifier (hereinafter referred to as a rule ID). Hereinafter, the above rule group is also referred to as a rule set.

同図に示すルール仕様250は、機能1のルールセット310、機能2のルールセット320、及び機能3のルールセット330の3つのルールセットを含む。このうちルールセット310は、ルールIDが1〜4の4つのルールを含む。またルールセット320は、ルールID1〜3の3つのルールを含む。またルールセット330は、ルールIDが1〜2の2つのルールを含む。尚、以下の説明において、各ルールを、ルール1、ルール2、・・・のように表記する。 The rule specification 250 shown in the figure includes three rule sets: a rule set 310 for function 1, a rule set 320 for function 2, and a rule set 330 for function 3. Of these, the rule set 310 includes four rules having rule IDs 1 to 4. Further, the rule set 320 includes three rules of rule IDs 1 to 3. Further, the rule set 330 includes two rules having rule IDs 1 and 2. In the following description, each rule is described as rule 1, rule 2, ....

各ルールは、条件部と結果部とを含む。IF−THEN形式の記述においては、条件部と結果部は夫々、IF節とTHEN節に相当する。例えば、図3に例示するルールセット310のルール1の場合、条件部は「p=1 and q>r」であり、結果部は「x=1」である。 Each rule includes a condition part and a result part. In the IF-THEN format description, the condition part and the result part correspond to the IF clause and the THEN clause, respectively. For example, in the case of rule 1 of the rule set 310 illustrated in FIG. 3, the condition part is “p = 1 and q> r” and the result part is “x = 1”.

以下の説明において、各ルールセットに対し、そのルールセットに含まれるルールの条件部に記述されている変数を入力変数と称し、結果部に記述されている変数を出力変数と称する。例えば、図3に例示するルールセット310において、入力変数はp、q、rであり、出力変数はxである。 In the following description, for each rule set, the variable described in the condition part of the rule included in the rule set is referred to as an input variable, and the variable described in the result part is referred to as an output variable. For example, in the rule set 310 illustrated in FIG. 3, the input variables are p, q, r and the output variables are x.

各ルールセットにおいて、入力変数の具体的な値を定めると、各ルールの条件部が充足するか(条件部の論理式が真となるか)一意に定まる。ルールの条件部が充足すると、当該ルールの結果部が真となるように出力変数の値が定まる。例えば、図3に例示するルールセット310において、入力変数p、q、rの具体的な値が夫々、1、2、3であるときルール2の条件部が充足し、出力変数xの具体的な値が2に定まる。 When the specific value of the input variable is defined in each rule set, it is uniquely determined whether the condition part of each rule is satisfied (whether the logical expression of the condition part is true). When the condition part of the rule is satisfied, the value of the output variable is determined so that the result part of the rule is true. For example, in the rule set 310 illustrated in FIG. 3, when the specific values of the input variables p, q, and r are 1, 2, and 3, respectively, the condition part of the rule 2 is satisfied, and the specific output variable x is specified. Value is set to 2.

例えば、ルール仕様250において、2つの機能がデータベースやファイル等への入出力を介してデータを受け渡す場合には、一方のルールセットの出力変数が他方のルールセットの入力変数に含まれる。例えば、図3に例示するルール仕様250において、機能1のルールセット310の出力変数xは、機能2のルールセット320の入力変数に含まれる。これは、機能1が変数xの値をデータベースやファイルに書き出し、機能2が変数xの値を同じデータベースやファイルから読み込んで参照等することを意味する。以下では、同じ変数を読み書きする複数の機能において、当該変数をルールセットの出力変数にもつ機能を「出力側機能」、当該変数をルールセットの入力変数にもつ機能を「入力側機能」と称する。 For example, in the rule specification 250, when two functions pass data via input / output to a database, a file, or the like, the output variable of one rule set is included in the input variable of the other rule set. For example, in the rule specification 250 illustrated in FIG. 3, the output variable x of the rule set 310 of the function 1 is included in the input variable of the rule set 320 of the function 2. This means that function 1 writes the value of the variable x to a database or file, and function 2 reads the value of the variable x from the same database or file and refers to it. In the following, among multiple functions that read and write the same variable, the function that has the variable as the output variable of the rule set is referred to as the "output side function", and the function that has the variable as the input variable of the rule set is referred to as the "input side function". ..

尚、2つの機能について、一方のルールセットの出力変数と他方のルールセットの入力変数が異なる場合に、入力変数と出力変数の対応関係の情報を別に用意し、データベースやファイル等への入出力を介してデータが受け渡されていることを表してもよい。例えば、図3に例示するルール仕様250において、機能3のルールセット330の出力変数nと、機能2のルールセット320の入力変数zとが対応している(データベースやファイル上では同じ値を指している)という別の情報により、これら機能間にデータの受け渡しがあることを表現してもよい。 For the two functions, when the output variable of one rule set and the input variable of the other rule set are different, the information on the correspondence between the input variable and the output variable is prepared separately and input / output to the database, file, etc. It may indicate that the data is being passed via. For example, in the rule specification 250 illustrated in FIG. 3, the output variable n of the rule set 330 of the function 3 and the input variable z of the rule set 320 of the function 2 correspond to each other (pointing to the same value on the database or file). It may be expressed that there is data transfer between these functions by another information such as).

図4は、情報記憶部230が記憶する不具合パターンリスト260の一例である。不具合パターンリスト260には、不具合検出装置100が検出する不具合ごとの、その不具合の特長を記述した不具合パターンを示す情報を含む。尚、不具合パターンリスト260は、例えば、ユーザが作成する FIG. 4 is an example of the defect pattern list 260 stored in the information storage unit 230. The defect pattern list 260 includes information indicating a defect pattern that describes the features of each defect detected by the defect detection device 100. The defect pattern list 260 is created by the user, for example.

同図に示す不具合パターンリスト260は、不具合A(ゼロ除算)の不具合パターン410と、不具合B(関数fの引数不正)の不具合パターン420とを含む。各不具合パターンは、種別と条件式の各項目を有する1つ以上の判定条件から構成される。種別には、「構文」又は「意味」のいずれかが設定される。条件式には、不具合検出装置100がルール仕様250に不具合を含むと判断するパターンが設定される。種別に「構文」が設定されている場合、条件式にはルール仕様250の構文(syntax)上の(変数に設定される具体的な値は考慮しない)パターンが設定される。種別に「意味」が設定されている場合、条件式にはルール仕様250の意味(semantics)上の(変数に設定される具体的な値
を考慮する)パターンが設定される。
The defect pattern list 260 shown in the figure includes a defect pattern 410 of defect A (division by zero) and a defect pattern 420 of defect B (argument invalidity of function f). Each defect pattern is composed of one or more determination conditions having each item of type and conditional expression. Either "syntax" or "meaning" is set for the type. In the conditional expression, a pattern is set in which the defect detection device 100 determines that the rule specification 250 includes a defect. When "syntax" is set for the type, a pattern on the syntax of the rule specification 250 (without considering the specific value set in the variable) is set in the conditional expression. When "meaning" is set for the type, a pattern on the semantics of the rule specification 250 (considering the specific value set in the variable) is set in the conditional expression.

例えば、図4に例示する不具合Aの不具合パターン410は2つの判定条件を含む。1つ目の判定条件は構文上のパターンであり、条件式は「引数に出現(出力変数、/、2)」である。2つ目の判定条件は意味上のパターンであり、条件式は「出力変数=0」である。 For example, the defect pattern 410 of defect A illustrated in FIG. 4 includes two determination conditions. The first judgment condition is a syntactic pattern, and the conditional expression is "appears in an argument (output variable, / 2)". The second determination condition is a semantic pattern, and the conditional expression is "output variable = 0".

条件式に記載されている「出力変数」は、不具合判定中の出力変数が格納されるプレースホルダである。また条件式に記載されている「引数に出現(式、関数、N)」は、式が関数に渡される第N引数に構文上含まれることを表す関数で、Nには正整数が設定される。つまり、条件式「引数に出現(出力変数、/、2)」は、出力変数が、関数「/」(除算)の第2引数(除数)に構文上含まれることを表す。尚、本例ではプレースホルダ「出力変数」と関数「引数に出現」とを使用するが、これらを使用しないことも、またこれら以外のプレースホルダや関数を定義して使用することも可能である。 The "output variable" described in the conditional expression is a placeholder in which the output variable during the defect determination is stored. In addition, "appearing in argument (expression, function, N)" described in the conditional expression is a function indicating that the expression is syntactically included in the Nth argument passed to the function, and a positive integer is set in N. NS. That is, the conditional expression "appears in the argument (output variable, / 2)" indicates that the output variable is syntactically included in the second argument (divisor) of the function "/" (division). In this example, the placeholder "output variable" and the function "appear in the argument" are used, but it is possible not to use these or to define and use other placeholders and functions. ..

図5は、図3に例示したルール仕様250及び図4に例示した不具合パターンリスト260に基づき、不具合検出装置100が生成した不具合検出結果270の例である。不具合検出結果270は、不具合サマリ510、検出された不具合の発生条件リスト520を含む。図5に示す不具合サマリ510の各行は、夫々、ルール仕様250中のルールセットの出力変数ごとに、その変数に関する不具合が含まれるか否かを示している。ユーザは不具合サマリ510を参照することで、出力変数ごとの不具合の有無を容易に把握することができる。 FIG. 5 is an example of the defect detection result 270 generated by the defect detection device 100 based on the rule specification 250 illustrated in FIG. 3 and the defect pattern list 260 illustrated in FIG. The defect detection result 270 includes a defect summary 510 and a list of conditions for generating the detected defects 520. Each line of the defect summary 510 shown in FIG. 5 indicates whether or not each output variable of the rule set in the rule specification 250 includes a defect related to that variable. By referring to the defect summary 510, the user can easily grasp the presence or absence of a defect for each output variable.

不具合サマリ510は、出力変数と、不具合パターンリスト260中の各不具合の有無とを含む。出力変数には、ルール仕様250中のルールセットの出力変数から一つが設定される。不具合の有無は、不具合パターンリスト260に設定されている不具合ごとに設定される。図5に例示する不具合サマリ510は、出力変数xに関して、不具合パターンリスト260中の不具合Aと不具合Bが含まれることを示している。また出力変数mやnに関して、不具合パターンリスト260中の不具合Aや不具合Bが含まれていないことを示している。尚、本例では不具合があることを「●」、不具合がないことを「‐」で表しているが、これら以外の文字や記号により表現してもよい。 The defect summary 510 includes an output variable and the presence / absence of each defect in the defect pattern list 260. One of the output variables of the rule set in the rule specification 250 is set as the output variable. The presence or absence of a defect is set for each defect set in the defect pattern list 260. The defect summary 510 illustrated in FIG. 5 shows that the defect A and the defect B in the defect pattern list 260 are included in the output variable x. Further, regarding the output variables m and n, it is shown that the defect A and the defect B in the defect pattern list 260 are not included. In this example, "●" indicates that there is a defect and "-" indicates that there is no defect, but characters and symbols other than these may be used.

検出された不具合の発生条件リスト520は、不具合サマリ510で不具合を含むと示された出力変数と不具合ごとに、その不具合の発生条件を有する。図5に例示する、検出された不具合の発生条件リスト520は、出力変数xに関する不具合Aの発生条件530、及び出力変数xに関する不具合Bの発生条件540を含む。 The detected defect occurrence condition list 520 has an output variable indicated to include a defect in the defect summary 510 and a defect occurrence condition for each defect. The detected defect occurrence condition list 520 illustrated in FIG. 5 includes the occurrence condition 530 of the defect A related to the output variable x and the occurrence condition 540 of the defect B related to the output variable x.

各不具合の発生条件は、ルール仕様250に含まれるルールのうち、不具合パターンリスト260で定義された不具合パターンを満たすルールを含む。例えば、図3に例示する機能1のルールセット310のルール4の条件部が充足する時、出力変数xの具体的な値が0となり、かつ、機能2のルールセット320のルール1又はルール2では条件部の除
数に出力変数xが出現する。つまり、出力変数xに関して、図4に例示する不具合Aの不具合パターン410が満たされ、図5に示すように、出力変数xに関する不具合Aの発生条件530は、ルールセット310のルール4と、ルールセット320のルール1及びルール2とを含む。
Each defect occurrence condition includes a rule that satisfies the defect pattern defined in the defect pattern list 260 among the rules included in the rule specification 250. For example, when the condition part of the rule 4 of the rule set 310 of the function 1 illustrated in FIG. 3 is satisfied, the specific value of the output variable x becomes 0, and the rule 1 or the rule 2 of the rule set 320 of the function 2 becomes 0. Then, the output variable x appears in the divisor of the condition part. That is, with respect to the output variable x, the defect pattern 410 of the defect A illustrated in FIG. 4 is satisfied, and as shown in FIG. 5, the occurrence condition 530 of the defect A regarding the output variable x is the rule 4 of the rule set 310 and the rule. Includes Rule 1 and Rule 2 of Set 320.

図5に示す、出力変数xに関する不具合Aの発生条件530と、出力変数xに関する不具合Bの発生条件540は、いずれも複数の機能のルールを含むが、単一の機能のみに依存する不具合である場合、不具合の発生条件を当該機能のルールのみとすることも可能である。例えば、図5に例示する出力変数xに関する不具合Bの発生条件540には、図3に例示するルール仕様250における、機能3のルールセット330のルールが全て含まれる。これは、不具合Bの発生条件は機能3に依存せず、機能1のみに依存することを意味しており、不具合Bの発生条件540は、機能1のルールセット310のルール4のみとしてもよい。 The occurrence condition 530 of the defect A related to the output variable x and the occurrence condition 540 of the defect B related to the output variable x shown in FIG. 5 both include rules for a plurality of functions, but are defects that depend on only a single function. In some cases, it is possible to set the condition for occurrence of the defect to be only the rule of the function. For example, the occurrence condition 540 of the defect B relating to the output variable x illustrated in FIG. 5 includes all the rules of the rule set 330 of the function 3 in the rule specification 250 illustrated in FIG. This means that the occurrence condition of the defect B does not depend on the function 3 but depends only on the function 1, and the occurrence condition 540 of the defect B may be only the rule 4 of the rule set 310 of the function 1. ..

検出された不具合の発生条件リスト520には、不具合の発生条件のほかに、その不具合の発生条件を満たす入力変数・出力変数の具体的な値の例を出力してもよい。例えば、図5に示す出力変数xに関する不具合Bの発生条件540について、この不具合の発生条件を満たす入力変数と出力変数の具体的な値の例として「p=2、q=0、r=0、x=0、n=1」を出力してもよい。 In the detected defect occurrence condition list 520, in addition to the defect occurrence condition, an example of specific values of the input variable / output variable that satisfies the defect occurrence condition may be output. For example, regarding the occurrence condition 540 of the defect B related to the output variable x shown in FIG. 5, "p = 2, q = 0, r = 0" as an example of specific values of the input variable and the output variable satisfying the occurrence condition of the defect. , X = 0, n = 1 ”may be output.

図6は、不具合の検出に際して不具合検出装置100が行う処理(以下、不具合検出処理S600と称する。)を説明するフローチャートである。以下、同図とともに不具合検出処理S600について説明する。尚、不具合検出部220は、例えば、ユーザからの指示を契機として不具合検出処理S600を開始する。また不具合検出部220は、例えば、スケジュールされたタイミングでバッチ処理等により自動的に不具合検出処理S600を実行する。尚、以下において、符号の前に付している文字「S」は処理ステップを意味する。 FIG. 6 is a flowchart illustrating a process (hereinafter, referred to as a defect detection process S600) performed by the defect detection device 100 when detecting a defect. Hereinafter, the defect detection process S600 will be described with reference to the figure. The defect detection unit 220 starts the defect detection process S600, for example, triggered by an instruction from the user. Further, the defect detection unit 220 automatically executes the defect detection process S600 by batch processing or the like at a scheduled timing, for example. In the following, the letter "S" attached before the code means a processing step.

まず不具合検出装置100は、情報記憶部230が記憶しているルール仕様250を読み込むとともに(S601)、情報記憶部230が記憶している不具合パターンリスト260を読み込む(S602)。 First, the defect detection device 100 reads the rule specification 250 stored in the information storage unit 230 (S601) and also reads the defect pattern list 260 stored in the information storage unit 230 (S602).

続いて、不具合検出装置100は、S601で読み込んだルール仕様250に基づきルールペアを生成する。ここでルールペアとは、データベースやファイル等への入出力を介してデータの受け渡しを行う2つの機能について、出力側機能のルールセットと入力側機能のルールセットの夫々からルールを1つずつ選択して組み合わせたものである。以下では、出力側機能のルールセットから選ばれたルールを「出力側ルール」と、また入力側機能のルールセットから選ばれたルールを「入力側ルール」と、夫々称する。例えば、図3に示すルール仕様250では、機能1と機能2、及び機能1と機能3が、夫々変数xの値を受け渡す出力側機能と入力側機能の組となっている。従って、この例の場合、不具合検出装置100は、機能1と機能2の組から4×3=12個、機能1と機能3の組から4×2=8個、合計20個のルールペアを生成する。 Subsequently, the defect detection device 100 generates a rule pair based on the rule specification 250 read in S601. Here, a rule pair is a rule pair that selects one rule from each of the output side function rule set and the input side function rule set for two functions that transfer data via input / output to a database or file. It is a combination of In the following, the rules selected from the rule set of the output side function will be referred to as "output side rules", and the rules selected from the rule set of the input side functions will be referred to as "input side rules". For example, in the rule specification 250 shown in FIG. 3, the function 1 and the function 2 and the function 1 and the function 3 are a set of an output side function and an input side function that pass the value of the variable x, respectively. Therefore, in the case of this example, the defect detection device 100 has a total of 20 rule pairs, 4 × 3 = 12 from the set of function 1 and function 2, and 4 × 2 = 8 from the set of function 1 and function 3. Generate.

尚、S603において、不具合検出装置100が、ルール仕様250から直接ルールペアを生成する代わりに、ルール仕様250に基づき出力側機能と入力側機能のペアを全て生成した後、各機能ペアからルールペアを生成するようにしてもよい。 In S603, instead of generating the rule pair directly from the rule specification 250, the defect detection device 100 generates all the pairs of the output side function and the input side function based on the rule specification 250, and then the rule pair is generated from each function pair. May be generated.

図6に戻り、S604では、不具合検出装置100は、S603で生成した全てのルールペアについてS605〜S609の処理を実行する。 Returning to FIG. 6, in S604, the defect detection device 100 executes the processes of S605 to S609 for all the rule pairs generated in S603.

S605では、不具合検出装置100は、S602で読み込んだ不具合パターンリスト260の全ての不具合についてS606〜S609の処理を実行する。 In S605, the defect detection device 100 executes the processes S606 to S609 for all the defects in the defect pattern list 260 read in S602.

S606では、不具合検出装置100は、現在処理中の不具合の不具合パターンにおいて「構文」を種別にもつ判定条件を、現在処理中のルールペアが満たしているか否かを判定する。不具合検出装置100は、判定条件の条件式中にプレースホルダ「出力変数」がある場合、現在処理中のルールペアにおける出力側ルールの出力変数をプレースホルダに格納して判定を行う。ルールペアが構文上のパターンを満たしているか否かは、例えば、パターンマッチングにより判定することができる。「構文」を種別にもつ全ての判定条件をルールペアが満たしている場合(S606:YES)、処理はS607に進み、満たしていない場合(S606:NO)、処理はS605のループに戻る。 In S606, the defect detection device 100 determines whether or not the rule pair currently being processed satisfies the determination condition having the "syntax" as the type in the defect pattern of the defect currently being processed. When the defect detection device 100 has a placeholder "output variable" in the conditional expression of the determination condition, the defect detection device 100 stores the output variable of the output side rule in the rule pair currently being processed in the placeholder and makes a determination. Whether or not the rule pair satisfies the syntactic pattern can be determined by, for example, pattern matching. If the rule pair satisfies all the determination conditions having the "syntax" as the type (S606: YES), the process proceeds to S607, and if not satisfied (S606: NO), the process returns to the loop of S605.

続いて、不具合検出装置100は、現在処理中の不具合の不具合パターンにおいて「意味」を種別にもつ判定条件を、現在処理中のルールペアが満たしているか否かを判定する(S607)。IF−THEN形式で記述されたルール仕様の場合、ルールペアが意味上のパターンを満たしているか否かは、例えば、SMTソルバ(Satisfiability Modulo Theories solver)を用いて判定することができる。「意味」を種別にもつ全ての判定条件
をルールペアが満たしている場合(S607:YES)、処理はS608に進み、そうでない場合(S607:NO)、処理はS605のループに戻る。
Subsequently, the defect detection device 100 determines whether or not the rule pair currently being processed satisfies the determination condition having "meaning" as the type in the defect pattern of the defect currently being processed (S607). In the case of the rule specification described in the IF-THEN format, whether or not the rule pair satisfies the semantic pattern can be determined by using, for example, an SMT solver (Satisfiability Modulo Theories solver). If the rule pair satisfies all the determination conditions having "meaning" as the type (S607: YES), the process proceeds to S608, and if not (S607: NO), the process returns to the loop of S605.

尚、本例では、S606で構文上のパターンを判定した後にS607で意味上のパターンを判定しているが、これらの処理の順序は逆にしてもよい。構文上のパターンの判定処理に時間がかかる場合、先に意味上のパターンの判定処理を行って構文上のパターンを判定するルールペアの数を減らすことで、不具合検出の処理時間を短縮することができる。 In this example, the syntactic pattern is determined in S606 and then the semantic pattern is determined in S607, but the order of these processes may be reversed. If it takes time to determine the syntactic pattern, reduce the number of rule pairs that determine the syntactic pattern by first performing the semantic pattern determination process to shorten the defect detection processing time. Can be done.

S608では、不具合検出装置100は、現在処理中のルールペアにおける出力側ルールの出力変数に現在処理中の不具合が含まれていることを、不具合検出結果270中の不具合サマリ510に記録する。例えば、不具合検出装置100は、図5に例示する不具合サマリ510において、当該出力変数の行の当該不具合の欄に「●」を記録する。 In S608, the defect detection device 100 records in the defect summary 510 in the defect detection result 270 that the output variable of the output side rule in the rule pair currently being processed includes the defect currently being processed. For example, the defect detection device 100 records “●” in the defect column of the output variable line in the defect summary 510 illustrated in FIG.

S609では、不具合検出装置100は、S608で不具合が含まれていると記録した出力変数と不具合に関する発生条件として、検出された不具合の発生条件リスト520に現在処理中のルールペアを構成している2つのルールを追加する。尚、既に検出された不具合の発生条件リスト520に同じルールが含まれている場合、そのルールは検出された不具合の発生条件リスト520に追加しなくてもよい。 In S609, the defect detection device 100 configures the rule pair currently being processed in the detected defect occurrence condition list 520 as the output variable recorded in S608 as containing the defect and the occurrence condition related to the defect. Add two rules. If the same rule is included in the already detected defect occurrence condition list 520, the rule does not have to be added to the detected defect occurrence condition list 520.

以上に説明したように、不具合検出装置100は、データベースやファイル等への入出力を介してデータを共有する機能を有するソフトウェアについて、ルール仕様と不具合パターンリストとに基づき、データの具体的な値(意味上のパターン)を考慮して不具合を検出するので、ソフトウェアの不具合を効率よく確実に検出することができる。また不具合検出装置100は、不具合の発生条件を発生条件リスト520として明確な形で出力するので、ユーザがデバッグ時の修正箇所の特定に要する時間を短縮することができる。このように不具合検出装置100によれば、データを受け渡しながら動作するソフトウェアの不具合を効率よく検出することができる。そのため、ユーザはソフトウェアの修正箇所の特定や不具合の除去等の作業を効率よく行うことができる。 As described above, the defect detection device 100 is a software having a function of sharing data via input / output to a database, a file, or the like, based on a rule specification and a defect pattern list, and is a specific value of data. Since defects are detected in consideration of (semantic pattern), software defects can be detected efficiently and reliably. Further, since the defect detection device 100 outputs the occurrence condition of the defect in a clear form as the occurrence condition list 520, the time required for the user to identify the correction part at the time of debugging can be shortened. As described above, according to the defect detection device 100, it is possible to efficiently detect defects in software that operates while passing data. Therefore, the user can efficiently perform work such as identifying a correction part of the software and removing a defect.

[第2実施形態]
第1実施形態では、ルール仕様250及び不具合検出結果270において、夫々が含むルールをIF−THEN形式で記述しているが、第2実施形態の不具合検出装置100は、ルール仕様250及び不具合検出結果270の夫々が含むルールを決定表形式で記述す
る。尚、第2実施形態の不具合検出装置100のハードウェア構成及び基本的なソフトウェア構成については、第1実施形態の不具合検出装置100と同様である。以下では、主として第1実施形態と異なる構成について説明する。
[Second Embodiment]
In the first embodiment, the rules included in the rule specification 250 and the defect detection result 270 are described in the IF-THE format, but the defect detection device 100 of the second embodiment describes the rule specification 250 and the defect detection result. The rules contained in each of the 270 are described in a decision table format. The hardware configuration and the basic software configuration of the defect detection device 100 of the second embodiment are the same as those of the defect detection device 100 of the first embodiment. Hereinafter, a configuration different from that of the first embodiment will be mainly described.

図7は、第2実施形態の不具合検出装置100のルール仕様生成部210により生成され情報記憶部230が記憶する、決定表形式で記述されたルール仕様250の例である。同図に示すように、このルール仕様250は、機能1のルールセット710、機能2のルールセット720、及び機能3のルールセット730を含む。 FIG. 7 is an example of the rule specification 250 described in the decision table format, which is generated by the rule specification generation unit 210 of the defect detection device 100 of the second embodiment and stored by the information storage unit 230. As shown in the figure, the rule specification 250 includes a rule set 710 of function 1, a rule set 720 of function 2, and a rule set 730 of function 3.

同図に示すように、各ルールセットは、ルールID、条件部、及び結果部の各列を含む一つ以上のルールの行で構成される。各列には列ラベルが付され、条件部の列ラベルには条件式が、結果部の列ラベルには結果変数が設定される。例えば、同図におけるルールセット710の場合、2列の条件部と1列の結果部とを含み、条件部の各列ラベルには夫々、p、q>rが、結果部の各列ラベルにはxが設定されている。 As shown in the figure, each rule set is composed of one or more rule rows including each column of rule ID, condition part, and result part. A column label is attached to each column, a conditional expression is set in the column label of the condition part, and a result variable is set in the column label of the result part. For example, in the case of the rule set 710 in the figure, the condition part of two columns and the result part of one column are included, and p and q> r are added to the label of each column of the condition part, respectively. Is set to x.

各ルールの条件部と結果部には、列ラベルに設定された条件式や結果変数の値、又は値の範囲が設定される。ルールの条件部の全ての列において、条件式の具体的な値がルールに設定された値、又は値の範囲である時、そのルールの条件部が充足する。例えば、図7に例示するルールセット710のルール1は、条件式pの値が1、かつ、条件式q>rの値がTrue(真)の時に条件部が充足し、結果変数xの値が1となることを意味する。またルールセット720のルール2は、条件式zの値がz>10の範囲、かつ、条件式y/xの値が2以外の時に条件部が充足し、結果変数mの値が2となることを意味する。 The conditional expression set in the column label, the value of the result variable, or the range of values is set in the conditional part and the result part of each rule. In all columns of the conditional part of a rule, when the specific value of the conditional expression is the value set in the rule or the range of values, the conditional part of the rule is satisfied. For example, in rule 1 of the rule set 710 illustrated in FIG. 7, the conditional part is satisfied when the value of the conditional expression p is 1 and the value of the conditional expression q> r is True (true), and the value of the result variable x. Means that is 1. Further, in rule 2 of the rule set 720, the conditional part is satisfied when the value of the conditional expression z is in the range of z> 10 and the value of the conditional expression y / x is other than 2, and the value of the result variable m becomes 2. Means that.

図8は、図7に例示したルール仕様250、及び図4に例示した不具合パターンリスト260に基づき、第2実施形態の不具合検出装置100の不具合検出部220が生成した不具合検出結果270の例である。同図に示す不具合検出結果270は、図5に示した不具合検出結果270における発生条件リスト520において、不具合の発生条件の各ルールを決定表形式で記述したものに相当する。 FIG. 8 is an example of the defect detection result 270 generated by the defect detection unit 220 of the defect detection device 100 of the second embodiment based on the rule specification 250 illustrated in FIG. 7 and the defect pattern list 260 illustrated in FIG. be. The defect detection result 270 shown in FIG. 5 corresponds to a decision table format in which each rule of the defect occurrence condition is described in the occurrence condition list 520 in the defect detection result 270 shown in FIG.

第2実施形態の不具合検出装置100は、第1実施形態の不具合検出装置100と同様に不具合検出処理S600を実行する。尚、第2実施形態の不具合検出装置100が実行する不具合検出処理S600は、以下の点で第1実施形態の不具合検出装置100と同様に不具合検出処理S600と相違する。 The defect detection device 100 of the second embodiment executes the defect detection process S600 in the same manner as the defect detection device 100 of the first embodiment. The defect detection process S600 executed by the defect detection device 100 of the second embodiment is different from the defect detection process S600 in the same manner as the defect detection device 100 of the first embodiment in the following points.

まずS606では、不具合検出装置100は、現在処理中の不具合(不具合パターン)において「構文」を種別にもつ判定条件を現在処理中のルールペアが満たしているか否かを判定する。ルールペアが構文上のパターンを満たしているか否かは、ルールペアに含まれるルールを決定表形式からIF−THEN形式に変換した上で、第1実施形態と同様にパターンマッチングを行うことにより判定することができる。またルールの決定表形式からIF−THEN形式への変換は、例えば、以下のようにして行うことができる。即ち、まず列ラベルに設定された条件式や結果変数を、ルールの対応する行に設定された値と等号(=)で連結するか、又は値の範囲と連結する。続いて、条件部の列をすべて論理積(and)で連結し、「IF 条件部 THEN 結果部」の形に並べる。必要ならば適宜括弧を追加してもよい。例えば、図7に例示するルールセット710のルール1をIF−THEN形式に変換すると「IF p=1 and (q>r)=True THEN x=1」となる。 First, in S606, the defect detection device 100 determines whether or not the rule pair currently being processed satisfies the determination condition having the "syntax" as the type in the defect (defect pattern) currently being processed. Whether or not the rule pair satisfies the syntactic pattern is determined by converting the rules included in the rule pair from the decision table format to the IF-THE format and then performing pattern matching in the same manner as in the first embodiment. can do. Further, the conversion from the rule decision table format to the IF-THEN format can be performed, for example, as follows. That is, first, the conditional expression or result variable set in the column label is concatenated with the value set in the corresponding row of the rule by an equal sign (=), or concatenated with the range of values. Then, all the columns of the condition part are connected by a logical product (and) and arranged in the form of "IF condition part THEN result part". Parentheses may be added as appropriate if necessary. For example, when the rule 1 of the rule set 710 illustrated in FIG. 7 is converted into the IF-THE format, it becomes "IF p = 1 and (q> r) = True THEn x = 1".

またS607では、不具合検出装置100は、現在処理中の不具合の不具合パターンにおいて「意味」を種別にもつ判定条件を、現在処理中のルールペアが満たしているか否かを判定する。ルールペアが意味上のパターンを満たしているか否かは、S606と同様の
方法でルールを決定表形式からIF−THEN形式に変換した上で判定することができる。
Further, in S607, the defect detection device 100 determines whether or not the rule pair currently being processed satisfies the determination condition having "meaning" as the type in the defect pattern of the defect currently being processed. Whether or not the rule pair satisfies the semantic pattern can be determined after converting the rule from the decision table format to the IF-THEN format in the same manner as in S606.

尚、S606とS607において、ルールを決定表形式からIF−THEN形式に変換する代わりに、S601等で事前にルール形式をIF−THEN形式に変換してもよい。またS606でIF−THEN形式に変換せず、決定表形式のまま構文上のパターンを判定するようにしてもよい。 In S606 and S607, instead of converting the rule from the decision table format to the IF-THEN format, the rule format may be converted to the IF-THEN format in advance by S601 or the like. Further, the syntactic pattern may be determined in the decision table format without converting to the IF-THEN format in S606.

以上のように変更することで、不具合検出装置100は、不具合の発生条件を決定表形式で出力するため、IF−THEN形式よりも不具合の発生条件の可読性が上がり、デバッグ時の修正箇所の特定に要する時間を更に短縮することができる。 By making the above changes, the defect detection device 100 outputs the defect occurrence conditions in the decision table format, so that the readability of the defect occurrence conditions is higher than in the IF-THEN format, and the correction location during debugging can be specified. The time required for this can be further reduced.

以上、本発明について実施の形態に基づき具体的に説明したが、本発明は上記の実施の形態に限定されるものではなく、その要旨を逸脱しない範囲で種々変更可能であることはいうまでもない。例えば、上記の実施の形態は本発明を分かりやすく説明するために詳細に説明したものであり、必ずしも説明した全ての構成を備えるものに限定されるものではない。また上記実施形態の構成の一部について、他の構成の追加・削除・置換をすることが可能である。 Although the present invention has been specifically described above based on the embodiments, it goes without saying that the present invention is not limited to the above embodiments and can be variously modified without departing from the gist thereof. No. For example, the above-described embodiment has been described in detail in order to explain the present invention in an easy-to-understand manner, and is not necessarily limited to the one including all the described configurations. Further, it is possible to add / delete / replace a part of the configuration of the above embodiment with another configuration.

また上記の各構成、機能部、処理部、処理手段等は、それらの一部または全部を、例えば、集積回路で設計する等によりハードウェアで実現してもよい。また上記の各構成、機能等は、プロセッサがそれぞれの機能を実現するプログラムを解釈し、実行することによりソフトウェアで実現してもよい。各機能を実現するプログラム、テーブル、ファイル等の情報は、メモリやハードディスク、SSD(Solid State Drive)等の記録装置、また
はICカード、SDカード、DVD等の記録媒体に置くことができる。
Further, each of the above configurations, functional units, processing units, processing means and the like may be realized by hardware by designing a part or all of them by, for example, an integrated circuit. Further, each of the above configurations, functions, and the like may be realized by software by the processor interpreting and executing a program that realizes each function. Information such as programs, tables, and files that realize each function can be placed in a memory, a hard disk, a recording device such as an SSD (Solid State Drive), or a recording medium such as an IC card, an SD card, or a DVD.

また上記の各図において、制御線や情報線は説明上必要と考えられるものを示しており、必ずしも実装上の全ての制御線や情報線を示しているとは限らない。例えば、実際にはほとんど全ての構成が相互に接続されていると考えてもよい。 Further, in each of the above figures, the control lines and information lines are shown as necessary for explanation, and not all the control lines and information lines in the implementation are necessarily shown. For example, in practice almost all configurations may be considered interconnected.

また以上に説明した不具合検出装置100の各種機能部、各種処理部、各種データベースの配置形態は一例に過ぎない。各種機能部、各種処理部、各種データベースの配置形態は、不具合検出装置100が備えるハードウェアやソフトウェアの性能、処理効率、通信効率等の観点から最適な配置形態に変更し得る。 Further, the arrangement form of the various functional units, the various processing units, and the various databases of the defect detection device 100 described above is only an example. The arrangement form of the various function units, the various processing units, and the various databases can be changed to the optimum arrangement form from the viewpoints of the performance, processing efficiency, communication efficiency, and the like of the hardware and software included in the defect detection device 100.

また前述した各種データベースの構成(スキーマ(Schema)等)は、リソースの効率的な利用、処理効率向上、アクセス効率向上、検索効率向上等の観点から柔軟に変更し得る。 Further, the above-mentioned configurations of various databases (schema, etc.) can be flexibly changed from the viewpoints of efficient use of resources, improvement of processing efficiency, improvement of access efficiency, improvement of search efficiency, and the like.

100 不具合検出装置、210 ルール仕様生成部、220 不具合検出部、230 情報記憶部、240 ソースコード、250 ルール仕様、260 不具合パターンリスト、270 不具合検出結果、520 検出された不具合の発生条件リスト、S600 不具合検出処理 100 Defect detection device, 210 Rule specification generator, 220 Defect detection unit, 230 Information storage unit, 240 Source code, 250 Rule specifications, 260 Defect pattern list, 270 Defect detection result, 520 Defect detection condition list, S600 Defect detection process

Claims (13)

ソフトウェアの仕様を、入力変数についての条件を示す情報と出力変数の値を示す情報とを含む一つ以上のルールにより記述した情報である、ルール仕様と、
検出しようとする不具合の特徴を、ルール仕様の構文上のパターンにより表した情報を含む、不具合パターンリストと、
を記憶する情報記憶部と、
前記ルール仕様と前記不具合パターンリストとを照合し、前記ルール仕様から前記パターンを満たす前記ルールを抽出した情報である不具合の発生条件リストを生成する不具合検出部と、
を備える、不具合検出装置。
A rule specification, which is information that describes a software specification by one or more rules including information indicating a condition for an input variable and information indicating a value of an output variable.
The failure of the features to be detected, including information expressed by the pattern on the syntax of the rule specification, and defect pattern list,
Information storage unit that stores
A defect detection unit that collates the rule specification with the defect pattern list and generates a defect occurrence condition list that is information obtained by extracting the rule that satisfies the pattern from the rule specification.
A defect detection device equipped with.
請求項1に記載の不具合検出装置であって、 The defect detection device according to claim 1.
前記不具合パターンリストは、検出しようとする不具合の特徴を、ルール仕様の意味上のパターンにより表した情報を含み、 The defect pattern list includes information representing the characteristics of the defect to be detected by the semantic pattern of the rule specification.
前記不具合パターンリストは、 The defect pattern list is
種別と条件式の各項目を有する1つ以上の判定条件を含み、 Includes one or more determination conditions with each item of type and conditional expression
前記種別には、当該判定条件が構文または意味のいずれについての判定条件であるかを示す情報が設定され、 Information indicating whether the judgment condition is a judgment condition in terms of syntax or meaning is set in the type.
前記条件式には、前記ルール仕様が不具合を含むと判断するパターンが設定される、 In the conditional expression, a pattern for determining that the rule specification includes a defect is set.
不具合検出装置。 Defect detection device.
請求項1または2に記載の不具合検出装置であって、
前記不具合検出部は、前記出力変数についての不具合の有無を示す情報である不具合サマリを生成する、
不具合検出装置。
The defect detection device according to claim 1 or 2.
The defect detection unit generates a defect summary which is information indicating the presence or absence of a defect in the output variable.
Defect detection device.
請求項に記載の不具合検出装置であって、
前記不具合検出部は、
前記ルール仕様に基づき、データの出力側となる機能を構成する前記ルールと前記データの入力側となる機能を構成する前記ルールとの組み合わせである複数のルールペアを生成し、
前記ルールペアと前記不具合パターンリストとを照合し、前記パターンを満たす前記ルールペアを抽出した情報を前記不具合の発生条件リストとして生成する、
不具合検出装置。
The defect detection device according to claim 2.
The defect detection unit
Based on the rule specifications, a plurality of rule pairs that are a combination of the rule that constitutes the function that is the output side of the data and the rule that constitutes the function that is the input side of the data are generated.
The rule pair is collated with the defect pattern list, and the information obtained by extracting the rule pair satisfying the pattern is generated as the defect occurrence condition list.
Defect detection device.
請求項4に記載の不具合検出装置であって、
前記不具合検出部は、前記ルールペアが前記意味上のパターンを満たしているか否かをSMTソルバ(Satisfiability Modulo Theories solver)により判定する、
不具合検出装置。
The defect detection device according to claim 4.
The defect detection unit determines whether or not the rule pair satisfies the semantic pattern by using an SMT solver (Satisfiability Modulo Theories solver).
Defect detection device.
請求項1乃至のいずれか一項に記載の不具合検出装置であって、
前記ルール仕様はIF−THEN形式で記述される、
不具合検出装置。
The defect detection device according to any one of claims 1 to 5.
The rule specifications are described in IF-THEN format.
Defect detection device.
請求項1乃至のいずれか一項に記載の不具合検出装置であって、
前記ルール仕様は、決定表形式で記述される、
不具合検出装置。
The defect detection device according to any one of claims 1 to 5.
The rule specifications are described in a decision table format.
Defect detection device.
請求項1乃至のいずれか一項に記載の不具合検出装置であって、
前記不具合の発生条件リストは、IF−THEN形式で記述される、
不具合検出装置。
The defect detection device according to any one of claims 1 to 5.
The defect occurrence condition list is described in IF-THEN format.
Defect detection device.
請求項1乃至のいずれか一項に記載の不具合検出装置であって、
前記不具合の発生条件リストは、決定表形式で記述される、
不具合検出装置。
The defect detection device according to any one of claims 1 to 5.
The list of conditions for occurrence of the defect is described in a decision table format.
Defect detection device.
情報処理装置が、
ソフトウェアの仕様を、入力変数についての条件を示す情報と出力変数の値を示す情報とを含む一つ以上のルールにより記述した情報である、ルール仕様と、
検出しようとする不具合の特徴を、ルール仕様の構文上のパターンにより表した情報を含む、不具合パターンリストと、
を記憶するステップ、及び、
前記ルール仕様と前記不具合パターンリストとを照合し前記ルール仕様から前記パターンを満たす前記ルールを抽出した情報である不具合の発生条件リストを生成するステップ、
を実行する、不具合検出方法。
Information processing device
A rule specification, which is information that describes a software specification by one or more rules including information indicating a condition for an input variable and information indicating a value of an output variable.
The failure of the features to be detected, including information expressed by the pattern on the syntax of the rule specification, and defect pattern list,
Steps to memorize, and
A step of collating the rule specification with the defect pattern list and generating a defect occurrence condition list which is information obtained by extracting the rule satisfying the pattern from the rule specification.
How to detect defects.
請求項10に記載の不具合検出方法であって、 The defect detection method according to claim 10.
前記不具合パターンリストは、検出しようとする不具合の特徴を、ルール仕様の意味上のパターンにより表した情報を含み、 The defect pattern list includes information representing the characteristics of the defect to be detected by the semantic pattern of the rule specification.
前記不具合パターンリストは、種別と条件式の各項目を有する1つ以上の判定条件を含み、前記種別には、当該判定条件が構文または意味のいずれについての判定条件であるかを示す情報が設定され、前記条件式には、前記ルール仕様が不具合を含むと判断するパターンが設定される、 The defect pattern list includes one or more judgment conditions having each item of a type and a conditional expression, and the type is set with information indicating whether the judgment condition is a judgment condition for syntax or meaning. Then, in the conditional expression, a pattern for determining that the rule specification includes a defect is set.
不具合検出方法。Defect detection method.
請求項10または11に記載の不具合検出方法であって、
前記情報処理装置が、前記出力変数についての不具合の有無を示す情報である不具合サマリを生成するステップをさらに実行する、
不具合検出方法。
The defect detection method according to claim 10 or 11.
The information processing apparatus further executes a step of generating a defect summary which is information indicating the presence or absence of a defect in the output variable.
Defect detection method.
請求項11に記載の不具合検出方法であって、
前記情報処理装置が、
前記ルール仕様に基づき、データの出力側となる機能を構成する前記ルールと前記データの入力側となる機能を構成する前記ルールとの組み合わせである複数のルールペアを生成するステップ、及び
前記ルールペアと前記不具合パターンリストとを照合し、前記パターンを満たす前記ルールペアを抽出した情報を前記不具合の発生条件リストとして生成するステップ、
を実行する、不具合検出方法。
The defect detection method according to claim 11.
The information processing device
Based on the rule specifications, a step of generating a plurality of rule pairs which are a combination of the rule constituting the function of the data output side and the rule constituting the function of the data input side, and the rule pair. And the defect pattern list, and the information obtained by extracting the rule pair satisfying the pattern is generated as the defect occurrence condition list.
How to detect defects.
JP2017213735A 2017-11-06 2017-11-06 Defect detection device and defect detection method Active JP6954806B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017213735A JP6954806B2 (en) 2017-11-06 2017-11-06 Defect detection device and defect detection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017213735A JP6954806B2 (en) 2017-11-06 2017-11-06 Defect detection device and defect detection method

Publications (2)

Publication Number Publication Date
JP2019086953A JP2019086953A (en) 2019-06-06
JP6954806B2 true JP6954806B2 (en) 2021-10-27

Family

ID=66764204

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017213735A Active JP6954806B2 (en) 2017-11-06 2017-11-06 Defect detection device and defect detection method

Country Status (1)

Country Link
JP (1) JP6954806B2 (en)

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08272623A (en) * 1995-04-03 1996-10-18 Toshiba Corp Device and method for program analysis
US20120017119A1 (en) * 2010-07-16 2012-01-19 Fujitsu Limited Solving Hybrid Constraints to Generate Test Cases for Validating a Software Module

Also Published As

Publication number Publication date
JP2019086953A (en) 2019-06-06

Similar Documents

Publication Publication Date Title
KR102464222B1 (en) Configurable annotations for privacy-sensitive user content
US6442684B1 (en) Determining a current machine state of software
EP3616066B1 (en) Human-readable, language-independent stack trace summary generation
JP5665128B2 (en) Static analysis support device, static analysis support method, and program
US9135591B1 (en) Analysis and assessment of software library projects
TW200527229A (en) Learning and using generalized string patterns for information extraction
CN108595187A (en) Method, device and the storage medium of Android installation kit integrated software development kit
US20150074045A1 (en) Business Rule Management System
JP2017041171A (en) Test scenario generation support device and test scenario generation support method
JP6440895B2 (en) Software analysis apparatus and software analysis method
JP2018005535A (en) Software development assist method and system
JP6692281B2 (en) Test case generation device and test case generation method
JP2009205523A (en) Automatic property generator
CN113434542A (en) Data relation identification method and device, electronic equipment and storage medium
JP2019219848A (en) Source code analysis method and source code analysis device
JP6954806B2 (en) Defect detection device and defect detection method
JP2018106556A (en) Screen information generating apparatus, screen information generating method, and program
CN110737642B (en) Database information analysis method, database information analysis device, computer device and storage medium
CN113900956A (en) Test case generation method and device, computer equipment and storage medium
JP6870454B2 (en) Analytical equipment, analytical programs and analytical methods
JP5808264B2 (en) Code generation apparatus, code generation method, and program
JP2017151594A (en) Supporting device, supporting method, and program
JP6983693B2 (en) Stub generation support device, stub generation support method, and program
JP7456843B2 (en) Program modification device, program modification method, and program modification program
JP2014174921A (en) Information processing system, and name-identification determination method and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20200316

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210302

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20210405

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: 20210928

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20210930

R150 Certificate of patent or registration of utility model

Ref document number: 6954806

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150