Lune

PLDI2023Top-tier venue

Conflict-Driven Synthesis for Layout Engines

Junrui Liu, Yanju Chen, Eric Atkinson, Yu Feng, Rastislav Bodík

Abstract

Modern web browsers rely on layout engines to convert HTML documents to layout trees that specify color, size, and position. However, existing layout engines are notoriously difficult to maintain because of the complexity of web standards. This is especially true for incremental layout engines, which are designed to improve performance by updating only the parts of the layout tree that need to be changed. In this paper, we propose Medea, a new framework for automatically generating incremental layout engines. Medea separates the specification of the layout engine from its incremental implementation, and guarantees correctness through layout engine synthesis. The synthesis is driven by a new iterative algorithm based on detecting conflicts that prevent optimality of the incremental algorithm. We evaluated Medea on a fragment of HTML layout that includes challenging features such as margin collapse, floating layout, and absolute positioning. Medea successfully synthesized an incremental layout engine for this fragment. The synthesized layout engine is both correct and efficient. In particular, we demonstrated that it avoids real-world bugs that have been reported in the layout engines of Chrome, Firefox, and Safari. The incremental layout engine synthesized by Medea is up to 1.82× faster than a naive incremental baseline. We also demonstrated that our conflict-driven algorithm produces engines that are 2.74× faster than a baseline without conflict analysis.

Ask Lune

Know where this paper stands in minutes, not an afternoon.

Lune can read the top-tier papers that cite it and the ones closest to it, and tells you what it claims, what came after and where it falls short, each point cited to the paper it comes from. No skimming, no AI slop.

5 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

its abstract · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Semantics for 2D Rasterization cites Spineless Traversal for Layout Invalidation
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers5

  1. FORAY: Towards Effective Attack Synthesis against Deep Logical Vulnerabilities in DeFi ProtocolsHongbo Wen, Hanzhi Liu, Jiaxin Song, Yanju Chen et al.CCS 2024 · 6 citations
  2. D-VSync: Decoupled Rendering and Displaying for Smartphone GraphicsYuanpei Wu, Dong Du, Chao Xu, Yubin Xia et al.ASPLOS 2025 · 3 citations
  3. Spineless Traversal for Layout InvalidationMarisa Kirisame, Tiezhi Wang, Pavel PanchekhaPLDI 2025
  4. Diagramming Program Values by Spatial RefinementSiddhartha Prasad, Michael Tu, Karan Kashyap, Tim Nelson et al.PLDI 2026
  5. Semantics for 2D RasterizationBhargav Kulkarni, Henry Whiting, Pavel PanchekhaOOPSLA 2026

Related papers

  1. Metamong: Detecting Render-Update Bugs in Web Browsers through FuzzingSuhwan Song, Byoungyoung LeeFSE 2023 · 2 citations
  2. MulFCoder: Framework-conditioned Multi-agent for MLLM-based Multi-framework Front-end Code GenerationJie Wu, Haoran Ma, Shisong Tang, Yulin Xu et al.ICML 2026
  3. Automated Fixing of Web UI Tests via Iterative Element MatchingYuanzhang Lin, Guoyao Wen, Xiang GaoASE 2023 · 8 citations
  4. PTDETECTOR: An Automated JavaScript Front-end Library DetectorXinyue Liu, Lukasz ZiarekASE 2023 · 2 citations
  5. Janus: Detecting Rendering Bugs in Web Browsers via Visual Delta ConsistencyChijin Zhou, Quan Zhang, Bingzhou Qian, Yu JiangICSE 2025 · 2 citations
Dusk over the sea between two cliffs drawn in fine vertical lines