Skip to content

Commit

Permalink
Merge pull request #1402 from ESMCI/jgfouca/show_build_time_per_compo…
Browse files Browse the repository at this point in the history
…nent

Print time built per model
Test suite: code_checker
Test baseline:
Test namelist changes:
Test status: bit for bit

Fixes #893

User interface changes?: Output time per built component

Code review: @jedwards4b
  • Loading branch information
jedwards4b authored Apr 24, 2017
2 parents dc1a7ce + 9a1d1eb commit f8f0fec
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions scripts/lib/CIME/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,7 @@ def _build_model_thread(config_dir, compclass, caseroot, libroot, bldroot, incro
thread_bad_results, smp, compiler):
###############################################################################
logger.info("Building %s with output to %s"%(compclass, file_build))
t1 = time.time()
with open(file_build, "w") as fd:
stat = run_cmd("MODEL=%s SMP=%s %s/buildlib %s %s %s " %
(compclass, stringify_bool(smp), config_dir, caseroot, libroot, bldroot),
Expand All @@ -313,6 +314,8 @@ def _build_model_thread(config_dir, compclass, caseroot, libroot, bldroot, incro
for mod_file in glob.glob(os.path.join(bldroot, "*_[Cc][Oo][Mm][Pp]_*.mod")):
shutil.copy(mod_file, incroot)

t2 = time.time()
logger.info("%s built in %f seconds" % (compclass, (t2 - t1)))

###############################################################################
def _clean_impl(case, cleanlist, clean_all):
Expand Down

0 comments on commit f8f0fec

Please sign in to comment.