Logan Chien | e75a8cc | 2012-02-24 12:26:43 +0800 | [diff] [blame] | 1 | // Generated with ../tools/gen_art_module_cc.sh |
| 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 | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 114 | FunctionType* FuncTy_10 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 115 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 116 | /*Params=*/FuncTy_10_args, |
| 117 | /*isVarArg=*/false); |
| 118 | |
| 119 | std::vector<Type*>FuncTy_11_args; |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 120 | FuncTy_11_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 121 | FuncTy_11_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 122 | FunctionType* FuncTy_11 = FunctionType::get( |
| 123 | /*Result=*/PointerTy_1, |
| 124 | /*Params=*/FuncTy_11_args, |
| 125 | /*isVarArg=*/false); |
| 126 | |
| 127 | std::vector<Type*>FuncTy_12_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 128 | FuncTy_12_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 129 | FuncTy_12_args.push_back(PointerTy_1); |
| 130 | FuncTy_12_args.push_back(IntegerType::get(mod->getContext(), 32)); |
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 | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 139 | FunctionType* FuncTy_13 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 140 | /*Result=*/Type::getVoidTy(mod->getContext()), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 141 | /*Params=*/FuncTy_13_args, |
| 142 | /*isVarArg=*/false); |
| 143 | |
| 144 | std::vector<Type*>FuncTy_14_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 145 | FuncTy_14_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 146 | FuncTy_14_args.push_back(PointerTy_1); |
| 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 | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 149 | /*Result=*/PointerTy_1, |
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; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 154 | FuncTy_15_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 155 | FuncTy_15_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 156 | FunctionType* FuncTy_15 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 157 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 158 | /*Params=*/FuncTy_15_args, |
| 159 | /*isVarArg=*/false); |
| 160 | |
| 161 | std::vector<Type*>FuncTy_16_args; |
| 162 | FuncTy_16_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 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( |
| 166 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
| 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 | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 173 | FuncTy_17_args.push_back(IntegerType::get(mod->getContext(), 64)); |
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 | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 182 | FuncTy_18_args.push_back(PointerTy_1); |
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); |
| 191 | FunctionType* FuncTy_19 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 192 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 193 | /*Params=*/FuncTy_19_args, |
| 194 | /*isVarArg=*/false); |
| 195 | |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 196 | std::vector<Type*>FuncTy_20_args; |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 197 | FuncTy_20_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | a6b2ca6 | 2012-03-06 15:50:54 +0800 | [diff] [blame] | 198 | FuncTy_20_args.push_back(PointerTy_1); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 199 | FunctionType* FuncTy_20 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 200 | /*Result=*/IntegerType::get(mod->getContext(), 64), |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 201 | /*Params=*/FuncTy_20_args, |
| 202 | /*isVarArg=*/false); |
| 203 | |
| 204 | std::vector<Type*>FuncTy_21_args; |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 205 | FuncTy_21_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 206 | FuncTy_21_args.push_back(PointerTy_1); |
| 207 | FuncTy_21_args.push_back(PointerTy_1); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 208 | FuncTy_21_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 209 | FunctionType* FuncTy_21 = FunctionType::get( |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 210 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | a6b2ca6 | 2012-03-06 15:50:54 +0800 | [diff] [blame] | 211 | /*Params=*/FuncTy_21_args, |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 212 | /*isVarArg=*/false); |
| 213 | |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 214 | std::vector<Type*>FuncTy_22_args; |
| 215 | FuncTy_22_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 216 | FuncTy_22_args.push_back(PointerTy_1); |
| 217 | FuncTy_22_args.push_back(PointerTy_1); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 218 | FuncTy_22_args.push_back(IntegerType::get(mod->getContext(), 64)); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 219 | FunctionType* FuncTy_22 = FunctionType::get( |
| 220 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
| 221 | /*Params=*/FuncTy_22_args, |
| 222 | /*isVarArg=*/false); |
| 223 | |
| 224 | std::vector<Type*>FuncTy_23_args; |
| 225 | FuncTy_23_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 226 | FuncTy_23_args.push_back(PointerTy_1); |
| 227 | FuncTy_23_args.push_back(PointerTy_1); |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 228 | FuncTy_23_args.push_back(PointerTy_1); |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 229 | FunctionType* FuncTy_23 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 230 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 231 | /*Params=*/FuncTy_23_args, |
| 232 | /*isVarArg=*/false); |
| 233 | |
| 234 | std::vector<Type*>FuncTy_24_args; |
| 235 | FuncTy_24_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 236 | FuncTy_24_args.push_back(PointerTy_1); |
| 237 | FuncTy_24_args.push_back(PointerTy_1); |
| 238 | FunctionType* FuncTy_24 = FunctionType::get( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 239 | /*Result=*/IntegerType::get(mod->getContext(), 64), |
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; |
| 244 | FuncTy_25_args.push_back(PointerTy_1); |
| 245 | FuncTy_25_args.push_back(PointerTy_1); |
| 246 | FunctionType* FuncTy_25 = FunctionType::get( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 247 | /*Result=*/PointerTy_1, |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 248 | /*Params=*/FuncTy_25_args, |
| 249 | /*isVarArg=*/false); |
| 250 | |
| 251 | std::vector<Type*>FuncTy_26_args; |
| 252 | FuncTy_26_args.push_back(PointerTy_1); |
| 253 | FuncTy_26_args.push_back(PointerTy_1); |
| 254 | FunctionType* FuncTy_26 = FunctionType::get( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 255 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
Logan Chien | 3b2b2e7 | 2012-03-06 16:11:45 +0800 | [diff] [blame] | 256 | /*Params=*/FuncTy_26_args, |
| 257 | /*isVarArg=*/false); |
| 258 | |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 259 | std::vector<Type*>FuncTy_27_args; |
| 260 | FuncTy_27_args.push_back(PointerTy_1); |
| 261 | FuncTy_27_args.push_back(PointerTy_1); |
| 262 | FunctionType* FuncTy_27 = FunctionType::get( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 263 | /*Result=*/Type::getVoidTy(mod->getContext()), |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 264 | /*Params=*/FuncTy_27_args, |
| 265 | /*isVarArg=*/false); |
| 266 | |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 267 | std::vector<Type*>FuncTy_28_args; |
| 268 | FuncTy_28_args.push_back(PointerTy_1); |
| 269 | FuncTy_28_args.push_back(PointerTy_1); |
| 270 | FuncTy_28_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 271 | FuncTy_28_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 272 | FunctionType* FuncTy_28 = FunctionType::get( |
| 273 | /*Result=*/PointerTy_1, |
| 274 | /*Params=*/FuncTy_28_args, |
| 275 | /*isVarArg=*/false); |
| 276 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 277 | |
| 278 | // Function Declarations |
| 279 | |
| 280 | Function* func___art_type_list = mod->getFunction("__art_type_list"); |
| 281 | if (!func___art_type_list) { |
| 282 | func___art_type_list = Function::Create( |
| 283 | /*Type=*/FuncTy_0, |
| 284 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 285 | /*Name=*/"__art_type_list", mod); // (external, no body) |
| 286 | func___art_type_list->setCallingConv(CallingConv::C); |
| 287 | } |
| 288 | AttrListPtr func___art_type_list_PAL; |
| 289 | func___art_type_list->setAttributes(func___art_type_list_PAL); |
| 290 | |
| 291 | Function* func_art_get_current_thread_from_code = mod->getFunction("art_get_current_thread_from_code"); |
| 292 | if (!func_art_get_current_thread_from_code) { |
| 293 | func_art_get_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 294 | /*Type=*/FuncTy_3, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 295 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 296 | /*Name=*/"art_get_current_thread_from_code", mod); // (external, no body) |
| 297 | func_art_get_current_thread_from_code->setCallingConv(CallingConv::C); |
| 298 | } |
| 299 | AttrListPtr func_art_get_current_thread_from_code_PAL; |
| 300 | func_art_get_current_thread_from_code->setAttributes(func_art_get_current_thread_from_code_PAL); |
| 301 | |
| 302 | Function* func_art_set_current_thread_from_code = mod->getFunction("art_set_current_thread_from_code"); |
| 303 | if (!func_art_set_current_thread_from_code) { |
| 304 | func_art_set_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 305 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 306 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 307 | /*Name=*/"art_set_current_thread_from_code", mod); // (external, no body) |
| 308 | func_art_set_current_thread_from_code->setCallingConv(CallingConv::C); |
| 309 | } |
| 310 | AttrListPtr func_art_set_current_thread_from_code_PAL; |
| 311 | func_art_set_current_thread_from_code->setAttributes(func_art_set_current_thread_from_code_PAL); |
| 312 | |
| 313 | Function* func_art_lock_object_from_code = mod->getFunction("art_lock_object_from_code"); |
| 314 | if (!func_art_lock_object_from_code) { |
| 315 | func_art_lock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 316 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 317 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 318 | /*Name=*/"art_lock_object_from_code", mod); // (external, no body) |
| 319 | func_art_lock_object_from_code->setCallingConv(CallingConv::C); |
| 320 | } |
| 321 | AttrListPtr func_art_lock_object_from_code_PAL; |
| 322 | func_art_lock_object_from_code->setAttributes(func_art_lock_object_from_code_PAL); |
| 323 | |
| 324 | Function* func_art_unlock_object_from_code = mod->getFunction("art_unlock_object_from_code"); |
| 325 | if (!func_art_unlock_object_from_code) { |
| 326 | func_art_unlock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 327 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 328 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 329 | /*Name=*/"art_unlock_object_from_code", mod); // (external, no body) |
| 330 | func_art_unlock_object_from_code->setCallingConv(CallingConv::C); |
| 331 | } |
| 332 | AttrListPtr func_art_unlock_object_from_code_PAL; |
| 333 | func_art_unlock_object_from_code->setAttributes(func_art_unlock_object_from_code_PAL); |
| 334 | |
| 335 | Function* func_art_test_suspend_from_code = mod->getFunction("art_test_suspend_from_code"); |
| 336 | if (!func_art_test_suspend_from_code) { |
| 337 | func_art_test_suspend_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 338 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 339 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 340 | /*Name=*/"art_test_suspend_from_code", mod); // (external, no body) |
| 341 | func_art_test_suspend_from_code->setCallingConv(CallingConv::C); |
| 342 | } |
| 343 | AttrListPtr func_art_test_suspend_from_code_PAL; |
| 344 | func_art_test_suspend_from_code->setAttributes(func_art_test_suspend_from_code_PAL); |
| 345 | |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 346 | Function* func_art_push_shadow_frame_from_code = mod->getFunction("art_push_shadow_frame_from_code"); |
| 347 | if (!func_art_push_shadow_frame_from_code) { |
| 348 | func_art_push_shadow_frame_from_code = Function::Create( |
| 349 | /*Type=*/FuncTy_6, |
| 350 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 351 | /*Name=*/"art_push_shadow_frame_from_code", mod); // (external, no body) |
| 352 | func_art_push_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 353 | } |
| 354 | AttrListPtr func_art_push_shadow_frame_from_code_PAL; |
| 355 | func_art_push_shadow_frame_from_code->setAttributes(func_art_push_shadow_frame_from_code_PAL); |
| 356 | |
| 357 | Function* func_art_pop_shadow_frame_from_code = mod->getFunction("art_pop_shadow_frame_from_code"); |
| 358 | if (!func_art_pop_shadow_frame_from_code) { |
| 359 | func_art_pop_shadow_frame_from_code = Function::Create( |
| 360 | /*Type=*/FuncTy_5, |
| 361 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 362 | /*Name=*/"art_pop_shadow_frame_from_code", mod); // (external, no body) |
| 363 | func_art_pop_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 364 | } |
| 365 | AttrListPtr func_art_pop_shadow_frame_from_code_PAL; |
| 366 | func_art_pop_shadow_frame_from_code->setAttributes(func_art_pop_shadow_frame_from_code_PAL); |
| 367 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 368 | Function* func_art_is_exception_pending_from_code = mod->getFunction("art_is_exception_pending_from_code"); |
| 369 | if (!func_art_is_exception_pending_from_code) { |
| 370 | func_art_is_exception_pending_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 371 | /*Type=*/FuncTy_7, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 372 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 373 | /*Name=*/"art_is_exception_pending_from_code", mod); // (external, no body) |
| 374 | func_art_is_exception_pending_from_code->setCallingConv(CallingConv::C); |
| 375 | } |
| 376 | AttrListPtr func_art_is_exception_pending_from_code_PAL; |
| 377 | func_art_is_exception_pending_from_code->setAttributes(func_art_is_exception_pending_from_code_PAL); |
| 378 | |
| 379 | Function* func_art_throw_div_zero_from_code = mod->getFunction("art_throw_div_zero_from_code"); |
| 380 | if (!func_art_throw_div_zero_from_code) { |
| 381 | func_art_throw_div_zero_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 382 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 383 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 384 | /*Name=*/"art_throw_div_zero_from_code", mod); // (external, no body) |
| 385 | func_art_throw_div_zero_from_code->setCallingConv(CallingConv::C); |
| 386 | } |
| 387 | AttrListPtr func_art_throw_div_zero_from_code_PAL; |
| 388 | func_art_throw_div_zero_from_code->setAttributes(func_art_throw_div_zero_from_code_PAL); |
| 389 | |
| 390 | Function* func_art_throw_array_bounds_from_code = mod->getFunction("art_throw_array_bounds_from_code"); |
| 391 | if (!func_art_throw_array_bounds_from_code) { |
| 392 | func_art_throw_array_bounds_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 393 | /*Type=*/FuncTy_8, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 394 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 395 | /*Name=*/"art_throw_array_bounds_from_code", mod); // (external, no body) |
| 396 | func_art_throw_array_bounds_from_code->setCallingConv(CallingConv::C); |
| 397 | } |
| 398 | AttrListPtr func_art_throw_array_bounds_from_code_PAL; |
| 399 | func_art_throw_array_bounds_from_code->setAttributes(func_art_throw_array_bounds_from_code_PAL); |
| 400 | |
| 401 | Function* func_art_throw_no_such_method_from_code = mod->getFunction("art_throw_no_such_method_from_code"); |
| 402 | if (!func_art_throw_no_such_method_from_code) { |
| 403 | func_art_throw_no_such_method_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 404 | /*Type=*/FuncTy_9, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 405 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 406 | /*Name=*/"art_throw_no_such_method_from_code", mod); // (external, no body) |
| 407 | func_art_throw_no_such_method_from_code->setCallingConv(CallingConv::C); |
| 408 | } |
| 409 | AttrListPtr func_art_throw_no_such_method_from_code_PAL; |
| 410 | func_art_throw_no_such_method_from_code->setAttributes(func_art_throw_no_such_method_from_code_PAL); |
| 411 | |
| 412 | Function* func_art_throw_null_pointer_exception_from_code = mod->getFunction("art_throw_null_pointer_exception_from_code"); |
| 413 | if (!func_art_throw_null_pointer_exception_from_code) { |
| 414 | func_art_throw_null_pointer_exception_from_code = Function::Create( |
TDYa127 | 3f9137d | 2012-04-08 15:59:19 -0700 | [diff] [blame] | 415 | /*Type=*/FuncTy_9, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 416 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 417 | /*Name=*/"art_throw_null_pointer_exception_from_code", mod); // (external, no body) |
| 418 | func_art_throw_null_pointer_exception_from_code->setCallingConv(CallingConv::C); |
| 419 | } |
| 420 | AttrListPtr func_art_throw_null_pointer_exception_from_code_PAL; |
| 421 | func_art_throw_null_pointer_exception_from_code->setAttributes(func_art_throw_null_pointer_exception_from_code_PAL); |
| 422 | |
| 423 | Function* func_art_throw_stack_overflow_from_code = mod->getFunction("art_throw_stack_overflow_from_code"); |
| 424 | if (!func_art_throw_stack_overflow_from_code) { |
| 425 | func_art_throw_stack_overflow_from_code = Function::Create( |
TDYa127 | 4165a83 | 2012-04-03 17:47:16 -0700 | [diff] [blame] | 426 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 427 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 428 | /*Name=*/"art_throw_stack_overflow_from_code", mod); // (external, no body) |
| 429 | func_art_throw_stack_overflow_from_code->setCallingConv(CallingConv::C); |
| 430 | } |
| 431 | AttrListPtr func_art_throw_stack_overflow_from_code_PAL; |
| 432 | func_art_throw_stack_overflow_from_code->setAttributes(func_art_throw_stack_overflow_from_code_PAL); |
| 433 | |
| 434 | Function* func_art_throw_exception_from_code = mod->getFunction("art_throw_exception_from_code"); |
| 435 | if (!func_art_throw_exception_from_code) { |
| 436 | func_art_throw_exception_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 437 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 438 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 439 | /*Name=*/"art_throw_exception_from_code", mod); // (external, no body) |
| 440 | func_art_throw_exception_from_code->setCallingConv(CallingConv::C); |
| 441 | } |
| 442 | AttrListPtr func_art_throw_exception_from_code_PAL; |
| 443 | func_art_throw_exception_from_code->setAttributes(func_art_throw_exception_from_code_PAL); |
| 444 | |
| 445 | Function* func_art_find_catch_block_from_code = mod->getFunction("art_find_catch_block_from_code"); |
| 446 | if (!func_art_find_catch_block_from_code) { |
| 447 | func_art_find_catch_block_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 448 | /*Type=*/FuncTy_10, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 449 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 450 | /*Name=*/"art_find_catch_block_from_code", mod); // (external, no body) |
| 451 | func_art_find_catch_block_from_code->setCallingConv(CallingConv::C); |
| 452 | } |
| 453 | AttrListPtr func_art_find_catch_block_from_code_PAL; |
| 454 | func_art_find_catch_block_from_code->setAttributes(func_art_find_catch_block_from_code_PAL); |
| 455 | |
| 456 | Function* func_art_alloc_object_from_code = mod->getFunction("art_alloc_object_from_code"); |
| 457 | if (!func_art_alloc_object_from_code) { |
| 458 | func_art_alloc_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 459 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 460 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 461 | /*Name=*/"art_alloc_object_from_code", mod); // (external, no body) |
| 462 | func_art_alloc_object_from_code->setCallingConv(CallingConv::C); |
| 463 | } |
| 464 | AttrListPtr func_art_alloc_object_from_code_PAL; |
| 465 | func_art_alloc_object_from_code->setAttributes(func_art_alloc_object_from_code_PAL); |
| 466 | |
| 467 | Function* func_art_alloc_object_from_code_with_access_check = mod->getFunction("art_alloc_object_from_code_with_access_check"); |
| 468 | if (!func_art_alloc_object_from_code_with_access_check) { |
| 469 | func_art_alloc_object_from_code_with_access_check = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 470 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 471 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 472 | /*Name=*/"art_alloc_object_from_code_with_access_check", mod); // (external, no body) |
| 473 | func_art_alloc_object_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 474 | } |
| 475 | AttrListPtr func_art_alloc_object_from_code_with_access_check_PAL; |
| 476 | func_art_alloc_object_from_code_with_access_check->setAttributes(func_art_alloc_object_from_code_with_access_check_PAL); |
| 477 | |
| 478 | Function* func_art_alloc_array_from_code = mod->getFunction("art_alloc_array_from_code"); |
| 479 | if (!func_art_alloc_array_from_code) { |
| 480 | func_art_alloc_array_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 481 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 482 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 483 | /*Name=*/"art_alloc_array_from_code", mod); // (external, no body) |
| 484 | func_art_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 485 | } |
| 486 | AttrListPtr func_art_alloc_array_from_code_PAL; |
| 487 | func_art_alloc_array_from_code->setAttributes(func_art_alloc_array_from_code_PAL); |
| 488 | |
| 489 | Function* func_art_alloc_array_from_code_with_access_check = mod->getFunction("art_alloc_array_from_code_with_access_check"); |
| 490 | if (!func_art_alloc_array_from_code_with_access_check) { |
| 491 | func_art_alloc_array_from_code_with_access_check = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 492 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 493 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 494 | /*Name=*/"art_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 495 | func_art_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 496 | } |
| 497 | AttrListPtr func_art_alloc_array_from_code_with_access_check_PAL; |
| 498 | func_art_alloc_array_from_code_with_access_check->setAttributes(func_art_alloc_array_from_code_with_access_check_PAL); |
| 499 | |
| 500 | Function* func_art_check_and_alloc_array_from_code = mod->getFunction("art_check_and_alloc_array_from_code"); |
| 501 | if (!func_art_check_and_alloc_array_from_code) { |
| 502 | func_art_check_and_alloc_array_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 503 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 504 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 505 | /*Name=*/"art_check_and_alloc_array_from_code", mod); // (external, no body) |
| 506 | func_art_check_and_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 507 | } |
| 508 | AttrListPtr func_art_check_and_alloc_array_from_code_PAL; |
| 509 | func_art_check_and_alloc_array_from_code->setAttributes(func_art_check_and_alloc_array_from_code_PAL); |
| 510 | |
| 511 | Function* func_art_check_and_alloc_array_from_code_with_access_check = mod->getFunction("art_check_and_alloc_array_from_code_with_access_check"); |
| 512 | if (!func_art_check_and_alloc_array_from_code_with_access_check) { |
| 513 | func_art_check_and_alloc_array_from_code_with_access_check = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 514 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 515 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 516 | /*Name=*/"art_check_and_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 517 | func_art_check_and_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 518 | } |
| 519 | AttrListPtr func_art_check_and_alloc_array_from_code_with_access_check_PAL; |
| 520 | func_art_check_and_alloc_array_from_code_with_access_check->setAttributes(func_art_check_and_alloc_array_from_code_with_access_check_PAL); |
| 521 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 522 | Function* func_art_find_instance_field_from_code = mod->getFunction("art_find_instance_field_from_code"); |
| 523 | if (!func_art_find_instance_field_from_code) { |
| 524 | func_art_find_instance_field_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 525 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 526 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 527 | /*Name=*/"art_find_instance_field_from_code", mod); // (external, no body) |
| 528 | func_art_find_instance_field_from_code->setCallingConv(CallingConv::C); |
| 529 | } |
| 530 | AttrListPtr func_art_find_instance_field_from_code_PAL; |
| 531 | func_art_find_instance_field_from_code->setAttributes(func_art_find_instance_field_from_code_PAL); |
| 532 | |
| 533 | Function* func_art_find_static_field_from_code = mod->getFunction("art_find_static_field_from_code"); |
| 534 | if (!func_art_find_static_field_from_code) { |
| 535 | func_art_find_static_field_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 536 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 537 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 538 | /*Name=*/"art_find_static_field_from_code", mod); // (external, no body) |
| 539 | func_art_find_static_field_from_code->setCallingConv(CallingConv::C); |
| 540 | } |
| 541 | AttrListPtr func_art_find_static_field_from_code_PAL; |
| 542 | func_art_find_static_field_from_code->setAttributes(func_art_find_static_field_from_code_PAL); |
| 543 | |
| 544 | Function* func_art_find_interface_method_from_code = mod->getFunction("art_find_interface_method_from_code"); |
| 545 | if (!func_art_find_interface_method_from_code) { |
| 546 | func_art_find_interface_method_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 547 | /*Type=*/FuncTy_14, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 548 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 549 | /*Name=*/"art_find_interface_method_from_code", mod); // (external, no body) |
| 550 | func_art_find_interface_method_from_code->setCallingConv(CallingConv::C); |
| 551 | } |
| 552 | AttrListPtr func_art_find_interface_method_from_code_PAL; |
| 553 | func_art_find_interface_method_from_code->setAttributes(func_art_find_interface_method_from_code_PAL); |
| 554 | |
Shih-wei Liao | 399ed3f | 2012-03-08 01:27:04 -0800 | [diff] [blame] | 555 | Function* func_art_find_virtual_method_from_code = mod->getFunction("art_find_virtual_method_from_code"); |
| 556 | if (!func_art_find_virtual_method_from_code) { |
| 557 | func_art_find_virtual_method_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 558 | /*Type=*/FuncTy_14, |
Shih-wei Liao | 399ed3f | 2012-03-08 01:27:04 -0800 | [diff] [blame] | 559 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 560 | /*Name=*/"art_find_virtual_method_from_code", mod); // (external, no body) |
| 561 | func_art_find_virtual_method_from_code->setCallingConv(CallingConv::C); |
| 562 | } |
| 563 | AttrListPtr func_art_find_virtual_method_from_code_PAL; |
| 564 | func_art_find_virtual_method_from_code->setAttributes(func_art_find_virtual_method_from_code_PAL); |
| 565 | |
| 566 | Function* func_art_find_super_method_from_code = mod->getFunction("art_find_super_method_from_code"); |
| 567 | if (!func_art_find_super_method_from_code) { |
| 568 | func_art_find_super_method_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 569 | /*Type=*/FuncTy_14, |
Shih-wei Liao | 399ed3f | 2012-03-08 01:27:04 -0800 | [diff] [blame] | 570 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 571 | /*Name=*/"art_find_super_method_from_code", mod); // (external, no body) |
| 572 | func_art_find_super_method_from_code->setCallingConv(CallingConv::C); |
| 573 | } |
| 574 | AttrListPtr func_art_find_super_method_from_code_PAL; |
| 575 | func_art_find_super_method_from_code->setAttributes(func_art_find_super_method_from_code_PAL); |
| 576 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 577 | Function* func_art_initialize_static_storage_from_code = mod->getFunction("art_initialize_static_storage_from_code"); |
| 578 | if (!func_art_initialize_static_storage_from_code) { |
| 579 | func_art_initialize_static_storage_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 580 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 581 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 582 | /*Name=*/"art_initialize_static_storage_from_code", mod); // (external, no body) |
| 583 | func_art_initialize_static_storage_from_code->setCallingConv(CallingConv::C); |
| 584 | } |
| 585 | AttrListPtr func_art_initialize_static_storage_from_code_PAL; |
| 586 | func_art_initialize_static_storage_from_code->setAttributes(func_art_initialize_static_storage_from_code_PAL); |
| 587 | |
| 588 | Function* func_art_initialize_type_from_code = mod->getFunction("art_initialize_type_from_code"); |
| 589 | if (!func_art_initialize_type_from_code) { |
| 590 | func_art_initialize_type_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 591 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 592 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 593 | /*Name=*/"art_initialize_type_from_code", mod); // (external, no body) |
| 594 | func_art_initialize_type_from_code->setCallingConv(CallingConv::C); |
| 595 | } |
| 596 | AttrListPtr func_art_initialize_type_from_code_PAL; |
| 597 | func_art_initialize_type_from_code->setAttributes(func_art_initialize_type_from_code_PAL); |
| 598 | |
| 599 | Function* func_art_initialize_type_and_verify_access_from_code = mod->getFunction("art_initialize_type_and_verify_access_from_code"); |
| 600 | if (!func_art_initialize_type_and_verify_access_from_code) { |
| 601 | func_art_initialize_type_and_verify_access_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 602 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 603 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 604 | /*Name=*/"art_initialize_type_and_verify_access_from_code", mod); // (external, no body) |
| 605 | func_art_initialize_type_and_verify_access_from_code->setCallingConv(CallingConv::C); |
| 606 | } |
| 607 | AttrListPtr func_art_initialize_type_and_verify_access_from_code_PAL; |
| 608 | func_art_initialize_type_and_verify_access_from_code->setAttributes(func_art_initialize_type_and_verify_access_from_code_PAL); |
| 609 | |
| 610 | Function* func_art_resolve_string_from_code = mod->getFunction("art_resolve_string_from_code"); |
| 611 | if (!func_art_resolve_string_from_code) { |
| 612 | func_art_resolve_string_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 613 | /*Type=*/FuncTy_15, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 614 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 615 | /*Name=*/"art_resolve_string_from_code", mod); // (external, no body) |
| 616 | func_art_resolve_string_from_code->setCallingConv(CallingConv::C); |
| 617 | } |
| 618 | AttrListPtr func_art_resolve_string_from_code_PAL; |
| 619 | func_art_resolve_string_from_code->setAttributes(func_art_resolve_string_from_code_PAL); |
| 620 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 621 | Function* func_art_set32_static_from_code = mod->getFunction("art_set32_static_from_code"); |
| 622 | if (!func_art_set32_static_from_code) { |
| 623 | func_art_set32_static_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 624 | /*Type=*/FuncTy_16, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 625 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 626 | /*Name=*/"art_set32_static_from_code", mod); // (external, no body) |
| 627 | func_art_set32_static_from_code->setCallingConv(CallingConv::C); |
| 628 | } |
| 629 | AttrListPtr func_art_set32_static_from_code_PAL; |
| 630 | func_art_set32_static_from_code->setAttributes(func_art_set32_static_from_code_PAL); |
| 631 | |
| 632 | Function* func_art_set64_static_from_code = mod->getFunction("art_set64_static_from_code"); |
| 633 | if (!func_art_set64_static_from_code) { |
| 634 | func_art_set64_static_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 635 | /*Type=*/FuncTy_17, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 636 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 637 | /*Name=*/"art_set64_static_from_code", mod); // (external, no body) |
| 638 | func_art_set64_static_from_code->setCallingConv(CallingConv::C); |
| 639 | } |
| 640 | AttrListPtr func_art_set64_static_from_code_PAL; |
| 641 | func_art_set64_static_from_code->setAttributes(func_art_set64_static_from_code_PAL); |
| 642 | |
| 643 | Function* func_art_set_obj_static_from_code = mod->getFunction("art_set_obj_static_from_code"); |
| 644 | if (!func_art_set_obj_static_from_code) { |
| 645 | func_art_set_obj_static_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 646 | /*Type=*/FuncTy_18, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 647 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 648 | /*Name=*/"art_set_obj_static_from_code", mod); // (external, no body) |
| 649 | func_art_set_obj_static_from_code->setCallingConv(CallingConv::C); |
| 650 | } |
| 651 | AttrListPtr func_art_set_obj_static_from_code_PAL; |
| 652 | func_art_set_obj_static_from_code->setAttributes(func_art_set_obj_static_from_code_PAL); |
| 653 | |
| 654 | Function* func_art_get32_static_from_code = mod->getFunction("art_get32_static_from_code"); |
| 655 | if (!func_art_get32_static_from_code) { |
| 656 | func_art_get32_static_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 657 | /*Type=*/FuncTy_19, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 658 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 659 | /*Name=*/"art_get32_static_from_code", mod); // (external, no body) |
| 660 | func_art_get32_static_from_code->setCallingConv(CallingConv::C); |
| 661 | } |
| 662 | AttrListPtr func_art_get32_static_from_code_PAL; |
| 663 | func_art_get32_static_from_code->setAttributes(func_art_get32_static_from_code_PAL); |
| 664 | |
| 665 | Function* func_art_get64_static_from_code = mod->getFunction("art_get64_static_from_code"); |
| 666 | if (!func_art_get64_static_from_code) { |
| 667 | func_art_get64_static_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 668 | /*Type=*/FuncTy_20, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 669 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 670 | /*Name=*/"art_get64_static_from_code", mod); // (external, no body) |
| 671 | func_art_get64_static_from_code->setCallingConv(CallingConv::C); |
| 672 | } |
| 673 | AttrListPtr func_art_get64_static_from_code_PAL; |
| 674 | func_art_get64_static_from_code->setAttributes(func_art_get64_static_from_code_PAL); |
| 675 | |
| 676 | Function* func_art_get_obj_static_from_code = mod->getFunction("art_get_obj_static_from_code"); |
| 677 | if (!func_art_get_obj_static_from_code) { |
| 678 | func_art_get_obj_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 679 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 680 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 681 | /*Name=*/"art_get_obj_static_from_code", mod); // (external, no body) |
| 682 | func_art_get_obj_static_from_code->setCallingConv(CallingConv::C); |
| 683 | } |
| 684 | AttrListPtr func_art_get_obj_static_from_code_PAL; |
| 685 | func_art_get_obj_static_from_code->setAttributes(func_art_get_obj_static_from_code_PAL); |
| 686 | |
| 687 | Function* func_art_set32_instance_from_code = mod->getFunction("art_set32_instance_from_code"); |
| 688 | if (!func_art_set32_instance_from_code) { |
| 689 | func_art_set32_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 690 | /*Type=*/FuncTy_21, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 691 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 692 | /*Name=*/"art_set32_instance_from_code", mod); // (external, no body) |
| 693 | func_art_set32_instance_from_code->setCallingConv(CallingConv::C); |
| 694 | } |
| 695 | AttrListPtr func_art_set32_instance_from_code_PAL; |
| 696 | func_art_set32_instance_from_code->setAttributes(func_art_set32_instance_from_code_PAL); |
| 697 | |
| 698 | Function* func_art_set64_instance_from_code = mod->getFunction("art_set64_instance_from_code"); |
| 699 | if (!func_art_set64_instance_from_code) { |
| 700 | func_art_set64_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 701 | /*Type=*/FuncTy_22, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 702 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 703 | /*Name=*/"art_set64_instance_from_code", mod); // (external, no body) |
| 704 | func_art_set64_instance_from_code->setCallingConv(CallingConv::C); |
| 705 | } |
| 706 | AttrListPtr func_art_set64_instance_from_code_PAL; |
| 707 | func_art_set64_instance_from_code->setAttributes(func_art_set64_instance_from_code_PAL); |
| 708 | |
| 709 | Function* func_art_set_obj_instance_from_code = mod->getFunction("art_set_obj_instance_from_code"); |
| 710 | if (!func_art_set_obj_instance_from_code) { |
| 711 | func_art_set_obj_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 712 | /*Type=*/FuncTy_23, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 713 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 714 | /*Name=*/"art_set_obj_instance_from_code", mod); // (external, no body) |
| 715 | func_art_set_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 716 | } |
| 717 | AttrListPtr func_art_set_obj_instance_from_code_PAL; |
| 718 | func_art_set_obj_instance_from_code->setAttributes(func_art_set_obj_instance_from_code_PAL); |
| 719 | |
| 720 | Function* func_art_get32_instance_from_code = mod->getFunction("art_get32_instance_from_code"); |
| 721 | if (!func_art_get32_instance_from_code) { |
| 722 | func_art_get32_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 723 | /*Type=*/FuncTy_18, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 724 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 725 | /*Name=*/"art_get32_instance_from_code", mod); // (external, no body) |
| 726 | func_art_get32_instance_from_code->setCallingConv(CallingConv::C); |
| 727 | } |
| 728 | AttrListPtr func_art_get32_instance_from_code_PAL; |
| 729 | func_art_get32_instance_from_code->setAttributes(func_art_get32_instance_from_code_PAL); |
| 730 | |
| 731 | Function* func_art_get64_instance_from_code = mod->getFunction("art_get64_instance_from_code"); |
| 732 | if (!func_art_get64_instance_from_code) { |
| 733 | func_art_get64_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 734 | /*Type=*/FuncTy_24, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 735 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 736 | /*Name=*/"art_get64_instance_from_code", mod); // (external, no body) |
| 737 | func_art_get64_instance_from_code->setCallingConv(CallingConv::C); |
| 738 | } |
| 739 | AttrListPtr func_art_get64_instance_from_code_PAL; |
| 740 | func_art_get64_instance_from_code->setAttributes(func_art_get64_instance_from_code_PAL); |
| 741 | |
| 742 | Function* func_art_get_obj_instance_from_code = mod->getFunction("art_get_obj_instance_from_code"); |
| 743 | if (!func_art_get_obj_instance_from_code) { |
| 744 | func_art_get_obj_instance_from_code = Function::Create( |
Logan Chien | 1b0a1b7 | 2012-03-15 06:20:17 +0800 | [diff] [blame] | 745 | /*Type=*/FuncTy_14, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 746 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 747 | /*Name=*/"art_get_obj_instance_from_code", mod); // (external, no body) |
| 748 | func_art_get_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 749 | } |
| 750 | AttrListPtr func_art_get_obj_instance_from_code_PAL; |
| 751 | func_art_get_obj_instance_from_code->setAttributes(func_art_get_obj_instance_from_code_PAL); |
| 752 | |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 753 | Function* func_art_decode_jobject_in_thread = mod->getFunction("art_decode_jobject_in_thread"); |
| 754 | if (!func_art_decode_jobject_in_thread) { |
| 755 | func_art_decode_jobject_in_thread = Function::Create( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 756 | /*Type=*/FuncTy_25, |
TDYa127 | 28f1a14 | 2012-03-15 21:51:52 -0700 | [diff] [blame] | 757 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 758 | /*Name=*/"art_decode_jobject_in_thread", mod); // (external, no body) |
| 759 | func_art_decode_jobject_in_thread->setCallingConv(CallingConv::C); |
| 760 | } |
| 761 | AttrListPtr func_art_decode_jobject_in_thread_PAL; |
| 762 | func_art_decode_jobject_in_thread->setAttributes(func_art_decode_jobject_in_thread_PAL); |
| 763 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 764 | Function* func_art_is_assignable_from_code = mod->getFunction("art_is_assignable_from_code"); |
| 765 | if (!func_art_is_assignable_from_code) { |
| 766 | func_art_is_assignable_from_code = Function::Create( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 767 | /*Type=*/FuncTy_26, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 768 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 769 | /*Name=*/"art_is_assignable_from_code", mod); // (external, no body) |
| 770 | func_art_is_assignable_from_code->setCallingConv(CallingConv::C); |
| 771 | } |
| 772 | AttrListPtr func_art_is_assignable_from_code_PAL; |
| 773 | func_art_is_assignable_from_code->setAttributes(func_art_is_assignable_from_code_PAL); |
| 774 | |
| 775 | Function* func_art_check_cast_from_code = mod->getFunction("art_check_cast_from_code"); |
| 776 | if (!func_art_check_cast_from_code) { |
| 777 | func_art_check_cast_from_code = Function::Create( |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 778 | /*Type=*/FuncTy_27, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 779 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 780 | /*Name=*/"art_check_cast_from_code", mod); // (external, no body) |
| 781 | func_art_check_cast_from_code->setCallingConv(CallingConv::C); |
| 782 | } |
| 783 | AttrListPtr func_art_check_cast_from_code_PAL; |
| 784 | func_art_check_cast_from_code->setAttributes(func_art_check_cast_from_code_PAL); |
| 785 | |
TDYa127 | 1b86d07 | 2012-04-05 17:38:56 -0700 | [diff] [blame] | 786 | Function* func_art_check_put_array_element_from_code = mod->getFunction("art_check_put_array_element_from_code"); |
| 787 | if (!func_art_check_put_array_element_from_code) { |
| 788 | func_art_check_put_array_element_from_code = Function::Create( |
| 789 | /*Type=*/FuncTy_27, |
| 790 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 791 | /*Name=*/"art_check_put_array_element_from_code", mod); // (external, no body) |
| 792 | func_art_check_put_array_element_from_code->setCallingConv(CallingConv::C); |
| 793 | } |
| 794 | AttrListPtr func_art_check_put_array_element_from_code_PAL; |
| 795 | func_art_check_put_array_element_from_code->setAttributes(func_art_check_put_array_element_from_code_PAL); |
| 796 | |
TDYa127 | 8532191 | 2012-04-01 15:24:56 -0700 | [diff] [blame] | 797 | Function* func_art_ensure_link_from_code = mod->getFunction("art_ensure_link_from_code"); |
| 798 | if (!func_art_ensure_link_from_code) { |
| 799 | func_art_ensure_link_from_code = Function::Create( |
| 800 | /*Type=*/FuncTy_4, |
| 801 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 802 | /*Name=*/"art_ensure_link_from_code", mod); // (external, no body) |
| 803 | func_art_ensure_link_from_code->setCallingConv(CallingConv::C); |
| 804 | } |
| 805 | AttrListPtr func_art_ensure_link_from_code_PAL; |
| 806 | func_art_ensure_link_from_code->setAttributes(func_art_ensure_link_from_code_PAL); |
| 807 | |
| 808 | Function* func_art_ensure_resolved_from_code = mod->getFunction("art_ensure_resolved_from_code"); |
| 809 | if (!func_art_ensure_resolved_from_code) { |
| 810 | func_art_ensure_resolved_from_code = Function::Create( |
| 811 | /*Type=*/FuncTy_28, |
| 812 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 813 | /*Name=*/"art_ensure_resolved_from_code", mod); // (external, no body) |
| 814 | func_art_ensure_resolved_from_code->setCallingConv(CallingConv::C); |
| 815 | } |
| 816 | AttrListPtr func_art_ensure_resolved_from_code_PAL; |
| 817 | func_art_ensure_resolved_from_code->setAttributes(func_art_ensure_resolved_from_code_PAL); |
| 818 | |
| 819 | Function* func_art_ensure_initialized_from_code = mod->getFunction("art_ensure_initialized_from_code"); |
| 820 | if (!func_art_ensure_initialized_from_code) { |
| 821 | func_art_ensure_initialized_from_code = Function::Create( |
| 822 | /*Type=*/FuncTy_25, |
| 823 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 824 | /*Name=*/"art_ensure_initialized_from_code", mod); // (external, no body) |
| 825 | func_art_ensure_initialized_from_code->setCallingConv(CallingConv::C); |
| 826 | } |
| 827 | AttrListPtr func_art_ensure_initialized_from_code_PAL; |
| 828 | func_art_ensure_initialized_from_code->setAttributes(func_art_ensure_initialized_from_code_PAL); |
| 829 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 830 | // Global Variable Declarations |
| 831 | |
| 832 | |
| 833 | // Constant Definitions |
| 834 | |
| 835 | // Global Variable Definitions |
| 836 | |
| 837 | // Function Definitions |
| 838 | |
| 839 | return mod; |
| 840 | |
| 841 | } |
Logan Chien | e75a8cc | 2012-02-24 12:26:43 +0800 | [diff] [blame] | 842 | |
| 843 | } // namespace compiler_llvm |
| 844 | } // namespace art |