Hi,

Thanks.

Can you attach the performance comparison?

Best,
-----------------------------------
Xiangdong Huang
School of Software, Tsinghua University

 黄向东
清华大学 软件学院


康愈圆 <ky...@mails.tsinghua.edu.cn> 于2019年9月1日周日 下午9:03写道:

> Hi,
>
> PR#336 is related to issue IOTDB-190.
>
> ANTLR v4 has some advanteges over ANTLR v3:
>
> 1. ANTLRv4 uses visitor and listener mechanism,which allows the grammer
> definition independent from programming language (e.g. Java).
> So it is much easier to maintain.
>
> 2. In Antlr v3, developers explicitly defines the structure of the tree to
> build using operator '->'. However, Antlr v4 hides the tree structure
> from developers, which simplifies grammer definition and increases the
> code readability.
>
> 3. ANTLR v3’s LL(* ) parsing strategy is weaker than v4’s ALL(* ), so v3
> sometimes relied on backtracking to properly parse input phrases.
>
> 4. ANTLR v3 cannot handle left-recursive rules, while ANTLR v4 can now
> handle direct left recursion. Therefore, ANTLR v4 can handle more
>  grammer rules.
>
> 5. ANTLR v4 works faster than ANTLR v3.
>
> Now, I'm working on this issue.
>
> ---------------------------------------------
> Yuyuan KANG
> School of Software, Tsinghua University
>
> 康愈圆
> 清华大学 软件学院
>
> 在2019-09-01 23:58:55,Christofer Dutz<christofer.d...@c-ware.de>写道:
> > Hi all,
> >
> > let me give some points I know from the past:
> > - With Anlr4 grammars you seem to be able to express more rules
> > - Antlr4 parsers appear to be a lot faster than Anltr3 parsers
> > - Antlr4 grammars are easier to read (at least this is my impression)
> > - Implementing Parsers/Compilers with an Antlr4 grammar is a lot easier
> as there is no longer a mixture of Antlr3 and Java code (the grammar
> contains absolutely no code and all is implemented by overriding "enterXYZ"
> and "exitXYZ" methods).
> >
> > So I was happy when reading that you're switching to antlr4.
> >
> > Chrus
> >
> >
> > Am 01.09.19, 17:38 schrieb "Xiangdong Huang" <saint...@gmail.com>:
> >
> >     Hi,
> >
> >     Let's discuss about PR#336..
> >
> >     1. Which issue the PR is for.
> >
> >     2. As you (@Ring-K) upgrade the parser from antlr 3  to antlr 4, what
> >     benefit can we get?
> >
> >     Best,
> >     -----------------------------------
> >     Xiangdong Huang
> >     School of Software, Tsinghua University
> >
> >      黄向东
> >     清华大学 软件学院
> >
> >
>
>

Reply via email to