diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-11-21 17:49:58 +0100 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-11-21 20:47:02 +0100 |
commit | b74207976b1e6b4972bcfee9512b6847ebc1625e (patch) | |
tree | 5ce23979f45ae8ad9db8d10e3cdea92dab63d751 | |
parent | cbfcb2e9f1591407cd4d64c1a0237c4783fe2450 (diff) |
print out total time in emcc in debug mode
-rwxr-xr-x | emcc | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -713,6 +713,8 @@ try: minify_whitespace = closure # if closure is run, minify whitespace if opt_level <= 0: keep_debug = True # always keep debug in -O0 + if DEBUG: start_time = time.time() # done after parsing arguments, which might affect debug state + if closure: assert os.path.exists(shared.CLOSURE_COMPILER), 'emcc: fatal: Closure compiler (%s) does not exist' % shared.CLOSURE_COMPILER @@ -1240,6 +1242,8 @@ try: # copy final JS to output shutil.move(final, target) + if DEBUG: print >> sys.stderr, 'emcc: total time: %.2f seconds' % (time.time() - start_time) + finally: if not TEMP_DIR: try: |