| OLD | NEW |
| 1 //===- subzero/src/IceConverter.h - Converts LLVM to ICE --------*- C++ -*-===// | 1 //===- subzero/src/IceConverter.h - Converts LLVM to ICE --------*- C++ -*-===// |
| 2 // | 2 // |
| 3 // The Subzero Code Generator | 3 // The Subzero Code Generator |
| 4 // | 4 // |
| 5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
| 6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
| 7 // | 7 // |
| 8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
| 9 // | 9 // |
| 10 // This file declares the LLVM to ICE converter. | 10 // This file declares the LLVM to ICE converter. |
| 11 // | 11 // |
| 12 //===----------------------------------------------------------------------===// | 12 //===----------------------------------------------------------------------===// |
| 13 | 13 |
| 14 #ifndef SUBZERO_SRC_ICECONVERTER_H | 14 #ifndef SUBZERO_SRC_ICECONVERTER_H |
| 15 #define SUBZERO_SRC_ICECONVERTER_H | 15 #define SUBZERO_SRC_ICECONVERTER_H |
| 16 | 16 |
| 17 #include "IceTranslator.h" | 17 #include "IceTranslator.h" |
| 18 | 18 |
| 19 namespace llvm { | 19 namespace llvm { |
| 20 class Module; | 20 class Module; |
| 21 } | 21 } |
| 22 | 22 |
| 23 namespace Ice { | 23 namespace Ice { |
| 24 | 24 |
| 25 class Converter : public Translator { | 25 class Converter : public Translator { |
| 26 public: | 26 public: |
| 27 Converter(GlobalContext *Ctx, Ice::ClFlags &Flags) : Translator(Ctx, Flags) {} | 27 Converter(GlobalContext *Ctx, Ice::ClFlags &Flags) : Translator(Ctx, Flags) {} |
| 28 /// Converts the LLVM Module to ICE. Returns exit status 0 if successful, | 28 /// Converts the LLVM Module to ICE. Sets exit status to false if successful, |
| 29 /// Nonzero otherwise. | 29 /// true otherwise. |
| 30 int convertToIce(llvm::Module *Mod); | 30 void convertToIce(llvm::Module *Mod); |
| 31 | 31 |
| 32 private: | 32 private: |
| 33 // Converts globals to ICE, and then machine code. |
| 34 void convertGlobals(llvm::Module *Mod); |
| 35 // Converts functions to ICE, and then machine code. |
| 36 void convertFunctions(llvm::Module *Mod); |
| 33 Converter(const Converter &) LLVM_DELETED_FUNCTION; | 37 Converter(const Converter &) LLVM_DELETED_FUNCTION; |
| 34 Converter &operator=(const Converter &) LLVM_DELETED_FUNCTION; | 38 Converter &operator=(const Converter &) LLVM_DELETED_FUNCTION; |
| 35 }; | 39 }; |
| 36 } | 40 } |
| 37 | 41 |
| 38 #endif // SUBZERO_SRC_ICECONVERTER_H | 42 #endif // SUBZERO_SRC_ICECONVERTER_H |
| OLD | NEW |