1 //===-- llvm/MC/MCCodeEmitter.h - Instruction Encoding ----------*- 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_MCCODEEMITTER_H
11 #define LLVM_MC_MCCODEEMITTER_H
17 template<typename T> class SmallVectorImpl;
19 /// MCCodeEmitter - Generic instruction encoding interface.
22 MCCodeEmitter(const MCCodeEmitter &); // DO NOT IMPLEMENT
23 void operator=(const MCCodeEmitter &); // DO NOT IMPLEMENT
24 protected: // Can only create subclasses.
28 virtual ~MCCodeEmitter();
30 /// EncodeInstruction - Encode the given \arg Inst to bytes on the output
32 virtual void EncodeInstruction(const MCInst &Inst, raw_ostream &OS,
33 SmallVectorImpl<MCFixup> &Fixups) const = 0;
36 } // End llvm namespace