Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I'm surprised to see it's that much faster than SWC. Does anyone have any general details on how that performance is achieved?


One thing worth noting: beyond raw parse speed, oxc's AST is designed to be allocation-friendly with arena allocation. SWC uses a more traditional approach. In practice this means oxc scales better when you're doing multiple passes (lint + transform + codegen) on the same file because you avoid a ton of intermediate allocations.

We switched a CI pipeline from babel to SWC last year and got roughly 8x improvement. Tried oxc's transformer more recently on the same codebase and it shaved off another 30-40% on top of SWC. The wins compound when you have thousands of files and the GC pressure from all those AST nodes starts to matter.


They wrote a post (https://oxc.rs/docs/learn/performance) but it doesn't include direct comparisons to SWC.


Their main page says 3x fast than SWC


Yeah, but not how their implementation techniques differ from SWC's to produce those results.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: