Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 1 | // Generated with tools/gen_art_module_cc.sh |
Logan Chien | e75a8cc | 2012-02-24 12:26:43 +0800 | [diff] [blame] | 2 | |
| 3 | |
| 4 | #pragma GCC diagnostic ignored "-Wframe-larger-than=" |
| 5 | // TODO: Remove this pragma after llc can generate makeLLVMModuleContents() |
| 6 | // with smaller frame size. |
| 7 | |
| 8 | #include <llvm/DerivedTypes.h> |
| 9 | #include <llvm/Function.h> |
| 10 | #include <llvm/Module.h> |
| 11 | #include <llvm/Type.h> |
| 12 | |
| 13 | #include <vector> |
| 14 | |
| 15 | using namespace llvm; |
| 16 | |
| 17 | namespace art { |
| 18 | namespace compiler_llvm { |
| 19 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 20 | |
| 21 | // Generated by llvm2cpp - DO NOT MODIFY! |
| 22 | |
| 23 | |
| 24 | Module* makeLLVMModuleContents(Module *mod) { |
| 25 | |
| 26 | mod->setModuleIdentifier("art_module.ll"); |
| 27 | |
| 28 | // Type Definitions |
| 29 | std::vector<Type*>FuncTy_0_args; |
| 30 | StructType *StructTy_JavaObject = mod->getTypeByName("JavaObject"); |
| 31 | if (!StructTy_JavaObject) { |
| 32 | StructTy_JavaObject = StructType::create(mod->getContext(), "JavaObject"); |
| 33 | } |
| 34 | std::vector<Type*>StructTy_JavaObject_fields; |
| 35 | if (StructTy_JavaObject->isOpaque()) { |
| 36 | StructTy_JavaObject->setBody(StructTy_JavaObject_fields, /*isPacked=*/false); |
| 37 | } |
| 38 | |
| 39 | PointerType* PointerTy_1 = PointerType::get(StructTy_JavaObject, 0); |
| 40 | |
| 41 | FuncTy_0_args.push_back(PointerTy_1); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 42 | StructType *StructTy_ShadowFrame = mod->getTypeByName("ShadowFrame"); |
| 43 | if (!StructTy_ShadowFrame) { |
| 44 | StructTy_ShadowFrame = StructType::create(mod->getContext(), "ShadowFrame"); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 45 | } |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 46 | std::vector<Type*>StructTy_ShadowFrame_fields; |
| 47 | PointerType* PointerTy_2 = PointerType::get(StructTy_ShadowFrame, 0); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 48 | |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 49 | StructTy_ShadowFrame_fields.push_back(PointerTy_2); |
| 50 | StructTy_ShadowFrame_fields.push_back(PointerTy_1); |
| 51 | StructTy_ShadowFrame_fields.push_back(IntegerType::get(mod->getContext(), 32)); |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 52 | StructTy_ShadowFrame_fields.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 53 | if (StructTy_ShadowFrame->isOpaque()) { |
| 54 | StructTy_ShadowFrame->setBody(StructTy_ShadowFrame_fields, /*isPacked=*/false); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 55 | } |
| 56 | |
| 57 | |
| 58 | FuncTy_0_args.push_back(PointerTy_2); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 59 | FunctionType* FuncTy_0 = FunctionType::get( |
| 60 | /*Result=*/Type::getVoidTy(mod->getContext()), |
| 61 | /*Params=*/FuncTy_0_args, |
| 62 | /*isVarArg=*/false); |
| 63 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 64 | std::vector<Type*>FuncTy_3_args; |
| 65 | FunctionType* FuncTy_3 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 66 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 67 | /*Params=*/FuncTy_3_args, |
| 68 | /*isVarArg=*/false); |
| 69 | |
| 70 | std::vector<Type*>FuncTy_4_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 71 | FuncTy_4_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 72 | FunctionType* FuncTy_4 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 73 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 74 | /*Params=*/FuncTy_4_args, |
| 75 | /*isVarArg=*/false); |
| 76 | |
| 77 | std::vector<Type*>FuncTy_5_args; |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 78 | FunctionType* FuncTy_5 = FunctionType::get( |
| 79 | /*Result=*/Type::getVoidTy(mod->getContext()), |
| 80 | /*Params=*/FuncTy_5_args, |
| 81 | /*isVarArg=*/false); |
| 82 | |
| 83 | std::vector<Type*>FuncTy_6_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 84 | FuncTy_6_args.push_back(PointerTy_2); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 85 | FunctionType* FuncTy_6 = FunctionType::get( |
| 86 | /*Result=*/Type::getVoidTy(mod->getContext()), |
| 87 | /*Params=*/FuncTy_6_args, |
| 88 | /*isVarArg=*/false); |
| 89 | |
| 90 | std::vector<Type*>FuncTy_7_args; |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 91 | FunctionType* FuncTy_7 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 92 | /*Result=*/IntegerType::get(mod->getContext(), 1), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 93 | /*Params=*/FuncTy_7_args, |
| 94 | /*isVarArg=*/false); |
| 95 | |
| 96 | std::vector<Type*>FuncTy_8_args; |
| 97 | FuncTy_8_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 98 | FuncTy_8_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 99 | FunctionType* FuncTy_8 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 100 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 101 | /*Params=*/FuncTy_8_args, |
| 102 | /*isVarArg=*/false); |
| 103 | |
| 104 | std::vector<Type*>FuncTy_9_args; |
| 105 | FuncTy_9_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 106 | FunctionType* FuncTy_9 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 107 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 108 | /*Params=*/FuncTy_9_args, |
| 109 | /*isVarArg=*/false); |
| 110 | |
| 111 | std::vector<Type*>FuncTy_10_args; |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 112 | FuncTy_10_args.push_back(PointerTy_1); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 113 | FuncTy_10_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 114 | FuncTy_10_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 115 | FunctionType* FuncTy_10 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 116 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 117 | /*Params=*/FuncTy_10_args, |
| 118 | /*isVarArg=*/false); |
| 119 | |
| 120 | std::vector<Type*>FuncTy_11_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 121 | FuncTy_11_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 122 | FuncTy_11_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 123 | FunctionType* FuncTy_11 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 124 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 125 | /*Params=*/FuncTy_11_args, |
| 126 | /*isVarArg=*/false); |
| 127 | |
| 128 | std::vector<Type*>FuncTy_12_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 129 | FuncTy_12_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 130 | FuncTy_12_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 131 | FunctionType* FuncTy_12 = FunctionType::get( |
| 132 | /*Result=*/PointerTy_1, |
| 133 | /*Params=*/FuncTy_12_args, |
| 134 | /*isVarArg=*/false); |
| 135 | |
| 136 | std::vector<Type*>FuncTy_13_args; |
| 137 | FuncTy_13_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 138 | FuncTy_13_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 139 | FuncTy_13_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 140 | FunctionType* FuncTy_13 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 141 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 142 | /*Params=*/FuncTy_13_args, |
| 143 | /*isVarArg=*/false); |
| 144 | |
| 145 | std::vector<Type*>FuncTy_14_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 146 | FuncTy_14_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 147 | FuncTy_14_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 148 | FunctionType* FuncTy_14 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 149 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 150 | /*Params=*/FuncTy_14_args, |
| 151 | /*isVarArg=*/false); |
| 152 | |
| 153 | std::vector<Type*>FuncTy_15_args; |
| 154 | FuncTy_15_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 155 | FuncTy_15_args.push_back(PointerTy_1); |
| 156 | FuncTy_15_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 157 | FunctionType* FuncTy_15 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 158 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 159 | /*Params=*/FuncTy_15_args, |
| 160 | /*isVarArg=*/false); |
| 161 | |
| 162 | std::vector<Type*>FuncTy_16_args; |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 163 | FuncTy_16_args.push_back(PointerTy_1); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 164 | FuncTy_16_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 165 | FunctionType* FuncTy_16 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 166 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 167 | /*Params=*/FuncTy_16_args, |
| 168 | /*isVarArg=*/false); |
| 169 | |
| 170 | std::vector<Type*>FuncTy_17_args; |
| 171 | FuncTy_17_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 172 | FuncTy_17_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 173 | FuncTy_17_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 174 | FunctionType* FuncTy_17 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 175 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 176 | /*Params=*/FuncTy_17_args, |
| 177 | /*isVarArg=*/false); |
| 178 | |
| 179 | std::vector<Type*>FuncTy_18_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 180 | FuncTy_18_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 181 | FuncTy_18_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 182 | FuncTy_18_args.push_back(IntegerType::get(mod->getContext(), 64)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 183 | FunctionType* FuncTy_18 = FunctionType::get( |
| 184 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
| 185 | /*Params=*/FuncTy_18_args, |
| 186 | /*isVarArg=*/false); |
| 187 | |
| 188 | std::vector<Type*>FuncTy_19_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 189 | FuncTy_19_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 190 | FuncTy_19_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 191 | FuncTy_19_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 192 | FunctionType* FuncTy_19 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 193 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 194 | /*Params=*/FuncTy_19_args, |
| 195 | /*isVarArg=*/false); |
| 196 | |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 197 | std::vector<Type*>FuncTy_20_args; |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 198 | FuncTy_20_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | a6b2ca6 | 2012-03-06 15:50:54 +0800 | [diff] [blame] | 199 | FuncTy_20_args.push_back(PointerTy_1); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 200 | FunctionType* FuncTy_20 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 201 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 202 | /*Params=*/FuncTy_20_args, |
| 203 | /*isVarArg=*/false); |
| 204 | |
| 205 | std::vector<Type*>FuncTy_21_args; |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 206 | FuncTy_21_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 207 | FuncTy_21_args.push_back(PointerTy_1); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 208 | FunctionType* FuncTy_21 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 209 | /*Result=*/IntegerType::get(mod->getContext(), 64), |
Logan Chien | a6b2ca6 | 2012-03-06 15:50:54 +0800 | [diff] [blame] | 210 | /*Params=*/FuncTy_21_args, |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 211 | /*isVarArg=*/false); |
| 212 | |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 213 | std::vector<Type*>FuncTy_22_args; |
| 214 | FuncTy_22_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 215 | FuncTy_22_args.push_back(PointerTy_1); |
| 216 | FuncTy_22_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 217 | FuncTy_22_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 218 | FunctionType* FuncTy_22 = FunctionType::get( |
| 219 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
| 220 | /*Params=*/FuncTy_22_args, |
| 221 | /*isVarArg=*/false); |
| 222 | |
| 223 | std::vector<Type*>FuncTy_23_args; |
| 224 | FuncTy_23_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 225 | FuncTy_23_args.push_back(PointerTy_1); |
| 226 | FuncTy_23_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 227 | FuncTy_23_args.push_back(IntegerType::get(mod->getContext(), 64)); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 228 | FunctionType* FuncTy_23 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 229 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 230 | /*Params=*/FuncTy_23_args, |
| 231 | /*isVarArg=*/false); |
| 232 | |
| 233 | std::vector<Type*>FuncTy_24_args; |
| 234 | FuncTy_24_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 235 | FuncTy_24_args.push_back(PointerTy_1); |
| 236 | FuncTy_24_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 237 | FuncTy_24_args.push_back(PointerTy_1); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 238 | FunctionType* FuncTy_24 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 239 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 240 | /*Params=*/FuncTy_24_args, |
| 241 | /*isVarArg=*/false); |
| 242 | |
| 243 | std::vector<Type*>FuncTy_25_args; |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 244 | FuncTy_25_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 245 | FuncTy_25_args.push_back(PointerTy_1); |
| 246 | FuncTy_25_args.push_back(PointerTy_1); |
| 247 | FunctionType* FuncTy_25 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 248 | /*Result=*/IntegerType::get(mod->getContext(), 64), |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 249 | /*Params=*/FuncTy_25_args, |
| 250 | /*isVarArg=*/false); |
| 251 | |
| 252 | std::vector<Type*>FuncTy_26_args; |
| 253 | FuncTy_26_args.push_back(PointerTy_1); |
| 254 | FuncTy_26_args.push_back(PointerTy_1); |
| 255 | FunctionType* FuncTy_26 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 256 | /*Result=*/PointerTy_1, |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 257 | /*Params=*/FuncTy_26_args, |
| 258 | /*isVarArg=*/false); |
| 259 | |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 260 | std::vector<Type*>FuncTy_27_args; |
| 261 | FuncTy_27_args.push_back(PointerTy_1); |
| 262 | FuncTy_27_args.push_back(PointerTy_1); |
| 263 | FunctionType* FuncTy_27 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 264 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 265 | /*Params=*/FuncTy_27_args, |
| 266 | /*isVarArg=*/false); |
| 267 | |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 268 | std::vector<Type*>FuncTy_28_args; |
| 269 | FuncTy_28_args.push_back(PointerTy_1); |
| 270 | FuncTy_28_args.push_back(PointerTy_1); |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 271 | FunctionType* FuncTy_28 = FunctionType::get( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 272 | /*Result=*/Type::getVoidTy(mod->getContext()), |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 273 | /*Params=*/FuncTy_28_args, |
| 274 | /*isVarArg=*/false); |
| 275 | |
TDYa127 | 0b686e5 | 2012-04-09 22:43:35 -0700 | [diff] [blame] | 276 | std::vector<Type*>FuncTy_29_args; |
| 277 | FuncTy_29_args.push_back(PointerTy_1); |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 278 | FuncTy_29_args.push_back(PointerTy_1); |
| 279 | FuncTy_29_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 280 | FuncTy_29_args.push_back(IntegerType::get(mod->getContext(), 1)); |
TDYa127 | 0b686e5 | 2012-04-09 22:43:35 -0700 | [diff] [blame] | 281 | FunctionType* FuncTy_29 = FunctionType::get( |
| 282 | /*Result=*/PointerTy_1, |
| 283 | /*Params=*/FuncTy_29_args, |
| 284 | /*isVarArg=*/false); |
| 285 | |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 286 | std::vector<Type*>FuncTy_30_args; |
| 287 | FuncTy_30_args.push_back(PointerTy_1); |
| 288 | FunctionType* FuncTy_30 = FunctionType::get( |
| 289 | /*Result=*/PointerTy_1, |
| 290 | /*Params=*/FuncTy_30_args, |
| 291 | /*isVarArg=*/false); |
| 292 | |
TDYa127 | 5bb8601 | 2012-04-11 05:57:28 -0700 | [diff] [blame^] | 293 | std::vector<Type*>FuncTy_31_args; |
| 294 | FuncTy_31_args.push_back(PointerTy_1); |
| 295 | FunctionType* FuncTy_31 = FunctionType::get( |
| 296 | /*Result=*/Type::getVoidTy(mod->getContext()), |
| 297 | /*Params=*/FuncTy_31_args, |
| 298 | /*isVarArg=*/true); |
| 299 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 300 | |
| 301 | // Function Declarations |
| 302 | |
| 303 | Function* func___art_type_list = mod->getFunction("__art_type_list"); |
| 304 | if (!func___art_type_list) { |
| 305 | func___art_type_list = Function::Create( |
| 306 | /*Type=*/FuncTy_0, |
| 307 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 308 | /*Name=*/"__art_type_list", mod); // (external, no body) |
| 309 | func___art_type_list->setCallingConv(CallingConv::C); |
| 310 | } |
| 311 | AttrListPtr func___art_type_list_PAL; |
| 312 | func___art_type_list->setAttributes(func___art_type_list_PAL); |
| 313 | |
| 314 | Function* func_art_get_current_thread_from_code = mod->getFunction("art_get_current_thread_from_code"); |
| 315 | if (!func_art_get_current_thread_from_code) { |
| 316 | func_art_get_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 317 | /*Type=*/FuncTy_3, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 318 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 319 | /*Name=*/"art_get_current_thread_from_code", mod); // (external, no body) |
| 320 | func_art_get_current_thread_from_code->setCallingConv(CallingConv::C); |
| 321 | } |
| 322 | AttrListPtr func_art_get_current_thread_from_code_PAL; |
| 323 | func_art_get_current_thread_from_code->setAttributes(func_art_get_current_thread_from_code_PAL); |
| 324 | |
| 325 | Function* func_art_set_current_thread_from_code = mod->getFunction("art_set_current_thread_from_code"); |
| 326 | if (!func_art_set_current_thread_from_code) { |
| 327 | func_art_set_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 328 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 329 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 330 | /*Name=*/"art_set_current_thread_from_code", mod); // (external, no body) |
| 331 | func_art_set_current_thread_from_code->setCallingConv(CallingConv::C); |
| 332 | } |
| 333 | AttrListPtr func_art_set_current_thread_from_code_PAL; |
| 334 | func_art_set_current_thread_from_code->setAttributes(func_art_set_current_thread_from_code_PAL); |
| 335 | |
| 336 | Function* func_art_lock_object_from_code = mod->getFunction("art_lock_object_from_code"); |
| 337 | if (!func_art_lock_object_from_code) { |
| 338 | func_art_lock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 339 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 340 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 341 | /*Name=*/"art_lock_object_from_code", mod); // (external, no body) |
| 342 | func_art_lock_object_from_code->setCallingConv(CallingConv::C); |
| 343 | } |
| 344 | AttrListPtr func_art_lock_object_from_code_PAL; |
| 345 | func_art_lock_object_from_code->setAttributes(func_art_lock_object_from_code_PAL); |
| 346 | |
| 347 | Function* func_art_unlock_object_from_code = mod->getFunction("art_unlock_object_from_code"); |
| 348 | if (!func_art_unlock_object_from_code) { |
| 349 | func_art_unlock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 350 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 351 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 352 | /*Name=*/"art_unlock_object_from_code", mod); // (external, no body) |
| 353 | func_art_unlock_object_from_code->setCallingConv(CallingConv::C); |
| 354 | } |
| 355 | AttrListPtr func_art_unlock_object_from_code_PAL; |
| 356 | func_art_unlock_object_from_code->setAttributes(func_art_unlock_object_from_code_PAL); |
| 357 | |
| 358 | Function* func_art_test_suspend_from_code = mod->getFunction("art_test_suspend_from_code"); |
| 359 | if (!func_art_test_suspend_from_code) { |
| 360 | func_art_test_suspend_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 361 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 362 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 363 | /*Name=*/"art_test_suspend_from_code", mod); // (external, no body) |
| 364 | func_art_test_suspend_from_code->setCallingConv(CallingConv::C); |
| 365 | } |
| 366 | AttrListPtr func_art_test_suspend_from_code_PAL; |
| 367 | func_art_test_suspend_from_code->setAttributes(func_art_test_suspend_from_code_PAL); |
| 368 | |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 369 | Function* func_art_push_shadow_frame_from_code = mod->getFunction("art_push_shadow_frame_from_code"); |
| 370 | if (!func_art_push_shadow_frame_from_code) { |
| 371 | func_art_push_shadow_frame_from_code = Function::Create( |
| 372 | /*Type=*/FuncTy_6, |
| 373 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 374 | /*Name=*/"art_push_shadow_frame_from_code", mod); // (external, no body) |
| 375 | func_art_push_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 376 | } |
| 377 | AttrListPtr func_art_push_shadow_frame_from_code_PAL; |
| 378 | func_art_push_shadow_frame_from_code->setAttributes(func_art_push_shadow_frame_from_code_PAL); |
| 379 | |
| 380 | Function* func_art_pop_shadow_frame_from_code = mod->getFunction("art_pop_shadow_frame_from_code"); |
| 381 | if (!func_art_pop_shadow_frame_from_code) { |
| 382 | func_art_pop_shadow_frame_from_code = Function::Create( |
| 383 | /*Type=*/FuncTy_5, |
| 384 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 385 | /*Name=*/"art_pop_shadow_frame_from_code", mod); // (external, no body) |
| 386 | func_art_pop_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 387 | } |
| 388 | AttrListPtr func_art_pop_shadow_frame_from_code_PAL; |
| 389 | func_art_pop_shadow_frame_from_code->setAttributes(func_art_pop_shadow_frame_from_code_PAL); |
| 390 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 391 | Function* func_art_is_exception_pending_from_code = mod->getFunction("art_is_exception_pending_from_code"); |
| 392 | if (!func_art_is_exception_pending_from_code) { |
| 393 | func_art_is_exception_pending_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 394 | /*Type=*/FuncTy_7, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 395 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 396 | /*Name=*/"art_is_exception_pending_from_code", mod); // (external, no body) |
| 397 | func_art_is_exception_pending_from_code->setCallingConv(CallingConv::C); |
| 398 | } |
| 399 | AttrListPtr func_art_is_exception_pending_from_code_PAL; |
| 400 | func_art_is_exception_pending_from_code->setAttributes(func_art_is_exception_pending_from_code_PAL); |
| 401 | |
| 402 | Function* func_art_throw_div_zero_from_code = mod->getFunction("art_throw_div_zero_from_code"); |
| 403 | if (!func_art_throw_div_zero_from_code) { |
| 404 | func_art_throw_div_zero_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 405 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 406 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 407 | /*Name=*/"art_throw_div_zero_from_code", mod); // (external, no body) |
| 408 | func_art_throw_div_zero_from_code->setCallingConv(CallingConv::C); |
| 409 | } |
| 410 | AttrListPtr func_art_throw_div_zero_from_code_PAL; |
| 411 | func_art_throw_div_zero_from_code->setAttributes(func_art_throw_div_zero_from_code_PAL); |
| 412 | |
| 413 | Function* func_art_throw_array_bounds_from_code = mod->getFunction("art_throw_array_bounds_from_code"); |
| 414 | if (!func_art_throw_array_bounds_from_code) { |
| 415 | func_art_throw_array_bounds_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 416 | /*Type=*/FuncTy_8, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 417 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 418 | /*Name=*/"art_throw_array_bounds_from_code", mod); // (external, no body) |
| 419 | func_art_throw_array_bounds_from_code->setCallingConv(CallingConv::C); |
| 420 | } |
| 421 | AttrListPtr func_art_throw_array_bounds_from_code_PAL; |
| 422 | func_art_throw_array_bounds_from_code->setAttributes(func_art_throw_array_bounds_from_code_PAL); |
| 423 | |
| 424 | Function* func_art_throw_no_such_method_from_code = mod->getFunction("art_throw_no_such_method_from_code"); |
| 425 | if (!func_art_throw_no_such_method_from_code) { |
| 426 | func_art_throw_no_such_method_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 427 | /*Type=*/FuncTy_9, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 428 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 429 | /*Name=*/"art_throw_no_such_method_from_code", mod); // (external, no body) |
| 430 | func_art_throw_no_such_method_from_code->setCallingConv(CallingConv::C); |
| 431 | } |
| 432 | AttrListPtr func_art_throw_no_such_method_from_code_PAL; |
| 433 | func_art_throw_no_such_method_from_code->setAttributes(func_art_throw_no_such_method_from_code_PAL); |
| 434 | |
| 435 | Function* func_art_throw_null_pointer_exception_from_code = mod->getFunction("art_throw_null_pointer_exception_from_code"); |
| 436 | if (!func_art_throw_null_pointer_exception_from_code) { |
| 437 | func_art_throw_null_pointer_exception_from_code = Function::Create( |
TDYa127 | 3f9137d | 2012-04-08 15:59:19 -0700 | [diff] [blame] | 438 | /*Type=*/FuncTy_9, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 439 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 440 | /*Name=*/"art_throw_null_pointer_exception_from_code", mod); // (external, no body) |
| 441 | func_art_throw_null_pointer_exception_from_code->setCallingConv(CallingConv::C); |
| 442 | } |
| 443 | AttrListPtr func_art_throw_null_pointer_exception_from_code_PAL; |
| 444 | func_art_throw_null_pointer_exception_from_code->setAttributes(func_art_throw_null_pointer_exception_from_code_PAL); |
| 445 | |
| 446 | Function* func_art_throw_stack_overflow_from_code = mod->getFunction("art_throw_stack_overflow_from_code"); |
| 447 | if (!func_art_throw_stack_overflow_from_code) { |
| 448 | func_art_throw_stack_overflow_from_code = Function::Create( |
TDYa127 | 4165a83 | 2012-04-03 17:47:16 -0700 | [diff] [blame] | 449 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 450 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 451 | /*Name=*/"art_throw_stack_overflow_from_code", mod); // (external, no body) |
| 452 | func_art_throw_stack_overflow_from_code->setCallingConv(CallingConv::C); |
| 453 | } |
| 454 | AttrListPtr func_art_throw_stack_overflow_from_code_PAL; |
| 455 | func_art_throw_stack_overflow_from_code->setAttributes(func_art_throw_stack_overflow_from_code_PAL); |
| 456 | |
| 457 | Function* func_art_throw_exception_from_code = mod->getFunction("art_throw_exception_from_code"); |
| 458 | if (!func_art_throw_exception_from_code) { |
| 459 | func_art_throw_exception_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 460 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 461 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 462 | /*Name=*/"art_throw_exception_from_code", mod); // (external, no body) |
| 463 | func_art_throw_exception_from_code->setCallingConv(CallingConv::C); |
| 464 | } |
| 465 | AttrListPtr func_art_throw_exception_from_code_PAL; |
| 466 | func_art_throw_exception_from_code->setAttributes(func_art_throw_exception_from_code_PAL); |
| 467 | |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 468 | Function* func_art_throw_verification_error_from_code = mod->getFunction("art_throw_verification_error_from_code"); |
| 469 | if (!func_art_throw_verification_error_from_code) { |
| 470 | func_art_throw_verification_error_from_code = Function::Create( |
| 471 | /*Type=*/FuncTy_10, |
| 472 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 473 | /*Name=*/"art_throw_verification_error_from_code", mod); // (external, no body) |
| 474 | func_art_throw_verification_error_from_code->setCallingConv(CallingConv::C); |
| 475 | } |
| 476 | AttrListPtr func_art_throw_verification_error_from_code_PAL; |
| 477 | func_art_throw_verification_error_from_code->setAttributes(func_art_throw_verification_error_from_code_PAL); |
| 478 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 479 | Function* func_art_find_catch_block_from_code = mod->getFunction("art_find_catch_block_from_code"); |
| 480 | if (!func_art_find_catch_block_from_code) { |
| 481 | func_art_find_catch_block_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 482 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 483 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 484 | /*Name=*/"art_find_catch_block_from_code", mod); // (external, no body) |
| 485 | func_art_find_catch_block_from_code->setCallingConv(CallingConv::C); |
| 486 | } |
| 487 | AttrListPtr func_art_find_catch_block_from_code_PAL; |
| 488 | func_art_find_catch_block_from_code->setAttributes(func_art_find_catch_block_from_code_PAL); |
| 489 | |
| 490 | Function* func_art_alloc_object_from_code = mod->getFunction("art_alloc_object_from_code"); |
| 491 | if (!func_art_alloc_object_from_code) { |
| 492 | func_art_alloc_object_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 493 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 494 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 495 | /*Name=*/"art_alloc_object_from_code", mod); // (external, no body) |
| 496 | func_art_alloc_object_from_code->setCallingConv(CallingConv::C); |
| 497 | } |
| 498 | AttrListPtr func_art_alloc_object_from_code_PAL; |
| 499 | func_art_alloc_object_from_code->setAttributes(func_art_alloc_object_from_code_PAL); |
| 500 | |
| 501 | Function* func_art_alloc_object_from_code_with_access_check = mod->getFunction("art_alloc_object_from_code_with_access_check"); |
| 502 | if (!func_art_alloc_object_from_code_with_access_check) { |
| 503 | func_art_alloc_object_from_code_with_access_check = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 504 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 505 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 506 | /*Name=*/"art_alloc_object_from_code_with_access_check", mod); // (external, no body) |
| 507 | func_art_alloc_object_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 508 | } |
| 509 | AttrListPtr func_art_alloc_object_from_code_with_access_check_PAL; |
| 510 | func_art_alloc_object_from_code_with_access_check->setAttributes(func_art_alloc_object_from_code_with_access_check_PAL); |
| 511 | |
| 512 | Function* func_art_alloc_array_from_code = mod->getFunction("art_alloc_array_from_code"); |
| 513 | if (!func_art_alloc_array_from_code) { |
| 514 | func_art_alloc_array_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 515 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 516 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 517 | /*Name=*/"art_alloc_array_from_code", mod); // (external, no body) |
| 518 | func_art_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 519 | } |
| 520 | AttrListPtr func_art_alloc_array_from_code_PAL; |
| 521 | func_art_alloc_array_from_code->setAttributes(func_art_alloc_array_from_code_PAL); |
| 522 | |
| 523 | Function* func_art_alloc_array_from_code_with_access_check = mod->getFunction("art_alloc_array_from_code_with_access_check"); |
| 524 | if (!func_art_alloc_array_from_code_with_access_check) { |
| 525 | func_art_alloc_array_from_code_with_access_check = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 526 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 527 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 528 | /*Name=*/"art_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 529 | func_art_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 530 | } |
| 531 | AttrListPtr func_art_alloc_array_from_code_with_access_check_PAL; |
| 532 | func_art_alloc_array_from_code_with_access_check->setAttributes(func_art_alloc_array_from_code_with_access_check_PAL); |
| 533 | |
| 534 | Function* func_art_check_and_alloc_array_from_code = mod->getFunction("art_check_and_alloc_array_from_code"); |
| 535 | if (!func_art_check_and_alloc_array_from_code) { |
| 536 | func_art_check_and_alloc_array_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 537 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 538 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 539 | /*Name=*/"art_check_and_alloc_array_from_code", mod); // (external, no body) |
| 540 | func_art_check_and_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 541 | } |
| 542 | AttrListPtr func_art_check_and_alloc_array_from_code_PAL; |
| 543 | func_art_check_and_alloc_array_from_code->setAttributes(func_art_check_and_alloc_array_from_code_PAL); |
| 544 | |
| 545 | Function* func_art_check_and_alloc_array_from_code_with_access_check = mod->getFunction("art_check_and_alloc_array_from_code_with_access_check"); |
| 546 | if (!func_art_check_and_alloc_array_from_code_with_access_check) { |
| 547 | func_art_check_and_alloc_array_from_code_with_access_check = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 548 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 549 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 550 | /*Name=*/"art_check_and_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 551 | func_art_check_and_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 552 | } |
| 553 | AttrListPtr func_art_check_and_alloc_array_from_code_with_access_check_PAL; |
| 554 | func_art_check_and_alloc_array_from_code_with_access_check->setAttributes(func_art_check_and_alloc_array_from_code_with_access_check_PAL); |
| 555 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 556 | Function* func_art_find_instance_field_from_code = mod->getFunction("art_find_instance_field_from_code"); |
| 557 | if (!func_art_find_instance_field_from_code) { |
| 558 | func_art_find_instance_field_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 559 | /*Type=*/FuncTy_14, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 560 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 561 | /*Name=*/"art_find_instance_field_from_code", mod); // (external, no body) |
| 562 | func_art_find_instance_field_from_code->setCallingConv(CallingConv::C); |
| 563 | } |
| 564 | AttrListPtr func_art_find_instance_field_from_code_PAL; |
| 565 | func_art_find_instance_field_from_code->setAttributes(func_art_find_instance_field_from_code_PAL); |
| 566 | |
| 567 | Function* func_art_find_static_field_from_code = mod->getFunction("art_find_static_field_from_code"); |
| 568 | if (!func_art_find_static_field_from_code) { |
| 569 | func_art_find_static_field_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 570 | /*Type=*/FuncTy_14, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 571 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 572 | /*Name=*/"art_find_static_field_from_code", mod); // (external, no body) |
| 573 | func_art_find_static_field_from_code->setCallingConv(CallingConv::C); |
| 574 | } |
| 575 | AttrListPtr func_art_find_static_field_from_code_PAL; |
| 576 | func_art_find_static_field_from_code->setAttributes(func_art_find_static_field_from_code_PAL); |
| 577 | |
Logan Chien | 7e7fabc | 2012-04-10 18:59:11 +0800 | [diff] [blame] | 578 | Function* func_art_find_static_method_from_code_with_access_check = mod->getFunction("art_find_static_method_from_code_with_access_check"); |
| 579 | if (!func_art_find_static_method_from_code_with_access_check) { |
| 580 | func_art_find_static_method_from_code_with_access_check = Function::Create( |
| 581 | /*Type=*/FuncTy_15, |
| 582 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 583 | /*Name=*/"art_find_static_method_from_code_with_access_check", mod); // (external, no body) |
| 584 | func_art_find_static_method_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 585 | } |
| 586 | AttrListPtr func_art_find_static_method_from_code_with_access_check_PAL; |
| 587 | func_art_find_static_method_from_code_with_access_check->setAttributes(func_art_find_static_method_from_code_with_access_check_PAL); |
| 588 | |
| 589 | Function* func_art_find_direct_method_from_code_with_access_check = mod->getFunction("art_find_direct_method_from_code_with_access_check"); |
| 590 | if (!func_art_find_direct_method_from_code_with_access_check) { |
| 591 | func_art_find_direct_method_from_code_with_access_check = Function::Create( |
| 592 | /*Type=*/FuncTy_15, |
| 593 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 594 | /*Name=*/"art_find_direct_method_from_code_with_access_check", mod); // (external, no body) |
| 595 | func_art_find_direct_method_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 596 | } |
| 597 | AttrListPtr func_art_find_direct_method_from_code_with_access_check_PAL; |
| 598 | func_art_find_direct_method_from_code_with_access_check->setAttributes(func_art_find_direct_method_from_code_with_access_check_PAL); |
| 599 | |
| 600 | Function* func_art_find_virtual_method_from_code_with_access_check = mod->getFunction("art_find_virtual_method_from_code_with_access_check"); |
| 601 | if (!func_art_find_virtual_method_from_code_with_access_check) { |
| 602 | func_art_find_virtual_method_from_code_with_access_check = Function::Create( |
| 603 | /*Type=*/FuncTy_15, |
| 604 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 605 | /*Name=*/"art_find_virtual_method_from_code_with_access_check", mod); // (external, no body) |
| 606 | func_art_find_virtual_method_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 607 | } |
| 608 | AttrListPtr func_art_find_virtual_method_from_code_with_access_check_PAL; |
| 609 | func_art_find_virtual_method_from_code_with_access_check->setAttributes(func_art_find_virtual_method_from_code_with_access_check_PAL); |
| 610 | |
| 611 | Function* func_art_find_super_method_from_code_with_access_check = mod->getFunction("art_find_super_method_from_code_with_access_check"); |
| 612 | if (!func_art_find_super_method_from_code_with_access_check) { |
| 613 | func_art_find_super_method_from_code_with_access_check = Function::Create( |
| 614 | /*Type=*/FuncTy_15, |
| 615 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 616 | /*Name=*/"art_find_super_method_from_code_with_access_check", mod); // (external, no body) |
| 617 | func_art_find_super_method_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 618 | } |
| 619 | AttrListPtr func_art_find_super_method_from_code_with_access_check_PAL; |
| 620 | func_art_find_super_method_from_code_with_access_check->setAttributes(func_art_find_super_method_from_code_with_access_check_PAL); |
| 621 | |
| 622 | Function* func_art_find_interface_method_from_code_with_access_check = mod->getFunction("art_find_interface_method_from_code_with_access_check"); |
| 623 | if (!func_art_find_interface_method_from_code_with_access_check) { |
| 624 | func_art_find_interface_method_from_code_with_access_check = Function::Create( |
| 625 | /*Type=*/FuncTy_15, |
| 626 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 627 | /*Name=*/"art_find_interface_method_from_code_with_access_check", mod); // (external, no body) |
| 628 | func_art_find_interface_method_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 629 | } |
| 630 | AttrListPtr func_art_find_interface_method_from_code_with_access_check_PAL; |
| 631 | func_art_find_interface_method_from_code_with_access_check->setAttributes(func_art_find_interface_method_from_code_with_access_check_PAL); |
| 632 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 633 | Function* func_art_find_interface_method_from_code = mod->getFunction("art_find_interface_method_from_code"); |
| 634 | if (!func_art_find_interface_method_from_code) { |
| 635 | func_art_find_interface_method_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 636 | /*Type=*/FuncTy_15, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 637 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 638 | /*Name=*/"art_find_interface_method_from_code", mod); // (external, no body) |
| 639 | func_art_find_interface_method_from_code->setCallingConv(CallingConv::C); |
| 640 | } |
| 641 | AttrListPtr func_art_find_interface_method_from_code_PAL; |
| 642 | func_art_find_interface_method_from_code->setAttributes(func_art_find_interface_method_from_code_PAL); |
| 643 | |
| 644 | Function* func_art_initialize_static_storage_from_code = mod->getFunction("art_initialize_static_storage_from_code"); |
| 645 | if (!func_art_initialize_static_storage_from_code) { |
| 646 | func_art_initialize_static_storage_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 647 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 648 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 649 | /*Name=*/"art_initialize_static_storage_from_code", mod); // (external, no body) |
| 650 | func_art_initialize_static_storage_from_code->setCallingConv(CallingConv::C); |
| 651 | } |
| 652 | AttrListPtr func_art_initialize_static_storage_from_code_PAL; |
| 653 | func_art_initialize_static_storage_from_code->setAttributes(func_art_initialize_static_storage_from_code_PAL); |
| 654 | |
| 655 | Function* func_art_initialize_type_from_code = mod->getFunction("art_initialize_type_from_code"); |
| 656 | if (!func_art_initialize_type_from_code) { |
| 657 | func_art_initialize_type_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 658 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 659 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 660 | /*Name=*/"art_initialize_type_from_code", mod); // (external, no body) |
| 661 | func_art_initialize_type_from_code->setCallingConv(CallingConv::C); |
| 662 | } |
| 663 | AttrListPtr func_art_initialize_type_from_code_PAL; |
| 664 | func_art_initialize_type_from_code->setAttributes(func_art_initialize_type_from_code_PAL); |
| 665 | |
| 666 | Function* func_art_initialize_type_and_verify_access_from_code = mod->getFunction("art_initialize_type_and_verify_access_from_code"); |
| 667 | if (!func_art_initialize_type_and_verify_access_from_code) { |
| 668 | func_art_initialize_type_and_verify_access_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 669 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 670 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 671 | /*Name=*/"art_initialize_type_and_verify_access_from_code", mod); // (external, no body) |
| 672 | func_art_initialize_type_and_verify_access_from_code->setCallingConv(CallingConv::C); |
| 673 | } |
| 674 | AttrListPtr func_art_initialize_type_and_verify_access_from_code_PAL; |
| 675 | func_art_initialize_type_and_verify_access_from_code->setAttributes(func_art_initialize_type_and_verify_access_from_code_PAL); |
| 676 | |
| 677 | Function* func_art_resolve_string_from_code = mod->getFunction("art_resolve_string_from_code"); |
| 678 | if (!func_art_resolve_string_from_code) { |
| 679 | func_art_resolve_string_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 680 | /*Type=*/FuncTy_16, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 681 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 682 | /*Name=*/"art_resolve_string_from_code", mod); // (external, no body) |
| 683 | func_art_resolve_string_from_code->setCallingConv(CallingConv::C); |
| 684 | } |
| 685 | AttrListPtr func_art_resolve_string_from_code_PAL; |
| 686 | func_art_resolve_string_from_code->setAttributes(func_art_resolve_string_from_code_PAL); |
| 687 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 688 | Function* func_art_set32_static_from_code = mod->getFunction("art_set32_static_from_code"); |
| 689 | if (!func_art_set32_static_from_code) { |
| 690 | func_art_set32_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 691 | /*Type=*/FuncTy_17, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 692 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 693 | /*Name=*/"art_set32_static_from_code", mod); // (external, no body) |
| 694 | func_art_set32_static_from_code->setCallingConv(CallingConv::C); |
| 695 | } |
| 696 | AttrListPtr func_art_set32_static_from_code_PAL; |
| 697 | func_art_set32_static_from_code->setAttributes(func_art_set32_static_from_code_PAL); |
| 698 | |
| 699 | Function* func_art_set64_static_from_code = mod->getFunction("art_set64_static_from_code"); |
| 700 | if (!func_art_set64_static_from_code) { |
| 701 | func_art_set64_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 702 | /*Type=*/FuncTy_18, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 703 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 704 | /*Name=*/"art_set64_static_from_code", mod); // (external, no body) |
| 705 | func_art_set64_static_from_code->setCallingConv(CallingConv::C); |
| 706 | } |
| 707 | AttrListPtr func_art_set64_static_from_code_PAL; |
| 708 | func_art_set64_static_from_code->setAttributes(func_art_set64_static_from_code_PAL); |
| 709 | |
| 710 | Function* func_art_set_obj_static_from_code = mod->getFunction("art_set_obj_static_from_code"); |
| 711 | if (!func_art_set_obj_static_from_code) { |
| 712 | func_art_set_obj_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 713 | /*Type=*/FuncTy_19, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 714 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 715 | /*Name=*/"art_set_obj_static_from_code", mod); // (external, no body) |
| 716 | func_art_set_obj_static_from_code->setCallingConv(CallingConv::C); |
| 717 | } |
| 718 | AttrListPtr func_art_set_obj_static_from_code_PAL; |
| 719 | func_art_set_obj_static_from_code->setAttributes(func_art_set_obj_static_from_code_PAL); |
| 720 | |
| 721 | Function* func_art_get32_static_from_code = mod->getFunction("art_get32_static_from_code"); |
| 722 | if (!func_art_get32_static_from_code) { |
| 723 | func_art_get32_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 724 | /*Type=*/FuncTy_20, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 725 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 726 | /*Name=*/"art_get32_static_from_code", mod); // (external, no body) |
| 727 | func_art_get32_static_from_code->setCallingConv(CallingConv::C); |
| 728 | } |
| 729 | AttrListPtr func_art_get32_static_from_code_PAL; |
| 730 | func_art_get32_static_from_code->setAttributes(func_art_get32_static_from_code_PAL); |
| 731 | |
| 732 | Function* func_art_get64_static_from_code = mod->getFunction("art_get64_static_from_code"); |
| 733 | if (!func_art_get64_static_from_code) { |
| 734 | func_art_get64_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 735 | /*Type=*/FuncTy_21, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 736 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 737 | /*Name=*/"art_get64_static_from_code", mod); // (external, no body) |
| 738 | func_art_get64_static_from_code->setCallingConv(CallingConv::C); |
| 739 | } |
| 740 | AttrListPtr func_art_get64_static_from_code_PAL; |
| 741 | func_art_get64_static_from_code->setAttributes(func_art_get64_static_from_code_PAL); |
| 742 | |
| 743 | Function* func_art_get_obj_static_from_code = mod->getFunction("art_get_obj_static_from_code"); |
| 744 | if (!func_art_get_obj_static_from_code) { |
| 745 | func_art_get_obj_static_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 746 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 747 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 748 | /*Name=*/"art_get_obj_static_from_code", mod); // (external, no body) |
| 749 | func_art_get_obj_static_from_code->setCallingConv(CallingConv::C); |
| 750 | } |
| 751 | AttrListPtr func_art_get_obj_static_from_code_PAL; |
| 752 | func_art_get_obj_static_from_code->setAttributes(func_art_get_obj_static_from_code_PAL); |
| 753 | |
| 754 | Function* func_art_set32_instance_from_code = mod->getFunction("art_set32_instance_from_code"); |
| 755 | if (!func_art_set32_instance_from_code) { |
| 756 | func_art_set32_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 757 | /*Type=*/FuncTy_22, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 758 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 759 | /*Name=*/"art_set32_instance_from_code", mod); // (external, no body) |
| 760 | func_art_set32_instance_from_code->setCallingConv(CallingConv::C); |
| 761 | } |
| 762 | AttrListPtr func_art_set32_instance_from_code_PAL; |
| 763 | func_art_set32_instance_from_code->setAttributes(func_art_set32_instance_from_code_PAL); |
| 764 | |
| 765 | Function* func_art_set64_instance_from_code = mod->getFunction("art_set64_instance_from_code"); |
| 766 | if (!func_art_set64_instance_from_code) { |
| 767 | func_art_set64_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 768 | /*Type=*/FuncTy_23, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 769 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 770 | /*Name=*/"art_set64_instance_from_code", mod); // (external, no body) |
| 771 | func_art_set64_instance_from_code->setCallingConv(CallingConv::C); |
| 772 | } |
| 773 | AttrListPtr func_art_set64_instance_from_code_PAL; |
| 774 | func_art_set64_instance_from_code->setAttributes(func_art_set64_instance_from_code_PAL); |
| 775 | |
| 776 | Function* func_art_set_obj_instance_from_code = mod->getFunction("art_set_obj_instance_from_code"); |
| 777 | if (!func_art_set_obj_instance_from_code) { |
| 778 | func_art_set_obj_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 779 | /*Type=*/FuncTy_24, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 780 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 781 | /*Name=*/"art_set_obj_instance_from_code", mod); // (external, no body) |
| 782 | func_art_set_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 783 | } |
| 784 | AttrListPtr func_art_set_obj_instance_from_code_PAL; |
| 785 | func_art_set_obj_instance_from_code->setAttributes(func_art_set_obj_instance_from_code_PAL); |
| 786 | |
| 787 | Function* func_art_get32_instance_from_code = mod->getFunction("art_get32_instance_from_code"); |
| 788 | if (!func_art_get32_instance_from_code) { |
| 789 | func_art_get32_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 790 | /*Type=*/FuncTy_19, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 791 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 792 | /*Name=*/"art_get32_instance_from_code", mod); // (external, no body) |
| 793 | func_art_get32_instance_from_code->setCallingConv(CallingConv::C); |
| 794 | } |
| 795 | AttrListPtr func_art_get32_instance_from_code_PAL; |
| 796 | func_art_get32_instance_from_code->setAttributes(func_art_get32_instance_from_code_PAL); |
| 797 | |
| 798 | Function* func_art_get64_instance_from_code = mod->getFunction("art_get64_instance_from_code"); |
| 799 | if (!func_art_get64_instance_from_code) { |
| 800 | func_art_get64_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 801 | /*Type=*/FuncTy_25, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 802 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 803 | /*Name=*/"art_get64_instance_from_code", mod); // (external, no body) |
| 804 | func_art_get64_instance_from_code->setCallingConv(CallingConv::C); |
| 805 | } |
| 806 | AttrListPtr func_art_get64_instance_from_code_PAL; |
| 807 | func_art_get64_instance_from_code->setAttributes(func_art_get64_instance_from_code_PAL); |
| 808 | |
| 809 | Function* func_art_get_obj_instance_from_code = mod->getFunction("art_get_obj_instance_from_code"); |
| 810 | if (!func_art_get_obj_instance_from_code) { |
| 811 | func_art_get_obj_instance_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 812 | /*Type=*/FuncTy_15, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 813 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 814 | /*Name=*/"art_get_obj_instance_from_code", mod); // (external, no body) |
| 815 | func_art_get_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 816 | } |
| 817 | AttrListPtr func_art_get_obj_instance_from_code_PAL; |
| 818 | func_art_get_obj_instance_from_code->setAttributes(func_art_get_obj_instance_from_code_PAL); |
| 819 | |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 820 | Function* func_art_decode_jobject_in_thread = mod->getFunction("art_decode_jobject_in_thread"); |
| 821 | if (!func_art_decode_jobject_in_thread) { |
| 822 | func_art_decode_jobject_in_thread = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 823 | /*Type=*/FuncTy_26, |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 824 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 825 | /*Name=*/"art_decode_jobject_in_thread", mod); // (external, no body) |
| 826 | func_art_decode_jobject_in_thread->setCallingConv(CallingConv::C); |
| 827 | } |
| 828 | AttrListPtr func_art_decode_jobject_in_thread_PAL; |
| 829 | func_art_decode_jobject_in_thread->setAttributes(func_art_decode_jobject_in_thread_PAL); |
| 830 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 831 | Function* func_art_is_assignable_from_code = mod->getFunction("art_is_assignable_from_code"); |
| 832 | if (!func_art_is_assignable_from_code) { |
| 833 | func_art_is_assignable_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 834 | /*Type=*/FuncTy_27, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 835 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 836 | /*Name=*/"art_is_assignable_from_code", mod); // (external, no body) |
| 837 | func_art_is_assignable_from_code->setCallingConv(CallingConv::C); |
| 838 | } |
| 839 | AttrListPtr func_art_is_assignable_from_code_PAL; |
| 840 | func_art_is_assignable_from_code->setAttributes(func_art_is_assignable_from_code_PAL); |
| 841 | |
| 842 | Function* func_art_check_cast_from_code = mod->getFunction("art_check_cast_from_code"); |
| 843 | if (!func_art_check_cast_from_code) { |
| 844 | func_art_check_cast_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 845 | /*Type=*/FuncTy_28, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 846 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 847 | /*Name=*/"art_check_cast_from_code", mod); // (external, no body) |
| 848 | func_art_check_cast_from_code->setCallingConv(CallingConv::C); |
| 849 | } |
| 850 | AttrListPtr func_art_check_cast_from_code_PAL; |
| 851 | func_art_check_cast_from_code->setAttributes(func_art_check_cast_from_code_PAL); |
| 852 | |
TDYa127 | 1b86d07 | 2012-04-05 17:38:56 -0700 | [diff] [blame] | 853 | Function* func_art_check_put_array_element_from_code = mod->getFunction("art_check_put_array_element_from_code"); |
| 854 | if (!func_art_check_put_array_element_from_code) { |
| 855 | func_art_check_put_array_element_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 856 | /*Type=*/FuncTy_28, |
TDYa127 | 1b86d07 | 2012-04-05 17:38:56 -0700 | [diff] [blame] | 857 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 858 | /*Name=*/"art_check_put_array_element_from_code", mod); // (external, no body) |
| 859 | func_art_check_put_array_element_from_code->setCallingConv(CallingConv::C); |
| 860 | } |
| 861 | AttrListPtr func_art_check_put_array_element_from_code_PAL; |
| 862 | func_art_check_put_array_element_from_code->setAttributes(func_art_check_put_array_element_from_code_PAL); |
| 863 | |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 864 | Function* func_art_ensure_resolved_from_code = mod->getFunction("art_ensure_resolved_from_code"); |
| 865 | if (!func_art_ensure_resolved_from_code) { |
| 866 | func_art_ensure_resolved_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 867 | /*Type=*/FuncTy_29, |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 868 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 869 | /*Name=*/"art_ensure_resolved_from_code", mod); // (external, no body) |
| 870 | func_art_ensure_resolved_from_code->setCallingConv(CallingConv::C); |
| 871 | } |
| 872 | AttrListPtr func_art_ensure_resolved_from_code_PAL; |
| 873 | func_art_ensure_resolved_from_code->setAttributes(func_art_ensure_resolved_from_code_PAL); |
| 874 | |
TDYa127 | 0b686e5 | 2012-04-09 22:43:35 -0700 | [diff] [blame] | 875 | Function* func_art_fix_stub_from_code = mod->getFunction("art_fix_stub_from_code"); |
| 876 | if (!func_art_fix_stub_from_code) { |
| 877 | func_art_fix_stub_from_code = Function::Create( |
Logan Chien | 9e5f5c1 | 2012-04-10 13:51:45 +0800 | [diff] [blame] | 878 | /*Type=*/FuncTy_30, |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 879 | /*Linkage=*/GlobalValue::ExternalLinkage, |
TDYa127 | 0b686e5 | 2012-04-09 22:43:35 -0700 | [diff] [blame] | 880 | /*Name=*/"art_fix_stub_from_code", mod); // (external, no body) |
| 881 | func_art_fix_stub_from_code->setCallingConv(CallingConv::C); |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 882 | } |
TDYa127 | 0b686e5 | 2012-04-09 22:43:35 -0700 | [diff] [blame] | 883 | AttrListPtr func_art_fix_stub_from_code_PAL; |
| 884 | func_art_fix_stub_from_code->setAttributes(func_art_fix_stub_from_code_PAL); |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 885 | |
TDYa127 | 5bb8601 | 2012-04-11 05:57:28 -0700 | [diff] [blame^] | 886 | Function* func_art_proxy_invoke_handler_from_code = mod->getFunction("art_proxy_invoke_handler_from_code"); |
| 887 | if (!func_art_proxy_invoke_handler_from_code) { |
| 888 | func_art_proxy_invoke_handler_from_code = Function::Create( |
| 889 | /*Type=*/FuncTy_31, |
| 890 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 891 | /*Name=*/"art_proxy_invoke_handler_from_code", mod); // (external, no body) |
| 892 | func_art_proxy_invoke_handler_from_code->setCallingConv(CallingConv::C); |
| 893 | } |
| 894 | AttrListPtr func_art_proxy_invoke_handler_from_code_PAL; |
| 895 | func_art_proxy_invoke_handler_from_code->setAttributes(func_art_proxy_invoke_handler_from_code_PAL); |
| 896 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 897 | // Global Variable Declarations |
| 898 | |
| 899 | |
| 900 | // Constant Definitions |
| 901 | |
| 902 | // Global Variable Definitions |
| 903 | |
| 904 | // Function Definitions |
| 905 | |
| 906 | return mod; |
| 907 | |
| 908 | } |
Logan Chien | e75a8cc | 2012-02-24 12:26:43 +0800 | [diff] [blame] | 909 | |
| 910 | } // namespace compiler_llvm |
| 911 | } // namespace art |