181 - New parser for Ovale scripts
The current parser in OvaleCompile.lua is using a string.gsub() technique to implement a script grammar, but there are problems with this approach:
- It constantly creates new Lua strings which causes a lot of overhead.
- It takes an indeterminate number of passes over the code text to parse and generate an AST.
- It's slow: all reports of the "script ran too long" error have been from the Compile() method; it needs to execute within 200ms at most.
The parser should be rewritten as an LR parser that can parse the code in a single pass.
| User | When | Change |
|---|---|---|
| jlam | Mar 14, 2013 at 14:41 UTC | Changed type from Defect to Enhancement |
| jlam | Jan 24, 2013 at 20:13 UTC | Changed type from Enhancement to Defect Changed priority from Low to Medium |
| jlam | Oct 25, 2012 at 21:30 UTC | Changed priority from High to Low |
| jlam | Oct 12, 2012 at 21:41 UTC | Changed status from Accepted to Started |
| jlam | Oct 12, 2012 at 21:40 UTC | Create |
- 3 comments
- 3 comments
- Reply
- #3
jlam Jan 24, 2013 at 20:14 UTC - 0 likesRaising this to a higher priority as current MoP users are apparently running into this problem again.
- Reply
- #2
jlam Oct 25, 2012 at 21:33 UTC - 0 likesDropping this ticket to low priority for now. Speed-ups have been achieved in an alternative way i the existing compile code by splitting the compilation into phases and avoiding a full compilation unless absolutely needed.
I will revisit this project at a later time.
- Reply
- #1
jlam Oct 15, 2012 at 03:00 UTC - 0 likesBlue post regarding Lua execution time:
This comment from Cyberolas in AceEvent ticket #296 has a suggested maximum execution time to avoid running into this error: