| OLD | NEW |
| 1 //===- subzero/src/IceELFObjectWriter.h - ELF object writer -----*- C++ -*-===// | 1 //===- subzero/src/IceELFObjectWriter.h - ELF object writer -----*- C++ -*-===// |
| 2 // | 2 // |
| 3 // The Subzero Code Generator | 3 // The Subzero Code Generator |
| 4 // | 4 // |
| 5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
| 6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
| 7 // | 7 // |
| 8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
| 9 /// | 9 /// |
| 10 /// \file | 10 /// \file |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 /// Copy the text fixups for use after all functions are written. | 69 /// Copy the text fixups for use after all functions are written. |
| 70 /// The text buffer and fixups are extracted from the Assembler object. | 70 /// The text buffer and fixups are extracted from the Assembler object. |
| 71 void writeFunctionCode(const IceString &FuncName, bool IsInternal, | 71 void writeFunctionCode(const IceString &FuncName, bool IsInternal, |
| 72 const Assembler *Asm); | 72 const Assembler *Asm); |
| 73 | 73 |
| 74 /// Queries the GlobalContext for constant pools of the given type | 74 /// Queries the GlobalContext for constant pools of the given type |
| 75 /// and writes out read-only data sections for those constants. This also | 75 /// and writes out read-only data sections for those constants. This also |
| 76 /// fills the symbol table with labels for each constant pool entry. | 76 /// fills the symbol table with labels for each constant pool entry. |
| 77 template <typename ConstType> void writeConstantPool(Type Ty); | 77 template <typename ConstType> void writeConstantPool(Type Ty); |
| 78 | 78 |
| 79 /// Write a jump table and register fixups for the target addresses. |
| 80 void writeJumpTable(const JumpTableData &JT, FixupKind RelocationKind); |
| 81 |
| 79 /// Populate the symbol table with a list of external/undefined symbols. | 82 /// Populate the symbol table with a list of external/undefined symbols. |
| 80 void setUndefinedSyms(const ConstantList &UndefSyms); | 83 void setUndefinedSyms(const ConstantList &UndefSyms); |
| 81 | 84 |
| 82 /// Do final layout and write out the rest of the object file. | 85 /// Do final layout and write out the rest of the object file. |
| 83 /// Finally, patch up the initial ELF header with the final info. | 86 /// Finally, patch up the initial ELF header with the final info. |
| 84 void writeNonUserSections(); | 87 void writeNonUserSections(); |
| 85 | 88 |
| 86 /// Which type of ELF section a global variable initializer belongs to. | 89 /// Which type of ELF section a global variable initializer belongs to. |
| 87 /// This is used as an array index so should start at 0 and be contiguous. | 90 /// This is used as an array index so should start at 0 and be contiguous. |
| 88 enum SectionType { ROData = 0, Data, BSS, NumSectionTypes }; | 91 enum SectionType { ROData = 0, Data, BSS, NumSectionTypes }; |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 | 164 |
| 162 /// Write the ELF file header with the given information about sections. | 165 /// Write the ELF file header with the given information about sections. |
| 163 template <bool IsELF64> | 166 template <bool IsELF64> |
| 164 void writeELFHeaderInternal(Elf64_Off SectionHeaderOffset, | 167 void writeELFHeaderInternal(Elf64_Off SectionHeaderOffset, |
| 165 SizeT SectHeaderStrIndex, SizeT NumSections); | 168 SizeT SectHeaderStrIndex, SizeT NumSections); |
| 166 }; | 169 }; |
| 167 | 170 |
| 168 } // end of namespace Ice | 171 } // end of namespace Ice |
| 169 | 172 |
| 170 #endif // SUBZERO_SRC_ICEELFOBJECTWRITER_H | 173 #endif // SUBZERO_SRC_ICEELFOBJECTWRITER_H |
| OLD | NEW |