1 //===-- llvm/MC/MachObjectWriter.h - Mach-O File Writer ---------*- C++ -*-===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #ifndef LLVM_MC_MACHOBJECTWRITER_H
11 #define LLVM_MC_MACHOBJECTWRITER_H
13 #include "llvm/MC/MCObjectWriter.h"
14 #include "llvm/Support/raw_ostream.h"
24 class MachObjectWriter : public MCObjectWriter {
28 MachObjectWriter(raw_ostream &OS, bool Is64Bit, uint32_t CPUType,
29 uint32_t CPUSubtype, bool IsLittleEndian = true);
30 virtual ~MachObjectWriter();
32 virtual void ExecutePostLayoutBinding(MCAssembler &Asm);
34 virtual void RecordRelocation(const MCAssembler &Asm,
35 const MCAsmLayout &Layout,
36 const MCFragment *Fragment,
37 const MCFixup &Fixup, MCValue Target,
38 uint64_t &FixedValue);
40 virtual bool IsFixupFullyResolved(const MCAssembler &Asm,
43 const MCFragment *DF) const;
45 virtual void WriteObject(MCAssembler &Asm, const MCAsmLayout &Layout);
48 } // End llvm namespace