#include "Literals.h"\r
#include "DpInternal.h"\r
\r
-/** Gather and print ALL Profiling Records.\r
- *\r
- * Displays all "interesting" Profile measurements in order.\r
- * The number of records displayed is controlled by:\r
- * - records with a duration less than mInterestThreshold microseconds are not displayed.\r
- * - No more than Limit records are displayed. A Limit of zero will not limit the output.\r
- * - If the ExcludeFlag is TRUE, records matching entries in the CumData array are not\r
- * displayed.\r
- *\r
- * @pre The mInterestThreshold global variable is set to the shortest duration to be printed.\r
- * The mGaugeString and mUnicodeToken global arrays are used for temporary string storage.\r
- * They must not be in use by a calling function.\r
- *\r
- * @param[in] Limit The number of records to print. Zero is ALL.\r
- * @param[in] ExcludeFlag TRUE to exclude individual Cumulative items from display.\r
- *\r
+/** \r
+ Gather and print ALL Profiling Records.\r
+ \r
+ Displays all "interesting" Profile measurements in order.\r
+ The number of records displayed is controlled by:\r
+ - records with a duration less than mInterestThreshold microseconds are not displayed.\r
+ - No more than Limit records are displayed. A Limit of zero will not limit the output.\r
+ - If the ExcludeFlag is TRUE, records matching entries in the CumData array are not\r
+ displayed.\r
+ \r
+ @pre The mInterestThreshold global variable is set to the shortest duration to be printed.\r
+ The mGaugeString and mUnicodeToken global arrays are used for temporary string storage.\r
+ They must not be in use by a calling function.\r
+ \r
+ @param[in] Limit The number of records to print. Zero is ALL.\r
+ @param[in] ExcludeFlag TRUE to exclude individual Cumulative items from display.\r
+ \r
**/\r
VOID\r
DumpAllProfile(\r
)\r
{\r
EFI_STRING StringPtr;\r
+ EFI_STRING StringPtrUnknown;\r
\r
+ StringPtrUnknown = HiiGetString (gHiiHandle, STRING_TOKEN (STR_ALIT_UNKNOWN), NULL); \r
StringPtr = HiiGetString (gHiiHandle, STRING_TOKEN (STR_DP_SECTION_PROFILE), NULL);\r
+\r
PrintToken( STRING_TOKEN (STR_DP_SECTION_HEADER),\r
- (StringPtr == NULL) ? ALit_UNKNOWN: StringPtr);\r
+ (StringPtr == NULL) ? StringPtrUnknown: StringPtr);\r
+ FreePool (StringPtr);\r
+ FreePool (StringPtrUnknown);\r
return;\r
}\r
\r
-/** Gather and print Raw Profile Records.\r
- *\r
- * All Profile measurements with a duration greater than or equal to\r
- * mInterestThreshold are printed without interpretation.\r
- *\r
- * The number of records displayed is controlled by:\r
- * - records with a duration less than mInterestThreshold microseconds are not displayed.\r
- * - No more than Limit records are displayed. A Limit of zero will not limit the output.\r
- * - If the ExcludeFlag is TRUE, records matching entries in the CumData array are not\r
- * displayed.\r
- *\r
- * @pre The mInterestThreshold global variable is set to the shortest duration to be printed.\r
- *\r
- * @param[in] Limit The number of records to print. Zero is ALL.\r
- * @param[in] ExcludeFlag TRUE to exclude individual Cumulative items from display.\r
- *\r
+/** \r
+ Gather and print Raw Profile Records.\r
+ \r
+ All Profile measurements with a duration greater than or equal to\r
+ mInterestThreshold are printed without interpretation.\r
+ \r
+ The number of records displayed is controlled by:\r
+ - records with a duration less than mInterestThreshold microseconds are not displayed.\r
+ - No more than Limit records are displayed. A Limit of zero will not limit the output.\r
+ - If the ExcludeFlag is TRUE, records matching entries in the CumData array are not\r
+ displayed.\r
+ \r
+ @pre The mInterestThreshold global variable is set to the shortest duration to be printed.\r
+ \r
+ @param[in] Limit The number of records to print. Zero is ALL.\r
+ @param[in] ExcludeFlag TRUE to exclude individual Cumulative items from display.\r
+ \r
**/\r
VOID\r
DumpRawProfile(\r
)\r
{\r
EFI_STRING StringPtr;\r
+ EFI_STRING StringPtrUnknown;\r
\r
+ StringPtrUnknown = HiiGetString (gHiiHandle, STRING_TOKEN (STR_ALIT_UNKNOWN), NULL); \r
StringPtr = HiiGetString (gHiiHandle, STRING_TOKEN (STR_DP_SECTION_RAWPROFILE), NULL);\r
PrintToken( STRING_TOKEN (STR_DP_SECTION_HEADER),\r
- (StringPtr == NULL) ? ALit_UNKNOWN: StringPtr);\r
+ (StringPtr == NULL) ? StringPtrUnknown: StringPtr);\r
+ FreePool (StringPtr);\r
+ FreePool (StringPtrUnknown);\r
return;\r
}\r