efficient static analysis of xml paths and types
play

Efficient Static Analysis of XML Paths and Types Pierre Genevs - PowerPoint PPT Presentation

Efficient Static Analysis of XML Paths and Types Pierre Genevs EPFL, Switzerland Joint work with Nabil Layada and Alan Schmitt INRIA, France PLDI07, San Diego, June 2007 Introduction More and more XML data Objective: ensuring


  1. Efficient Static Analysis of XML Paths and Types Pierre Genevès – EPFL, Switzerland Joint work with Nabil Layaïda and Alan Schmitt – INRIA, France PLDI’07, San Diego, June 2007

  2. Introduction More and more XML data Objective: ensuring safety and efficiency of programs that manipulate XML Two ways for processing XML: General purpose languages extended with librairies 1 DSLs: e.g. XSLT, XQuery (W3C standards) that rely on XPath 2 In both cases: static analysis of programs very hard (very complex to detect errors at compile-time) This paper: we solve important XML static analysis tasks by reduction to satisfiability of a new tree logic P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  3. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b /descendant::b/parent::a/child::c ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  4. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b /descendant::b/parent::a/child::c ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  5. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b /descendant::b /parent::a/child::c ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  6. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b /descendant::b/parent::a /child::c ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  7. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b /descendant::b/parent::a/child::c ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  8. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  9. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  10. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? ? /descendant::b/parent::a/child::c ⊕ T = ∅ ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  11. Safety and Efficiency of Programs / Programs that manipulate XML trees a c Analysis: ∈ b c tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  12. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... q optimised } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  13. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... q optimised } let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  14. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ... ? q optimised } q ∩ q forbidden � = ∅ let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  15. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ! ... ? q optimised } q ∩ q forbidden � = ∅ forbidden access! let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  16. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ! ... ? q optimised } q ∩ q forbidden � = ∅ forbidden access! let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  17. Safety and Efficiency of Programs / Programs that manipulate a c XML trees Analysis: ∈ c b tree types (XML Schemas, Type T a DTDs) queries (XPath) b ? /descendant::b/parent::a/child::c ⊕ T ≡ /child::a/child::c � �� � � �� � q optimised q for x in (q) do { ! ... ? q optimised } q ∩ q forbidden � = ∅ forbidden access! let n = q; ... Before: complexity too high, implementations out of scope... This paper: optimal complexity + efficient implementation P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

  18. XPath Static Analysis Tasks Basic Tasks XPath typing 1 XPath query comparisons 2 query containment, emptiness, overlap, equivalence Main Applications Static analysis of host languages: error detection, optimization (static type-checkers, optimizing compilers) Checking integrity constraints in XML databases P . Genevès, EPFL Efficient Static Analysis of XML Paths and Types

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend