A Method of Instruction Optimization

An instruction optimization and instruction technology, applied in instruments, computing, electrical and digital data processing, etc., can solve problems such as loopholes, inability to verify comparative analysis, lack of overall consideration, etc., to improve efficiency, improve operating speed, and meet industrial control real-time requirements. Effects of sexual demands

Active Publication Date: 2021-10-01
NR ELECTRIC CO LTD +1
View PDF8 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Commonly used compilers usually optimize at the compilation stage, but because they are limited to the optimization of local functions, they lack overall consideration, and the optimization method used is a black box, which has loopholes and cannot be verified for comparative analysis

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 of Instruction Optimization

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0018] The technical solutions and beneficial effects of the present invention will be described in detail below in conjunction with the accompanying drawings.

[0019] Such as figure 1 As shown, the present invention provides a method for instruction optimization, comprising the steps of:

[0020] (1) Obtain the instruction file compiled by the structured text (ST) program; read the file header, and obtain the contents of the data area and the instruction area. Preferably, the instruction file is divided into a file header, a data area, and an instruction area. The data area stores information such as variable index, variable type, variable attribute, and initial value, including referenced external variables, variables defined by ST programs, and temporary variables generated by compilation. In the instruction area, follow the format of the three-address code, that is, the instruction type, the address of the left operand (lvalue variable) in the data area, and the address...

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 an instruction optimization method, which comprises the following steps: step 1, obtaining the instruction file compiled by the structured text program, obtaining the contents of the data area and the instruction area; step 2, analyzing the data area, and extracting variable information; step 3, dividing Traversing the instruction area three times, sequentially adopting optimization methods of assignment optimization, algebraic simplification, and reference point processing to merge, delete, and adjust instructions; step 4, store optimized data and instruction information as files. This optimization method can perform reliable and fast optimization of instructions by analyzing instruction files of a predetermined format after ST program compilation, and improve program operating efficiency.

Description

technical field [0001] The invention belongs to the field of industrial control programming, and in particular relates to an instruction optimization processing method after the structured text is compiled. Background technique [0002] IEC61131 is an international standard for programmable logic controllers (PLC) promulgated by the International Electrotechnical Commission (IEC), which regulates the development of programming tools and application control programs for programmable logic controllers. IEC61131-3 defines the structured text (ST) language, ST is a high-level programming language similar to Pascal, especially suitable for complex algorithm technology, the program structure is clear, and it is convenient for programmers and operation and maintenance personnel to communicate algorithms. Structured text needs to be converted into an instruction file that the device can run in order to run. When an embedded device interprets and executes binary instructions, it has...

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): G06F9/30
CPCG06F9/3001
Inventor 熊蕙陈宏君张磊文继锋谭良良周磊徐睿曾凯刘坤顾熹谭林丰
Owner NR ELECTRIC CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products