blob: f34ece81b95e6cbc1fc1580a831b1d66415e6767 [file] [log] [blame]
Dan Gohmanb0cf29c2008-08-13 20:19:35 +00001//===- FastISelEmitter.h - Generate an instruction selector -----*- 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// This tablegen backend emits a "fast" instruction selector.
11//
12//===----------------------------------------------------------------------===//
13
14#ifndef FASTISEL_EMITTER_H
15#define FASTISEL_EMITTER_H
16
17#include "TableGenBackend.h"
18#include "CodeGenDAGPatterns.h"
19#include <set>
20
21namespace llvm {
22
23/// FastISelEmitter - The top-level class which coordinates construction
24/// and emission of the instruction selector.
25///
26class FastISelEmitter : public TableGenBackend {
27 RecordKeeper &Records;
28 CodeGenDAGPatterns CGP;
29public:
30 explicit FastISelEmitter(RecordKeeper &R) : Records(R), CGP(R) {}
31
32 // run - Output the isel, returning true on failure.
33 void run(std::ostream &OS);
34};
35
36} // End llvm namespace
37
38#endif