The invention relates to a variable recalculation method, a variable recalculation
system, variable recalculation equipment and a medium based on
data flow analysis. The method comprises the steps of setting Boolean attributes on a ternary lattice of a re-computable seed, and spreading the Boolean attributes according to a preset instruction type, so that the Boolean attributes are unified at a
data control flow merging point through union operation of the lattice, and a re-computable judgment result of each variable is obtained. And identifying cross-sub-kernel variables, and classifying the cross-sub-kernel variables according to the re-computable judgment result to obtain uniform variables, re-computable variables and non-re-computable variables. A first
data structure set is constructed by assigning on-stack variables to uniform variables, recording a calculation sequence of recalculable variables, and assigning on-stack arrays to non-recalculable variables. According to the first
data structure set,
code conversion is carried out when the work item loop is created, and variable recalculation and expansion of the variables are completed. By adopting the method, redundant storage and memory access operations can be reduced to the maximum extent.