diff options
author | Bi, Dandan <dandan.bi@intel.com> | 2018-06-22 16:56:21 +0800 |
---|---|---|
committer | Liming Gao <liming.gao@intel.com> | 2018-06-26 15:36:59 +0800 |
commit | 67e9ab84ef042bd59c4297fdad7f6aece6b7bbca (patch) | |
tree | 9f47b68e792551e6608db4fadd9a82a964876aae /MdeModulePkg/Core/Pei | |
parent | f45dd2dd4f1d6fab4bb62bfd5f4e71cb7849897d (diff) | |
download | edk2-67e9ab84ef042bd59c4297fdad7f6aece6b7bbca.tar.gz edk2-67e9ab84ef042bd59c4297fdad7f6aece6b7bbca.tar.bz2 edk2-67e9ab84ef042bd59c4297fdad7f6aece6b7bbca.zip |
MdeModulePkg: Use new added Perf macros
Replace old Perf macros with the new added ones.
Cc: Liming Gao <liming.gao@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Eric Dong <eric.dong@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Dandan Bi <dandan.bi@intel.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'MdeModulePkg/Core/Pei')
-rw-r--r-- | MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c | 8 | ||||
-rw-r--r-- | MdeModulePkg/Core/Pei/PeiMain/PeiMain.c | 17 |
2 files changed, 12 insertions, 13 deletions
diff --git a/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c b/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c index 0ac3fdde6a..c4f629dadf 100644 --- a/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c +++ b/MdeModulePkg/Core/Pei/Dispatcher/Dispatcher.c @@ -1000,9 +1000,9 @@ PeiDispatcher ( //
PeimEntryPoint = (EFI_PEIM_ENTRY_POINT2)(UINTN)EntryPoint;
- PERF_START (PeimFileHandle, "PEIM", NULL, 0);
+ PERF_START_IMAGE_BEGIN (PeimFileHandle);
PeimEntryPoint(PeimFileHandle, (const EFI_PEI_SERVICES **) &Private->Ps);
- PERF_END (PeimFileHandle, "PEIM", NULL, 0);
+ PERF_START_IMAGE_END (PeimFileHandle);
}
//
@@ -1109,7 +1109,7 @@ PeiDispatcher ( // The PEIM has its dependencies satisfied, and its entry point
// has been found, so invoke it.
//
- PERF_START (PeimFileHandle, "PEIM", NULL, 0);
+ PERF_START_IMAGE_BEGIN (PeimFileHandle);
REPORT_STATUS_CODE_WITH_EXTENDED_DATA (
EFI_PROGRESS_CODE,
@@ -1145,7 +1145,7 @@ PeiDispatcher ( (VOID *)(&PeimFileHandle),
sizeof (PeimFileHandle)
);
- PERF_END (PeimFileHandle, "PEIM", NULL, 0);
+ PERF_START_IMAGE_END (PeimFileHandle);
}
}
diff --git a/MdeModulePkg/Core/Pei/PeiMain/PeiMain.c b/MdeModulePkg/Core/Pei/PeiMain/PeiMain.c index 775bf18ce9..a52e6f0201 100644 --- a/MdeModulePkg/Core/Pei/PeiMain/PeiMain.c +++ b/MdeModulePkg/Core/Pei/PeiMain/PeiMain.c @@ -352,18 +352,17 @@ PeiCore ( // Update performance measurements
//
if (OldCoreData == NULL) {
- PERF_START (NULL, "SEC", NULL, 1);
- PERF_END (NULL, "SEC", NULL, 0);
+ PERF_EVENT ("SEC"); // Means the end of SEC phase.
//
// If first pass, start performance measurement.
//
- PERF_START (NULL,"PEI", NULL, 0);
- PERF_START (NULL,"PreMem", NULL, 0);
+ PERF_CROSSMODULE_BEGIN ("PEI");
+ PERF_INMODULE_BEGIN ("PreMem");
} else {
- PERF_END (NULL,"PreMem", NULL, 0);
- PERF_START (NULL,"PostMem", NULL, 0);
+ PERF_INMODULE_END ("PreMem");
+ PERF_INMODULE_BEGIN ("PostMem");
}
//
@@ -411,7 +410,7 @@ PeiCore ( //
// Alert any listeners that there is permanent memory available
//
- PERF_START (NULL,"DisMem", NULL, 0);
+ PERF_INMODULE_BEGIN ("DisMem");
Status = PeiServicesInstallPpi (&mMemoryDiscoveredPpi);
//
@@ -419,7 +418,7 @@ PeiCore ( //
ProcessNotifyList (&PrivateData);
- PERF_END (NULL,"DisMem", NULL, 0);
+ PERF_INMODULE_END ("DisMem");
}
//
@@ -437,7 +436,7 @@ PeiCore ( //
// Measure PEI Core execution time.
//
- PERF_END (NULL, "PostMem", NULL, 0);
+ PERF_INMODULE_END ("PostMem");
//
// Lookup DXE IPL PPI
|