Adaptive LL(*) Parsing: The Power of Dynamic Analysis

被引:0
|
作者
Parr, Terence [1 ]
Harwell, Sam [2 ]
Fisher, Kathleen [3 ]
机构
[1] Univ San Francisco, San Francisco, CA 94117 USA
[2] Univ Texas Austin, Austin, TX 78712 USA
[3] Tufts Univ, Medford, MA USA
关键词
Algorithms; Languages; Theory; nondeterministic parsing; DFA; augmented transition networks; grammar; ALL(*); LL(*); GLR; GLL; PEG;
D O I
10.1145/2714064.2660202
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Despite the advances made by modern parsing strategies such as PEG, LL(*), GLR, and GLL, parsing is not a solved problem. Existing approaches suffer from a number of weaknesses, including difficulties supporting side-effecting embedded actions, slow and/or unpredictable performance, and counter-intuitive matching strategies. This paper introduces the ALL(*) parsing strategy that combines the simplicity, efficiency, and predictability of conventional top-down LL(k) parsers with the power of a GLR-like mechanism to make parsing decisions. The critical innovation is to move grammar analysis to parse-time, which lets ALL(*) handle any non-left-recursive context-free grammar. ALL(*) is O(n(4)) in theory but consistently performs linearly on grammars used in practice, outperforming general strategies such as GLL and GLR by orders of magnitude. ANTLR 4 generates ALL(*) parsers and supports direct left-recursion through grammar rewriting. Widespread ANTLR 4 use (5000 downloads/month in 2013) provides evidence that ALL(*) is effective for a wide variety of applications.
引用
收藏
页码:579 / 598
页数:20
相关论文
共 50 条
  • [41] Adaptive Analysis of Power System Dynamic Topology Based on Multi-area Pinning Synchronization
    Li X.
    Han B.
    Li G.
    Luo L.
    Wang K.
    Han, Bei (han_bei@sjtu.edu.cn), 1600, Chinese Society for Electrical Engineering (41): : 3807 - 3817
  • [42] Simplified Power Adaptive Digital Predistorter for RF Power Amplifiers in Dynamic Power Transmission
    Guo, Yan
    Yu, Chao
    Zhu, Anding
    2015 45TH EUROPEAN MICROWAVE CONFERENCE (EUMC), 2015, : 1132 - 1135
  • [43] Simplified Power Adaptive Digital Predistorter for RF Power Amplifiers in Dynamic Power Transmission
    Guo, Yan
    Yu, Chao
    Zhu, Anding
    2015 10TH EUROPEAN MICROWAVE INTEGRATED CIRCUITS CONFERENCE (EUMIC), 2015, : 281 - 284
  • [44] Dynamic control analysis of charging and discharging power for electric vehicles with adaptive optimal fuzzy control
    Meng, Fanzi
    Zhang, Yu
    Meng, Fanzi (mengfanzi@jluat.edu.cn), 1600, IOS Press BV (41): : 4929 - 4936
  • [45] A Low-Power Circuit for Adaptive Dynamic Programming
    Zheng, Nan
    Mazumder, Pinaki
    2018 31ST INTERNATIONAL CONFERENCE ON VLSI DESIGN AND 2018 17TH INTERNATIONAL CONFERENCE ON EMBEDDED SYSTEMS (VLSID & ES), 2018, : 192 - 197
  • [46] Dynamic control analysis of charging and discharging power for electric vehicles with adaptive optimal fuzzy control
    Meng, Fanzi
    Zhang, Yu
    JOURNAL OF INTELLIGENT & FUZZY SYSTEMS, 2021, 41 (04) : 4929 - 4936
  • [47] Adaptive Power System for Managing Large Dynamic Loads
    Temkin, Deanna
    Boehmer, Tyler
    Billups, Amy
    IEEE TRANSACTIONS ON POWER DELIVERY, 2016, 31 (02) : 630 - 639
  • [48] Adaptive dynamic surface control of Buck power converters
    Yi, Li-Kui
    Zhao, Jun
    Shiyou Huagong Gaodeng Xuexiao Xuebao/Journal of Petrochemical Universities, 2007, 20 (03): : 57 - 59
  • [49] An Adaptive Dynamic Reference Control for Power Converters in a Microgrid
    Jayan, Vijesh
    Ghias, Amer M. Y. M.
    Guerrero, Josep M.
    Merabet, Adel
    IEEE TRANSACTIONS ON POWER ELECTRONICS, 2022, 37 (08) : 9164 - 9174
  • [50] Perspective-Adaptive Convolutions for Scene Parsing
    Zhang, Rui
    Tang, Sheng
    Zhang, Yongdong
    Li, Jintao
    Yan, Shuicheng
    IEEE TRANSACTIONS ON PATTERN ANALYSIS AND MACHINE INTELLIGENCE, 2020, 42 (04) : 909 - 924