sv-parser icon indicating copy to clipboard operation
sv-parser copied to clipboard

Compilation Speed

Open SeanMcLoughlin opened this issue 3 years ago • 1 comments

Compilation of this crate is extremely slow to the point of not being able to use an on-the-fly linter at all, making working with this crate difficult.

I've run some profiling using this unstable feature. Below is a screenshot of the report: Screenshot_20210428_210925

Running self-profiling shows that the longest sections of compilation time have to do with proc_macro expansion. For sv-parser-parser, this is definitely due to the macros for packrat parsing/tracing. For sv-parser-syntaxtree, it's due to all of the derive macros.

I know this is a difficult problem to solve, but I'm curious if there's been any thought on how to improve the compilation speeds of these crates.

SeanMcLoughlin avatar Apr 29 '21 04:04 SeanMcLoughlin

@SeanMcLoughlin Is this still a problem? Can you describe your usecase? You don't need to recompile sv-parser every time you want to run svlint.

DaveMcEwan avatar Jun 10 '22 08:06 DaveMcEwan