blob: 87915a6366df7b6f648142280ee180e261440254 [file] [log] [blame]
//===- subzero/src/IceCompiler.h - Compiler driver --------------*- C++ -*-===//
//
// The Subzero Code Generator
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------------------------------------------------------------------===//
//
// This file declares the driver for translating bitcode to native code.
//
//===----------------------------------------------------------------------===//
#ifndef SUBZERO_SRC_ICECOMPILER_H
#define SUBZERO_SRC_ICECOMPILER_H
#include "IceDefs.h"
namespace llvm {
class DataStreamer;
}
namespace Ice {
class ClFlagsExtra;
// A compiler driver. It may be called to handle a single compile request.
class Compiler {
Compiler(const Compiler &) = delete;
Compiler &operator=(const Compiler &) = delete;
public:
Compiler() {}
// Run the compiler with the given GlobalContext for compilation
// state. Upon error, the Context's error status will be set.
void run(const ClFlagsExtra &ExtraFlags, GlobalContext &Ctx,
std::unique_ptr<llvm::DataStreamer> &&InputStream);
};
} // end of namespace Ice
#endif // SUBZERO_SRC_ICECOMPILER_H