ruststep icon indicating copy to clipboard operation
ruststep copied to clipboard

Build time profiling using `-Z timings`

Open termoshtt opened this issue 4 years ago • 1 comments

cargo has -Z timings feature in nightly. It shows how long compile spent times like following:

   Completed espr v0.1.0 lib (test) in 6.1s
   Completed ruststep v0.1.0 lib (test) in 10.1s
   Completed ruststep v0.1.0 in 18.7s
   Completed espr-derive v0.1.0 lib (test) in 0.5s
   Completed ruststep-derive v0.1.0 test "try_build" (test) in 1.4s
   Completed ruststep-derive v0.1.0 lib (test) in 2.3s
   Completed ruststep v0.1.0 test "abc_dataset" (test) in 3.4s
   Completed ruststep v0.1.0 test "enum_deserialize" (test) in 3.5s
   Completed ruststep v0.1.0 test "simple" (test) in 3.5s
   Completed ruststep v0.1.0 test "list" (test) in 3.6s
   Completed ruststep v0.1.0 test "any_deserialize" (test) in 3.7s

https://doc.rust-lang.org/cargo/reference/unstable.html#timings

termoshtt avatar Nov 22 '21 08:11 termoshtt

cargo build --timings

has been stabilized in 1.60.0 https://blog.rust-lang.org/2022/04/07/Rust-1.60.0.html#cargo---timings

termoshtt avatar Apr 20 '22 07:04 termoshtt