/** @file\r
Processor or Compiler specific defines and types for Intel Itanium(TM).\r
\r
- Copyright (c) 2006, Intel Corporation\r
+ Copyright (c) 2006, Intel Corporation<BR>\r
All rights reserved. This program and the accompanying materials\r
are licensed and made available under the terms and conditions of the BSD License\r
which accompanies this distribution. The full text of the license may be found at\r
\r
\r
//\r
-// Make sure we are useing the correct packing rules per EFI specification\r
+// Make sure we are using the correct packing rules per EFI specification\r
//\r
#pragma pack()\r
\r
#pragma warning ( disable : 4505 )\r
\r
//\r
-// This warning is caused by empty (after preprocessing) souce file. For precompiled header only.\r
+// This warning is caused by empty (after preprocessing) source file. For precompiled header only.\r
//\r
#pragma warning ( disable : 4206 )\r
\r
\r
#if _MSC_EXTENSIONS\r
//\r
- // use Microsoft C complier dependent interger width types\r
+ // use Microsoft C complier dependent integer width types\r
//\r
typedef unsigned __int64 UINT64;\r
typedef __int64 INT64;\r
//\r
// Modifier to ensure that all protocol member functions and EFI intrinsics\r
// use the correct C calling convention. All protocol member functions and\r
-// EFI intrinsics are required to modify thier member functions with EFIAPI.\r
+// EFI intrinsics are required to modify their member functions with EFIAPI.\r
//\r
#if _MSC_EXTENSIONS\r
//\r
UINT64 r11;\r
} PAL_CALL_RETURN;\r
\r
-#define FUNCTION_ENTRY_POINT(p) (((EFI_PLABEL *)(p))->EntryPoint)\r
+/**\r
+ Return the pointer to the first instruction of a function given a function pointer.\r
+ For Itanium CPUs, all function calls are made through a PLABEL, so a pointer to a function \r
+ is actually a pointer to a PLABEL. The pointer to the first instruction of the function \r
+ is contained within the PLABEL. This macro may be used to retrieve a pointer to the first \r
+ instruction of a function independent of the CPU architecture being used. This is very \r
+ useful when printing function addresses through DEBUG() macros.\r
+ \r
+ @param FunctionPointer A pointer to a function.\r
+\r
+ @return The pointer to the first instruction of a function given a function pointer.\r
+ \r
+**/\r
+#define FUNCTION_ENTRY_POINT(FunctionPointer) (((EFI_PLABEL *)(FunctionPointer))->EntryPoint)\r
\r
#endif\r
\r