Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

/users/u3/mtikir/PMaCInstrumentor_v1601/include/defines/LoaderSection.d

Go to the documentation of this file.
00001 /*
00002 ##################################################################
00003 Table 15. Loader Section Header Structure (Defined in loader.h) XCOFF32     XCOFF64     Name     Description
00004 Offset     Length     Offset     Length
00005 0     4     0     4     l_version     Loader section version number
00006 4     4     4     4     l_nsyms     Number of symbol table entries
00007 8     4     8     4     l_nreloc     Number of relocation table entries
00008 12     4     12     4     l_istlen     Length of import file ID string table
00009 16     4     16     4     l_nimpid     Number of import file IDs
00010 20     4     24     8     l_impoff+     Offset to start of import file IDs
00011 24     4     20     4     l_stlen+     Length of string table
00012 28     4     32     8     l_stoff+     Offset to start of string table
00013 N/A     40     8     l_symoff     Offset to start of symbol table
00014 N/A     48     8     l_rldoff     Offset to start of relocation entries
00015 +Use "32" or "64" suffix when __XCOFF_HYBRID__ is defined.
00016 ##################################################################
00017 Table 16. Loader Section Symbol Table Entry Structure XCOFF32     XCOFF64     Name     Description
00018 Offset     Length     Offset     Length
00019 0     8     0    0     l_name+     Symbol name or byte offset into string table
00020 0     4     0    0     l_zeroes+     Zero indicates symbol name is referenced from l_offset
00021 4     4     8     4     l_offset+     Byte offset into string table of symbol name
00022 8     4     0     8     l_value+     Address field
00023 12     2     12     2     l_scnum     Section number containing symbol
00024 14     1     14     1     l_smtype     Symbol type, export, import flags
00025 15     1     15     1     l_smclas     Symbol storage class
00026 16     4     16     4     l_ifile     Import file ID; ordinal of import file IDs
00027 20     4     20     4     l_parm     Parameter type-check field
00028 +Use "32" or "64" suffix when __XCOFF_HYBRID__ is defined.
00029 ##################################################################
00030 Table 17. Loader Section Relocation Table Entry Structure XCOFF32     XCOFF64     Name     Description
00031 Offset     Length     Offset     Length
00032 0     4     0     8     l_vaddr+     Address field
00033 4     4     12     4     l_symndx+     Loader section symbol table index of referenced item
00034 8     2     8     2     l_rtype     Relocation type
00035 10     2     10     2     l_rsecnm     File section number being relocated
00036 +Use "32" or "64" suffix when __XCOFF_HYBRID__ is defined.
00037 ##################################################################
00038 */
00039 
00040 #define LOADERHEADER_MACROS_BASIS(__str)  \
00041         GET_FIELD_BASIS(uint32_t,l_version); \
00042         GET_FIELD_BASIS(uint32_t,l_nsyms); \
00043         GET_FIELD_BASIS(uint32_t,l_nreloc); \
00044         GET_FIELD_BASIS(uint32_t,l_istlen); \
00045         GET_FIELD_BASIS(uint32_t,l_nimpid); \
00046         GET_FIELD_BASIS(uint64_t,l_impoff); \
00047         GET_FIELD_BASIS(uint32_t,l_stlen); \
00048         GET_FIELD_BASIS(uint64_t,l_stoff); \
00049         GET_FIELD_BASIS(uint64_t,l_symoff); \
00050         GET_FIELD_BASIS(uint64_t,l_rldoff); \
00051 
00053 #define LOADERHEADER_MACROS_CLASS(__str)  \
00054         GET_FIELD_CLASS(uint32_t,l_version); \
00055         GET_FIELD_CLASS(uint32_t,l_nsyms); \
00056         GET_FIELD_CLASS(uint32_t,l_nreloc); \
00057         GET_FIELD_CLASS(uint32_t,l_istlen); \
00058         GET_FIELD_CLASS(uint32_t,l_nimpid); \
00059         GET_FIELD_CLASS(uint64_t,l_impoff); \
00060         GET_FIELD_CLASS(uint32_t,l_stlen); \
00061         GET_FIELD_CLASS(uint64_t,l_stoff); \
00062 
00064 #define LOADERSYMBOL_MACROS_BASIS(__str)  \
00065         GET_FIELD_BASIS(char*,l_name); \
00066         GET_FIELD_BASIS(uint32_t,l_zeroes); \
00067         GET_FIELD_BASIS(uint32_t,l_offset); \
00068         GET_FIELD_BASIS(uint64_t,l_value); \
00069         GET_FIELD_BASIS(uint16_t,l_scnum); \
00070         GET_FIELD_BASIS(uint8_t,l_smtype); \
00071         GET_FIELD_BASIS(uint8_t,l_smclas); \
00072         GET_FIELD_BASIS(uint32_t,l_ifile); \
00073         GET_FIELD_BASIS(uint32_t,l_parm); \
00074 
00076 #define LOADERSYMBOL_MACROS_CLASS(__str)  \
00077         GET_FIELD_CLASS(uint32_t,l_offset); \
00078         GET_FIELD_CLASS(uint64_t,l_value); \
00079         GET_FIELD_CLASS(uint16_t,l_scnum); \
00080         GET_FIELD_CLASS(uint8_t,l_smtype); \
00081         GET_FIELD_CLASS(uint8_t,l_smclas); \
00082         GET_FIELD_CLASS(uint32_t,l_ifile); \
00083         GET_FIELD_CLASS(uint32_t,l_parm); \
00084 
00086 #define LOADERRELOC_MACROS_BASIS(__str)  \
00087         GET_FIELD_BASIS(uint64_t,l_vaddr); \
00088         GET_FIELD_BASIS(uint32_t,l_symndx); \
00089         GET_FIELD_BASIS(uint16_t,l_rtype); \
00090         GET_FIELD_BASIS(uint16_t,l_rsecnm); \
00091 
00093 #define LOADERRELOC_MACROS_CLASS(__str)  \
00094         GET_FIELD_CLASS(uint64_t,l_vaddr); \
00095         GET_FIELD_CLASS(uint32_t,l_symndx); \
00096         GET_FIELD_CLASS(uint16_t,l_rtype); \
00097         GET_FIELD_CLASS(uint16_t,l_rsecnm); \
00098 

Generated on Mon Jan 28 11:08:31 2008 for PMaCInstrumentor by doxygen 1.3.5