Supercharge Your Innovation With Domain-Expert AI Agents!

A method and device for converting program code into data constraints

A technology of data constraints and program codes, which is applied in the fields of electrical digital data processing, computer security devices, instruments, etc., can solve the problems of high complexity of intermediate instructions and difficult extraction of data constraints, and achieve the effect of facilitating constraint extraction

Active Publication Date: 2020-03-27
NANJING UNIV
View PDF2 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0005] The problem to be solved by the present invention: under the existing technology, the complexity of intermediate instructions is high, which leads to difficulties in data constraint extraction

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • A method and device for converting program code into data constraints
  • A method and device for converting program code into data constraints
  • A method and device for converting program code into data constraints

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0032] The present invention will be described in further detail below in conjunction with the accompanying drawings.

[0033] The method for converting program codes into data constraints of the present invention includes two steps: a step of converting source codes into intermediate instruction sets and a step of processing the intermediate instruction sets to extract data constraints. Wherein, the former is the aforementioned step S1, converting the source code input by the user into an intermediate instruction set; the latter is the aforementioned steps S2, S3, S4 and S5.

[0034] The process of step S1 can be implemented by a general front-end compiler. Those skilled in the art understand that under the framework of existing compiler theory, a compiler generally consists of a front-end compiler, an optimization module and a back-end compiler. The front-end compiler is used to convert source codes in different languages ​​into intermediate instruction sets, then the optim...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention discloses a method and a device for converting program codes into data constraint. According to the method, first, the program codes are converted into an intermediate instruction set; second, the intermediate instruction set is refined and split, and variables of a complicated type involved in an original variable definition instruction are refined and split into multiple variables of a simple type in the refining and splitting process; third, the variables of the simple type are further refined into address pointer variables of a simple type and pointer pointing variables of a simple type; and last, the corresponding variable definition instruction is refined and split into a memory distribution instruction and an initialized data storage instruction targeting the address pointer variables of the simple type and the pointer pointing variables of the simple type, and then an access instruction, an arithmetic instruction and a comparison instruction in the refined and split intermediate instruction set are extracted to serve as the data constraint.

Description

technical field [0001] The invention relates to an analysis and verification technology of program codes, in particular to the problem of analyzing whether there is an error in the program codes through the data constraints after converting the program codes into data constraints. Background technique [0002] Today, with the rapid development of application software, software security and reliability have become a crucial issue, and code analysis and verification testing is a common method in related fields. Code analysis, testing, verification, etc. often need to extract corresponding constraints for the program, and judge the security of the software code on the constraint set. In this process, constraint extraction plays a very important role. [0003] One of the existing methods is to first convert the code into intermediate code through a compiler, and then extract constraints on the original code based on this. For example, the LLVM project is a modular and reusable...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
Patent Type & Authority Patents(China)
IPC IPC(8): G06F21/56
CPCG06F21/563
Inventor 卜磊李一超陶昱天闾乐成梁东隽沈大川赵建华李宣东
Owner NANJING UNIV
Features
  • R&D
  • Intellectual Property
  • Life Sciences
  • Materials
  • Tech Scout
Why Patsnap Eureka
  • Unparalleled Data Quality
  • Higher Quality Content
  • 60% Fewer Hallucinations
Social media
Patsnap Eureka Blog
Learn More