builder: measure msvc execution too

pull/5922/head
Delyan Angelov 2020-07-21 19:45:50 +03:00
parent 14fd7d93ca
commit 8b930b4888
1 changed files with 4 additions and 0 deletions

View File

@ -1,6 +1,7 @@
module builder module builder
import os import os
import time
import v.pref import v.pref
import v.cflag import v.cflag
@ -302,11 +303,14 @@ pub fn (mut v Builder) cc_msvc() {
println('==========\n') println('==========\n')
} }
// println('$cmd') // println('$cmd')
ticks := time.ticks()
res := os.exec(cmd) or { res := os.exec(cmd) or {
println(err) println(err)
verror('msvc error') verror('msvc error')
return return
} }
diff := time.ticks() - ticks
v.timing_message('C msvc: ${diff}ms')
if res.exit_code != 0 { if res.exit_code != 0 {
verror(res.output) verror(res.output)
} }