Intermediate code optimization method for binary translation based on intermediate representation rule replacement
Author:
Affiliation:

(1. PLA Strategic Support Force Information Engineering University, Zhengzhou 450001, China;2. State Key Laboratory of Mathematical Engineering and Advanced Computing, Zhengzhou 450002, China)

Clc Number:

TP314

Fund Project:

  • Article
  • |
  • Figures
  • |
  • Metrics
  • |
  • Reference
  • |
  • Related
  • |
  • Cited by
  • |
  • Materials
  • |
  • Comments
    Abstract:

    In the process of realizing multi-source to multi-target program translation, the dynamic binary translation uses intermediate code to shield the hardware differences between different source platforms, and the memory virtual strategy is adopted to achieve the goal. As a result, it brings about the problem of intermediate code expansion. Traditional intermediate code optimization methods usually use the method of matching and deleting redundant instructions. The intermediate representation rule replacement for special instruction matching was focused on, and an intermediate code optimization method for binary translation based on intermediate representation rule replacement was proposed. This method described the corresponding intermediate representation replacement rules for several typical scenarios of intermediate code expansion, and the register direct mapping strategy used in the back-end code optimization was applied here. By establishing mapping formula, the memory virtual operation was replaced by local register operation, thus reducing the expansion degree of intermediate code. The SPEC CPU2006 test suite was used to carry out the experimental, and the experimental results verify the correctness and effectiveness of this optimization method. The results before and after optimization are consistent, which verifies the correctness of the optimization method, meanwhile, the average reduction rate of intermediate code for each case after optimization is 32.59%, which verifies the effectiveness of the optimization method.

    Reference
    Related
    Cited by
Get Citation
Share
Article Metrics
  • Abstract:
  • PDF:
  • HTML:
  • Cited by:
History
  • Received:November 09,2020
  • Revised:
  • Adopted:
  • Online: July 20,2021
  • Published: August 28,2021
Article QR Code