You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found one serious problem of SWC ES AST, which wastes enormous amount of memory / performance.
The problem is that, Expr was needlessly 96 bytes. I optimized it by boxing some large variants, but while refactoring in the past, AssignExpr -> AssignTarget got too big without being caught in a code review.
(Sadly, static assertion was disabled due to a layout size bug of old rustc)
// Memory layout depends on the version of rustc.
// #[cfg(target_pointer_width = "64")]
// assert_eq_size!(Expr, [u8; 80]);
I'll work on this today.
The text was updated successfully, but these errors were encountered:
Allocates memory in heap will cost a lot of performance, if we can new ast in bumpalo it's will improve amount of perf.
It's so said that it may import a big break change.
Allocates memory in heap will cost a lot of performance, if we can new ast in bumpalo it's will improve amount of perf. It's so said that it may import a big break change.
Hardfist: i done profile before and it turns out that mimalloc does lots of optimization like bump allocator,so mimalloc improve swc allocator perfromance a lot but little to oxc
I found one serious problem of SWC ES AST, which wastes enormous amount of memory / performance.
The problem is that, Expr was needlessly 96 bytes. I optimized it by boxing some large variants, but while refactoring in the past, AssignExpr -> AssignTarget got too big without being caught in a code review.
(Sadly, static assertion was disabled due to a layout size bug of old rustc)
// Memory layout depends on the version of rustc.
// #[cfg(target_pointer_width = "64")]
// assert_eq_size!(Expr, [u8; 80]);
I'll work on this today.
The text was updated successfully, but these errors were encountered: