Moonbit developers are lying to you

12 pointsposted 5 months ago
by todsacerdoti

1 Comments

slanterns

5 months ago

I found the [picture](https://www.moonbitlang.cn/assets/images/image-1-41a71e74567...) in moonbit's [post](https://www.moonbitlang.cn/blog/moonbit-value-type) which claim it is 33% faster is so misleading. The real reason for the performance difference has nothing to do with the code shown in the picture or "value types," but is the [memory allocation](https://github.com/moonbit-community/benchmark-fft/blob/8768...) in recursive function in their Rust code, while Moonbit is a managed language whose runtime [uses mimalloc by default](https://github.com/moonbit-community/benchmark-fft/issues/10). By simply [switching](https://github.com/CrazyboyQCD/benchmark-fft/pull/1) Rust from system allocator to mimalloc as well, it'll just outperform Moonbit.