Add missing file.
[oota-llvm.git] / include / llvm / CodeGen / MachineCodeInfo.h
1 //===-- MachineCodeInfo.h - Class used to report JIT info -------*- 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 file defines MachineCodeInfo, a class used by the JIT ExecutionEngine
11 // to report information about the generated machine code.
12 //
13 // See JIT::runJITOnFunction for usage.
14 //
15 //===----------------------------------------------------------------------===//
16
17 #ifndef EE_MACHINE_CODE_INFO_H
18 #define EE_MACHINE_CODE_INFO_H
19
20 namespace llvm {
21
22 class MachineCodeInfo {
23 private:
24   size_t Size;   // Number of bytes in memory used
25   void *Address; // The address of the function in memory
26
27 public:
28   MachineCodeInfo() : Size(0), Address(0) {}
29
30   void setSize(size_t s) {
31     Size = s;
32   }
33
34   void setAddress(void *a) {
35     Address = a;
36   }
37
38   size_t size() const {
39     return Size;
40   }
41
42   void *address() const {
43     return Address;
44   }
45
46 };
47
48 }
49
50 #endif
51