Xingyu Xie
operator node & dataflow edge
referentially transparent: value of an expression depends only on its constituent expressions, no side effect
complete: any source program could be represented as PEG
≥
function validate(cfg1, cfg2: CFG): CFG
let peg1 = ConvertToPEG(cfg1)
let peg2 = ConvertToPEG(cfg2)
// A is the set of axioms
let epeg = Saturate(peg1, A)
return isInstantiation(peg2, epeg)
E-PEG is PEG with a set of equalities over nodes of PEG.
Ax1
Ax2
Ax3
Ax2
Ax3
Ax1
Ax1
saturation: repeatedly apply axioms to infer new equalities, until no axiom could be applied or given bounds are reached.
Axiom application:
Partial order (subset):
Axiom a is monotonic:
Generally, there maybe not a normal form such as
When the normal form doesn't exist, saturation may not terminate. Thus, we bound the number of times of same application.
My thought: there must be a normal sequence , where , s.t.
We define ir2 to be a normal form of ir1 if: