]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Ecc/EccMain.py
BaseTools/Ecc: Replace deprecated function time.clock()
[mirror_edk2.git] / BaseTools / Source / Python / Ecc / EccMain.py
index 560bb9fd7a314f7c84fed97acd57d87bef7b9086..72edbea3b8831aae38f99ea2e5fbd81db93023a5 100644 (file)
@@ -2,6 +2,7 @@
 # This file is used to be the main entrance of ECC tool\r
 #\r
 # Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) Microsoft Corporation.<BR>\r
 # SPDX-License-Identifier: BSD-2-Clause-Patent\r
 #\r
 \r
@@ -406,9 +407,9 @@ if __name__ == '__main__':
     EdkLogger.Initialize()\r
     EdkLogger.IsRaiseError = False\r
 \r
-    StartTime = time.clock()\r
+    StartTime = time.perf_counter()\r
     Ecc = Ecc()\r
-    FinishTime = time.clock()\r
+    FinishTime = time.perf_counter()\r
 \r
     BuildDuration = time.strftime("%M:%S", time.gmtime(int(round(FinishTime - StartTime))))\r
     EdkLogger.quiet("\n%s [%s]" % (time.strftime("%H:%M:%S, %b.%d %Y", time.localtime()), BuildDuration))\r