From 1ac8ea0859d91d86c23b5574bd0474887df1b96e Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Thu, 6 Mar 2014 11:39:43 -0800 Subject: show logging about preload/pre-main time even without a main --- src/postamble.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/postamble.js') diff --git a/src/postamble.js b/src/postamble.js index 603b330c..b90049bc 100644 --- a/src/postamble.js +++ b/src/postamble.js @@ -48,10 +48,6 @@ Module['callMain'] = Module.callMain = function callMain(args) { args = args || []; - if (ENVIRONMENT_IS_WEB && preloadStartTime !== null) { - Module.printErr('preload time: ' + (Date.now() - preloadStartTime) + ' ms'); - } - ensureInitRuntime(); var argc = args.length+1; @@ -130,6 +126,10 @@ function run(args) { preMain(); + if (ENVIRONMENT_IS_WEB && preloadStartTime !== null) { + Module.printErr('pre-main prep time: ' + (Date.now() - preloadStartTime) + ' ms'); + } + if (Module['_main'] && shouldRunNow) { Module['callMain'](args); } -- cgit v1.2.3-18-g5258