src/share/vm/utilities/elfSymbolTable.hpp
Print this page
rev 5729 : 8019929: PPC64 (part 107): Extend ELF-decoder to support PPC64 function descriptor tables
@@ -43,11 +43,15 @@
public:
ElfSymbolTable(FILE* file, Elf_Shdr shdr);
~ElfSymbolTable();
// search the symbol that is nearest to the specified address.
+#if defined(PPC64)
+ bool lookup(address addr, int* stringtableIndex, int* posIndex, int* offset, ElfFuncDescTable* funcDescTable);
+#else
bool lookup(address addr, int* stringtableIndex, int* posIndex, int* offset);
+#endif
NullDecoder::decoder_status get_status() { return m_status; };
protected:
ElfSymbolTable* m_next;
@@ -63,8 +67,37 @@
Elf_Shdr m_shdr;
NullDecoder::decoder_status m_status;
};
+#if defined(PPC64)
+
+class ElfFuncDescTable: public CHeapObj<mtInternal> {
+ friend class ElfFile;
+ public:
+ ElfFuncDescTable(FILE* file, Elf_Shdr shdr);
+ ~ElfFuncDescTable();
+
+ // return the function address for the function descriptor at 'index' or NULL on error
+ address lookup(Elf_Word index);
+
+ NullDecoder::decoder_status get_status() { return m_status; };
+
+ protected:
+ // holds the complete function descriptor section if
+ // we can allocate enough memory
+ address* m_funcDescs;
+
+ // file contains string table
+ FILE* m_file;
+
+ // section header
+ Elf_Shdr m_shdr;
+
+ NullDecoder::decoder_status m_status;
+};
+
+#endif
+
#endif // _WINDOWS and _APPLE
#endif // SHARE_VM_UTILITIES_ELF_SYMBOL_TABLE_HPP