Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality. Learn more →
Top 6 Rust Compiler Projects
-
InfluxDB
Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
Project mention: Why Split Lexing and Parsing into Two Separate Phases? | news.ycombinator.com | 2023-05-04Well, my personal experience was in the opposite direction actually.
I used to use combinators-based approach without Lex/Syn separation (aka PEGs) for a long time. But then I came up to understanding that the separation approach is actually better in performance. And also that working and debugging of the Token sequences while writing parser manually is just more handy (at least for me).
But this is my personal experience of course. I do believe too that it all depends on the goal, and parsers micro-optimizations is not that much critical in many cases, and that combinators approach actually works quite well too.
As of Nom, I can say that it works quite well. But I think that the it's performance gains stem from the fact that Rust is a systems-based PL, and it optimizes function combinations just better than, let say, JavaScript or Python.
In my incremental parsers library Lady Deirdre I utilize Lex/Syn separation, and the LL(1) recursive-descend parsing, and it shows much better performance than in Tree-Sitter at least on relatively big files [1].
[1] https://github.com/Eliah-Lakhin/lady-deirdre/tree/master/wor...
Indeed this is the problem I'm having with my proc macro crates lexgen and parsegen. In the case of lexgen, the proc macro is actually quite fast for realistic inputs, but the compiler spends a lot of time checking and generated code with cargo check (which I suspect rust-analyzer also uses). In the case of parsegen the proc macro does some analyses and takes some time. In both cases I have to split my proc macro code (not the proc macros, the code that uses the proc macros) to separate crates so that they won't be recompiler/re-analyzed as I work on the code.
Rust Compilers related posts
- Can one use lambda calculus as an IR?
- How are macros dealt with for incremental compilation?
- Targetting C
- If you're not using a lexer generator for your compiler, why?
- A fully-featured lexer generator for Rust, implemented as a proc macro
- ClojuRust – Clojure in Rust
- Does such a language already exist ("Rust--")?
-
A note from our sponsor - InfluxDB
www.influxdata.com | 25 Apr 2024
Index
What are some of the best open-source Compiler projects in Rust? This list will help you:
Project | Stars | |
---|---|---|
1 | micro-mitten | 531 |
2 | crafting-interpreters-rs | 215 |
3 | lua-in-rust | 97 |
4 | lady-deirdre | 70 |
5 | lexgen | 60 |
6 | clojurust | 48 |
Sponsored