Reference-Sensitivity Analysis in Partial Evaluation for XQuery
Hang Su, Husheng Liao · 2009
In the partial evaluation for XQuery, the reconstruction for XML document segment is used to represent the result of the constant folding for the value of a node expression. But the representation of the result do lost some semantic information of the value, such as the relative position of a node in an XML document. Unfortunately, there are some special expressions that work out their values by using the semantic information in XQuery. A wrong residual program will be produced by the partial evaluator when reconstructs the values of the expressions which participate in the computing of those special expressions. And it will result in a low efficient partial evaluation if constant folding is arbitrarily prohibited. To avoid the mistake and achieve an effective partial evaluation for XQuery, a novel method, called reference-sensitivity analysis, is proposed in this thesis, which can be used to distinguish the node expression whose value can not be reconstructed for doing constant folding from others.