Rust 1.2 稳定版发布,Mozilla 编程语言

jopen 9年前
 

Rust 1.2 稳定版发布了,该版本对编译器进行改进,包含两方面主要的性能提升:

  • An across-the-board improvementto real-world compiler performance. Representative crates include hyper (compiles 1.16x faster), html5ever (1.62x faster), regex (1.32x faster) and rust-encoding (1.35x faster). You can explore some of this performance data at Nick Cameron’s preliminary tracking site , using dates 2015-05-15 to 2015-06-25.

  • Parallel codegenis now working , and produces a 33% speedup when bootstrapping on a 4 core machine. Parallel codegen is particularly useful for debug builds, since it prevents some optimizations; but it can also be used with optimizations as an effective-O1flag. It can be activated by passing-C codegen-units=Ntorustc, whereNis the desired number of threads.

Cargo 的性能也得到提升:

  • Builds that do not require any recompilation (“no-op builds”) for large projects are much faster: for Servo, build time went from 5 seconds to 0.5 seconds.

  • Cargo now supports shared target directories that cache dependencies across multiple packages, which results in significant build-time reduction for complex projects.

同时 Rust 1.2 支持 MSVC (Microsoft Visual C) 工具链。在语言方面 Rust 1.2 完成了 dynamically-sized type (DST) 工作。详细介绍请看 发行说明

Rust 是 Mozilla 的一个新的编程语言,由web语言的领军人物Brendan Eich(js之父),Dave Herman以及Mozilla公司的Graydon Hoare 合力开发。