21 votes 21 votes Which of the following is the most powerful parsing method? LL (1) Canonical LR SLR LALR Compiler Design gate1999 compiler-design parsing easy + – Kathleen asked Sep 23, 2014 Kathleen 23.4k views answer comment Share Follow See all 2 Comments See all 2 2 Comments reply ektan commented Aug 19, 2018 reply Follow Share Though it's not included in the question, where would operator precedence parser fit in the terms of power ? 0 votes 0 votes Pranavpurkar commented Nov 28, 2022 reply Follow Share ektan An operator-precedence parser is a simple shift-reduce parser that is capable of parsing a subset of LR(1) grammars. More precisely, the operator-precedence parser can parse all LR(1) grammars where two consecutive nonterminals and epsilon never appear in the right-hand side of any rule. https://en.wikipedia.org/wiki/Operator-precedence_parser#:~:text=An%20operator%2Dprecedence%20parser%20is,of%20LR(1)%20grammars. 0 votes 0 votes Please log in or register to add a comment.
Best answer 31 votes 31 votes Canonical LR is most powerful method LR > LALR > SLR so ans is B Pooja Palod answered Sep 14, 2015 • edited Apr 28, 2021 by Lakshman Bhaiya Pooja Palod comment Share Follow See all 2 Comments See all 2 2 Comments reply talha hashim commented Jul 18, 2018 reply Follow Share nice mam 0 votes 0 votes Thadymademe commented Oct 22, 2022 reply Follow Share @Sachin Mittal 1 Sir can we fit in operator precedence grammar in the diagram?? 0 votes 0 votes Please log in or register to add a comment.
5 votes 5 votes power of PArser is derived on the basis of NO. of language parsed.... CLR could parsed all the language which could parsed by other..... hs_yadav answered Sep 4, 2017 hs_yadav comment Share Follow See all 8 Comments See all 8 8 Comments reply Show 5 previous comments Venkat Sai commented Jan 10, 2018 reply Follow Share @srestha LR(1) parsers can parse every language in DCFL set because DCFL are not inherently unambiguos i.e they are gaurenteed to exist atleast one unambiguous grammar that derives them . there is one to one correspondence between the number of DCFL languages and the LR(1)( cannonical LR) parsers but the pther parsers SLR LALR LR(0) donot gaurentee to parse even the unambiguous versions of the grammers corresponding to the DCFL hence the power increases as SHOWN ABOVE 1 votes 1 votes srestha commented Jan 10, 2018 reply Follow Share ok :) and what is difference in terms of grammar and in terms of language? 0 votes 0 votes Venkat Sai commented Jan 10, 2018 reply Follow Share What she meant was Parser always corresponds to a grammer...for every grammer u will have a corresponding language a language can have many grammars but for every DCFL there is gaurenteed to exist one unambiguos one .. we should not relate a language to the parser as it will be designed based on the grammer rules and its not EXACTLY correct 0 votes 0 votes Please log in or register to add a comment.
4 votes 4 votes Among the all parsing techniques Canonical LR i.e. CLR is MOST powerful method. We can also show the order of method in increasing power as below. LL(1) < SLR < LALR < CLR Rohit01 answered Sep 17, 2015 Rohit01 comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes CLR is more powerful. YOGESH PATEL 1 answered Sep 4, 2017 YOGESH PATEL 1 comment Share Follow See all 0 reply Please log in or register to add a comment.