Tweak to fix spelling and grammar in comment.
[oota-llvm.git] / include / llvm / MC / ELFObjectWriter.h
1 //===-- llvm/MC/ELFObjectWriter.h - ELF File Writer ---------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9
10 #ifndef LLVM_MC_ELFOBJECTWRITER_H
11 #define LLVM_MC_ELFOBJECTWRITER_H
12
13 #include "llvm/ADT/Triple.h"
14 #include "llvm/MC/MCObjectWriter.h"
15 #include "llvm/Support/raw_ostream.h"
16 #include <cassert>
17
18 namespace llvm {
19 class MCAsmFixup;
20 class MCAssembler;
21 class MCFragment;
22 class MCValue;
23 class raw_ostream;
24
25 class ELFObjectWriter : public MCObjectWriter {
26   void *Impl;
27
28 public:
29   ELFObjectWriter(raw_ostream &OS, bool Is64Bit, Triple::OSType OSType, 
30                   uint16_t EMachine, bool IsLittleEndian = true,
31                   bool HasRelocationAddend = true);
32
33   virtual ~ELFObjectWriter();
34
35   virtual void ExecutePostLayoutBinding(MCAssembler &Asm);
36
37   virtual void RecordRelocation(const MCAssembler &Asm,
38                                 const MCAsmLayout &Layout,
39                                 const MCFragment *Fragment,
40                                 const MCFixup &Fixup, MCValue Target,
41                                 uint64_t &FixedValue);
42
43   virtual bool IsFixupFullyResolved(const MCAssembler &Asm,
44                                     const MCValue Target,
45                                     bool IsPCRel,
46                                     const MCFragment *DF) const;
47
48   virtual void WriteObject(MCAssembler &Asm, const MCAsmLayout &Layout);
49 };
50
51 } // End llvm namespace
52
53 #endif