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 | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 42 | StructType *StructTy_ArtFrame = mod->getTypeByName("ArtFrame"); |
| 43 | if (!StructTy_ArtFrame) { |
| 44 | StructTy_ArtFrame = StructType::create(mod->getContext(), "ArtFrame"); |
| 45 | } |
| 46 | std::vector<Type*>StructTy_ArtFrame_fields; |
| 47 | PointerType* PointerTy_2 = PointerType::get(StructTy_ArtFrame, 0); |
| 48 | |
| 49 | StructTy_ArtFrame_fields.push_back(PointerTy_2); |
| 50 | StructTy_ArtFrame_fields.push_back(PointerTy_1); |
| 51 | StructTy_ArtFrame_fields.push_back(IntegerType::get(mod->getContext(), 32)); |
| 52 | StructTy_ArtFrame_fields.push_back(IntegerType::get(mod->getContext(), 32)); |
| 53 | if (StructTy_ArtFrame->isOpaque()) { |
| 54 | StructTy_ArtFrame->setBody(StructTy_ArtFrame_fields, /*isPacked=*/false); |
| 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 | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 145 | FuncTy_14_args.push_back(PointerTy_1); |
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 | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 147 | FunctionType* FuncTy_14 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 148 | /*Result=*/PointerTy_1, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 149 | /*Params=*/FuncTy_14_args, |
| 150 | /*isVarArg=*/false); |
| 151 | |
| 152 | std::vector<Type*>FuncTy_15_args; |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 153 | FuncTy_15_args.push_back(PointerTy_1); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 154 | FuncTy_15_args.push_back(IntegerType::get(mod->getContext(), 32)); |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 155 | FuncTy_15_args.push_back(IntegerType::get(mod->getContext(), 1)); |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 156 | FunctionType* FuncTy_15 = FunctionType::get( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +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 | 3f71e70 | 2012-02-17 18:45:27 +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 | 3f71e70 | 2012-02-17 18:45:27 +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); |
| 182 | FuncTy_18_args.push_back(PointerTy_1); |
| 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 | 3f71e70 | 2012-02-17 18:45:27 +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; |
| 197 | FuncTy_20_args.push_back(IntegerType::get(mod->getContext(), 32)); |
| 198 | FuncTy_20_args.push_back(PointerTy_1); |
| 199 | FunctionType* FuncTy_20 = FunctionType::get( |
| 200 | /*Result=*/IntegerType::get(mod->getContext(), 64), |
| 201 | /*Params=*/FuncTy_20_args, |
| 202 | /*isVarArg=*/false); |
| 203 | |
| 204 | std::vector<Type*>FuncTy_21_args; |
| 205 | FuncTy_21_args.push_back(PointerTy_1); |
| 206 | FuncTy_21_args.push_back(PointerTy_1); |
| 207 | FunctionType* FuncTy_21 = FunctionType::get( |
| 208 | /*Result=*/IntegerType::get(mod->getContext(), 32), |
| 209 | /*Params=*/FuncTy_21_args, |
| 210 | /*isVarArg=*/false); |
| 211 | |
| 212 | std::vector<Type*>FuncTy_22_args; |
| 213 | FuncTy_22_args.push_back(PointerTy_1); |
| 214 | FuncTy_22_args.push_back(PointerTy_1); |
| 215 | FunctionType* FuncTy_22 = FunctionType::get( |
| 216 | /*Result=*/Type::getVoidTy(mod->getContext()), |
| 217 | /*Params=*/FuncTy_22_args, |
| 218 | /*isVarArg=*/false); |
| 219 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 220 | |
| 221 | // Function Declarations |
| 222 | |
| 223 | Function* func___art_type_list = mod->getFunction("__art_type_list"); |
| 224 | if (!func___art_type_list) { |
| 225 | func___art_type_list = Function::Create( |
| 226 | /*Type=*/FuncTy_0, |
| 227 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 228 | /*Name=*/"__art_type_list", mod); // (external, no body) |
| 229 | func___art_type_list->setCallingConv(CallingConv::C); |
| 230 | } |
| 231 | AttrListPtr func___art_type_list_PAL; |
| 232 | func___art_type_list->setAttributes(func___art_type_list_PAL); |
| 233 | |
| 234 | Function* func_art_get_current_thread_from_code = mod->getFunction("art_get_current_thread_from_code"); |
| 235 | if (!func_art_get_current_thread_from_code) { |
| 236 | func_art_get_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 237 | /*Type=*/FuncTy_3, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 238 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 239 | /*Name=*/"art_get_current_thread_from_code", mod); // (external, no body) |
| 240 | func_art_get_current_thread_from_code->setCallingConv(CallingConv::C); |
| 241 | } |
| 242 | AttrListPtr func_art_get_current_thread_from_code_PAL; |
| 243 | func_art_get_current_thread_from_code->setAttributes(func_art_get_current_thread_from_code_PAL); |
| 244 | |
| 245 | Function* func_art_set_current_thread_from_code = mod->getFunction("art_set_current_thread_from_code"); |
| 246 | if (!func_art_set_current_thread_from_code) { |
| 247 | func_art_set_current_thread_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 248 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 249 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 250 | /*Name=*/"art_set_current_thread_from_code", mod); // (external, no body) |
| 251 | func_art_set_current_thread_from_code->setCallingConv(CallingConv::C); |
| 252 | } |
| 253 | AttrListPtr func_art_set_current_thread_from_code_PAL; |
| 254 | func_art_set_current_thread_from_code->setAttributes(func_art_set_current_thread_from_code_PAL); |
| 255 | |
| 256 | Function* func_art_lock_object_from_code = mod->getFunction("art_lock_object_from_code"); |
| 257 | if (!func_art_lock_object_from_code) { |
| 258 | func_art_lock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 259 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 260 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 261 | /*Name=*/"art_lock_object_from_code", mod); // (external, no body) |
| 262 | func_art_lock_object_from_code->setCallingConv(CallingConv::C); |
| 263 | } |
| 264 | AttrListPtr func_art_lock_object_from_code_PAL; |
| 265 | func_art_lock_object_from_code->setAttributes(func_art_lock_object_from_code_PAL); |
| 266 | |
| 267 | Function* func_art_unlock_object_from_code = mod->getFunction("art_unlock_object_from_code"); |
| 268 | if (!func_art_unlock_object_from_code) { |
| 269 | func_art_unlock_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 270 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 271 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 272 | /*Name=*/"art_unlock_object_from_code", mod); // (external, no body) |
| 273 | func_art_unlock_object_from_code->setCallingConv(CallingConv::C); |
| 274 | } |
| 275 | AttrListPtr func_art_unlock_object_from_code_PAL; |
| 276 | func_art_unlock_object_from_code->setAttributes(func_art_unlock_object_from_code_PAL); |
| 277 | |
| 278 | Function* func_art_test_suspend_from_code = mod->getFunction("art_test_suspend_from_code"); |
| 279 | if (!func_art_test_suspend_from_code) { |
| 280 | func_art_test_suspend_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 281 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 282 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 283 | /*Name=*/"art_test_suspend_from_code", mod); // (external, no body) |
| 284 | func_art_test_suspend_from_code->setCallingConv(CallingConv::C); |
| 285 | } |
| 286 | AttrListPtr func_art_test_suspend_from_code_PAL; |
| 287 | func_art_test_suspend_from_code->setAttributes(func_art_test_suspend_from_code_PAL); |
| 288 | |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 289 | Function* func_art_push_shadow_frame_from_code = mod->getFunction("art_push_shadow_frame_from_code"); |
| 290 | if (!func_art_push_shadow_frame_from_code) { |
| 291 | func_art_push_shadow_frame_from_code = Function::Create( |
| 292 | /*Type=*/FuncTy_6, |
| 293 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 294 | /*Name=*/"art_push_shadow_frame_from_code", mod); // (external, no body) |
| 295 | func_art_push_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 296 | } |
| 297 | AttrListPtr func_art_push_shadow_frame_from_code_PAL; |
| 298 | func_art_push_shadow_frame_from_code->setAttributes(func_art_push_shadow_frame_from_code_PAL); |
| 299 | |
| 300 | Function* func_art_pop_shadow_frame_from_code = mod->getFunction("art_pop_shadow_frame_from_code"); |
| 301 | if (!func_art_pop_shadow_frame_from_code) { |
| 302 | func_art_pop_shadow_frame_from_code = Function::Create( |
| 303 | /*Type=*/FuncTy_5, |
| 304 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 305 | /*Name=*/"art_pop_shadow_frame_from_code", mod); // (external, no body) |
| 306 | func_art_pop_shadow_frame_from_code->setCallingConv(CallingConv::C); |
| 307 | } |
| 308 | AttrListPtr func_art_pop_shadow_frame_from_code_PAL; |
| 309 | func_art_pop_shadow_frame_from_code->setAttributes(func_art_pop_shadow_frame_from_code_PAL); |
| 310 | |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 311 | Function* func_art_is_exception_pending_from_code = mod->getFunction("art_is_exception_pending_from_code"); |
| 312 | if (!func_art_is_exception_pending_from_code) { |
| 313 | func_art_is_exception_pending_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 314 | /*Type=*/FuncTy_7, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 315 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 316 | /*Name=*/"art_is_exception_pending_from_code", mod); // (external, no body) |
| 317 | func_art_is_exception_pending_from_code->setCallingConv(CallingConv::C); |
| 318 | } |
| 319 | AttrListPtr func_art_is_exception_pending_from_code_PAL; |
| 320 | func_art_is_exception_pending_from_code->setAttributes(func_art_is_exception_pending_from_code_PAL); |
| 321 | |
| 322 | Function* func_art_throw_div_zero_from_code = mod->getFunction("art_throw_div_zero_from_code"); |
| 323 | if (!func_art_throw_div_zero_from_code) { |
| 324 | func_art_throw_div_zero_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 325 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 326 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 327 | /*Name=*/"art_throw_div_zero_from_code", mod); // (external, no body) |
| 328 | func_art_throw_div_zero_from_code->setCallingConv(CallingConv::C); |
| 329 | } |
| 330 | AttrListPtr func_art_throw_div_zero_from_code_PAL; |
| 331 | func_art_throw_div_zero_from_code->setAttributes(func_art_throw_div_zero_from_code_PAL); |
| 332 | |
| 333 | Function* func_art_throw_array_bounds_from_code = mod->getFunction("art_throw_array_bounds_from_code"); |
| 334 | if (!func_art_throw_array_bounds_from_code) { |
| 335 | func_art_throw_array_bounds_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 336 | /*Type=*/FuncTy_8, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 337 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 338 | /*Name=*/"art_throw_array_bounds_from_code", mod); // (external, no body) |
| 339 | func_art_throw_array_bounds_from_code->setCallingConv(CallingConv::C); |
| 340 | } |
| 341 | AttrListPtr func_art_throw_array_bounds_from_code_PAL; |
| 342 | func_art_throw_array_bounds_from_code->setAttributes(func_art_throw_array_bounds_from_code_PAL); |
| 343 | |
| 344 | Function* func_art_throw_no_such_method_from_code = mod->getFunction("art_throw_no_such_method_from_code"); |
| 345 | if (!func_art_throw_no_such_method_from_code) { |
| 346 | func_art_throw_no_such_method_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 347 | /*Type=*/FuncTy_9, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 348 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 349 | /*Name=*/"art_throw_no_such_method_from_code", mod); // (external, no body) |
| 350 | func_art_throw_no_such_method_from_code->setCallingConv(CallingConv::C); |
| 351 | } |
| 352 | AttrListPtr func_art_throw_no_such_method_from_code_PAL; |
| 353 | func_art_throw_no_such_method_from_code->setAttributes(func_art_throw_no_such_method_from_code_PAL); |
| 354 | |
| 355 | Function* func_art_throw_null_pointer_exception_from_code = mod->getFunction("art_throw_null_pointer_exception_from_code"); |
| 356 | if (!func_art_throw_null_pointer_exception_from_code) { |
| 357 | func_art_throw_null_pointer_exception_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 358 | /*Type=*/FuncTy_5, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 359 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 360 | /*Name=*/"art_throw_null_pointer_exception_from_code", mod); // (external, no body) |
| 361 | func_art_throw_null_pointer_exception_from_code->setCallingConv(CallingConv::C); |
| 362 | } |
| 363 | AttrListPtr func_art_throw_null_pointer_exception_from_code_PAL; |
| 364 | func_art_throw_null_pointer_exception_from_code->setAttributes(func_art_throw_null_pointer_exception_from_code_PAL); |
| 365 | |
| 366 | Function* func_art_throw_stack_overflow_from_code = mod->getFunction("art_throw_stack_overflow_from_code"); |
| 367 | if (!func_art_throw_stack_overflow_from_code) { |
| 368 | func_art_throw_stack_overflow_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 369 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 370 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 371 | /*Name=*/"art_throw_stack_overflow_from_code", mod); // (external, no body) |
| 372 | func_art_throw_stack_overflow_from_code->setCallingConv(CallingConv::C); |
| 373 | } |
| 374 | AttrListPtr func_art_throw_stack_overflow_from_code_PAL; |
| 375 | func_art_throw_stack_overflow_from_code->setAttributes(func_art_throw_stack_overflow_from_code_PAL); |
| 376 | |
| 377 | Function* func_art_throw_exception_from_code = mod->getFunction("art_throw_exception_from_code"); |
| 378 | if (!func_art_throw_exception_from_code) { |
| 379 | func_art_throw_exception_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 380 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 381 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 382 | /*Name=*/"art_throw_exception_from_code", mod); // (external, no body) |
| 383 | func_art_throw_exception_from_code->setCallingConv(CallingConv::C); |
| 384 | } |
| 385 | AttrListPtr func_art_throw_exception_from_code_PAL; |
| 386 | func_art_throw_exception_from_code->setAttributes(func_art_throw_exception_from_code_PAL); |
| 387 | |
| 388 | Function* func_art_find_catch_block_from_code = mod->getFunction("art_find_catch_block_from_code"); |
| 389 | if (!func_art_find_catch_block_from_code) { |
| 390 | func_art_find_catch_block_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 391 | /*Type=*/FuncTy_10, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 392 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 393 | /*Name=*/"art_find_catch_block_from_code", mod); // (external, no body) |
| 394 | func_art_find_catch_block_from_code->setCallingConv(CallingConv::C); |
| 395 | } |
| 396 | AttrListPtr func_art_find_catch_block_from_code_PAL; |
| 397 | func_art_find_catch_block_from_code->setAttributes(func_art_find_catch_block_from_code_PAL); |
| 398 | |
| 399 | Function* func_art_alloc_object_from_code = mod->getFunction("art_alloc_object_from_code"); |
| 400 | if (!func_art_alloc_object_from_code) { |
| 401 | func_art_alloc_object_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 402 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 403 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 404 | /*Name=*/"art_alloc_object_from_code", mod); // (external, no body) |
| 405 | func_art_alloc_object_from_code->setCallingConv(CallingConv::C); |
| 406 | } |
| 407 | AttrListPtr func_art_alloc_object_from_code_PAL; |
| 408 | func_art_alloc_object_from_code->setAttributes(func_art_alloc_object_from_code_PAL); |
| 409 | |
| 410 | Function* func_art_alloc_object_from_code_with_access_check = mod->getFunction("art_alloc_object_from_code_with_access_check"); |
| 411 | if (!func_art_alloc_object_from_code_with_access_check) { |
| 412 | func_art_alloc_object_from_code_with_access_check = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 413 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 414 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 415 | /*Name=*/"art_alloc_object_from_code_with_access_check", mod); // (external, no body) |
| 416 | func_art_alloc_object_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 417 | } |
| 418 | AttrListPtr func_art_alloc_object_from_code_with_access_check_PAL; |
| 419 | func_art_alloc_object_from_code_with_access_check->setAttributes(func_art_alloc_object_from_code_with_access_check_PAL); |
| 420 | |
| 421 | Function* func_art_alloc_array_from_code = mod->getFunction("art_alloc_array_from_code"); |
| 422 | if (!func_art_alloc_array_from_code) { |
| 423 | func_art_alloc_array_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 424 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 425 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 426 | /*Name=*/"art_alloc_array_from_code", mod); // (external, no body) |
| 427 | func_art_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 428 | } |
| 429 | AttrListPtr func_art_alloc_array_from_code_PAL; |
| 430 | func_art_alloc_array_from_code->setAttributes(func_art_alloc_array_from_code_PAL); |
| 431 | |
| 432 | Function* func_art_alloc_array_from_code_with_access_check = mod->getFunction("art_alloc_array_from_code_with_access_check"); |
| 433 | if (!func_art_alloc_array_from_code_with_access_check) { |
| 434 | func_art_alloc_array_from_code_with_access_check = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 435 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 436 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 437 | /*Name=*/"art_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 438 | func_art_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 439 | } |
| 440 | AttrListPtr func_art_alloc_array_from_code_with_access_check_PAL; |
| 441 | func_art_alloc_array_from_code_with_access_check->setAttributes(func_art_alloc_array_from_code_with_access_check_PAL); |
| 442 | |
| 443 | Function* func_art_check_and_alloc_array_from_code = mod->getFunction("art_check_and_alloc_array_from_code"); |
| 444 | if (!func_art_check_and_alloc_array_from_code) { |
| 445 | func_art_check_and_alloc_array_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 446 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 447 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 448 | /*Name=*/"art_check_and_alloc_array_from_code", mod); // (external, no body) |
| 449 | func_art_check_and_alloc_array_from_code->setCallingConv(CallingConv::C); |
| 450 | } |
| 451 | AttrListPtr func_art_check_and_alloc_array_from_code_PAL; |
| 452 | func_art_check_and_alloc_array_from_code->setAttributes(func_art_check_and_alloc_array_from_code_PAL); |
| 453 | |
| 454 | Function* func_art_check_and_alloc_array_from_code_with_access_check = mod->getFunction("art_check_and_alloc_array_from_code_with_access_check"); |
| 455 | if (!func_art_check_and_alloc_array_from_code_with_access_check) { |
| 456 | 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] | 457 | /*Type=*/FuncTy_12, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 458 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 459 | /*Name=*/"art_check_and_alloc_array_from_code_with_access_check", mod); // (external, no body) |
| 460 | func_art_check_and_alloc_array_from_code_with_access_check->setCallingConv(CallingConv::C); |
| 461 | } |
| 462 | AttrListPtr func_art_check_and_alloc_array_from_code_with_access_check_PAL; |
| 463 | func_art_check_and_alloc_array_from_code_with_access_check->setAttributes(func_art_check_and_alloc_array_from_code_with_access_check_PAL); |
| 464 | |
| 465 | Function* func_art_object_init_from_code = mod->getFunction("art_object_init_from_code"); |
| 466 | if (!func_art_object_init_from_code) { |
| 467 | func_art_object_init_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 468 | /*Type=*/FuncTy_4, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 469 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 470 | /*Name=*/"art_object_init_from_code", mod); // (external, no body) |
| 471 | func_art_object_init_from_code->setCallingConv(CallingConv::C); |
| 472 | } |
| 473 | AttrListPtr func_art_object_init_from_code_PAL; |
| 474 | func_art_object_init_from_code->setAttributes(func_art_object_init_from_code_PAL); |
| 475 | |
| 476 | Function* func_art_find_instance_field_from_code = mod->getFunction("art_find_instance_field_from_code"); |
| 477 | if (!func_art_find_instance_field_from_code) { |
| 478 | func_art_find_instance_field_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 479 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 480 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 481 | /*Name=*/"art_find_instance_field_from_code", mod); // (external, no body) |
| 482 | func_art_find_instance_field_from_code->setCallingConv(CallingConv::C); |
| 483 | } |
| 484 | AttrListPtr func_art_find_instance_field_from_code_PAL; |
| 485 | func_art_find_instance_field_from_code->setAttributes(func_art_find_instance_field_from_code_PAL); |
| 486 | |
| 487 | Function* func_art_find_static_field_from_code = mod->getFunction("art_find_static_field_from_code"); |
| 488 | if (!func_art_find_static_field_from_code) { |
| 489 | func_art_find_static_field_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 490 | /*Type=*/FuncTy_13, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 491 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 492 | /*Name=*/"art_find_static_field_from_code", mod); // (external, no body) |
| 493 | func_art_find_static_field_from_code->setCallingConv(CallingConv::C); |
| 494 | } |
| 495 | AttrListPtr func_art_find_static_field_from_code_PAL; |
| 496 | func_art_find_static_field_from_code->setAttributes(func_art_find_static_field_from_code_PAL); |
| 497 | |
| 498 | Function* func_art_find_interface_method_from_code = mod->getFunction("art_find_interface_method_from_code"); |
| 499 | if (!func_art_find_interface_method_from_code) { |
| 500 | func_art_find_interface_method_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 501 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 502 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 503 | /*Name=*/"art_find_interface_method_from_code", mod); // (external, no body) |
| 504 | func_art_find_interface_method_from_code->setCallingConv(CallingConv::C); |
| 505 | } |
| 506 | AttrListPtr func_art_find_interface_method_from_code_PAL; |
| 507 | func_art_find_interface_method_from_code->setAttributes(func_art_find_interface_method_from_code_PAL); |
| 508 | |
| 509 | Function* func_art_initialize_static_storage_from_code = mod->getFunction("art_initialize_static_storage_from_code"); |
| 510 | if (!func_art_initialize_static_storage_from_code) { |
| 511 | func_art_initialize_static_storage_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 512 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 513 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 514 | /*Name=*/"art_initialize_static_storage_from_code", mod); // (external, no body) |
| 515 | func_art_initialize_static_storage_from_code->setCallingConv(CallingConv::C); |
| 516 | } |
| 517 | AttrListPtr func_art_initialize_static_storage_from_code_PAL; |
| 518 | func_art_initialize_static_storage_from_code->setAttributes(func_art_initialize_static_storage_from_code_PAL); |
| 519 | |
| 520 | Function* func_art_initialize_type_from_code = mod->getFunction("art_initialize_type_from_code"); |
| 521 | if (!func_art_initialize_type_from_code) { |
| 522 | func_art_initialize_type_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 523 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 524 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 525 | /*Name=*/"art_initialize_type_from_code", mod); // (external, no body) |
| 526 | func_art_initialize_type_from_code->setCallingConv(CallingConv::C); |
| 527 | } |
| 528 | AttrListPtr func_art_initialize_type_from_code_PAL; |
| 529 | func_art_initialize_type_from_code->setAttributes(func_art_initialize_type_from_code_PAL); |
| 530 | |
| 531 | Function* func_art_initialize_type_and_verify_access_from_code = mod->getFunction("art_initialize_type_and_verify_access_from_code"); |
| 532 | if (!func_art_initialize_type_and_verify_access_from_code) { |
| 533 | func_art_initialize_type_and_verify_access_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 534 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 535 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 536 | /*Name=*/"art_initialize_type_and_verify_access_from_code", mod); // (external, no body) |
| 537 | func_art_initialize_type_and_verify_access_from_code->setCallingConv(CallingConv::C); |
| 538 | } |
| 539 | AttrListPtr func_art_initialize_type_and_verify_access_from_code_PAL; |
| 540 | func_art_initialize_type_and_verify_access_from_code->setAttributes(func_art_initialize_type_and_verify_access_from_code_PAL); |
| 541 | |
| 542 | Function* func_art_resolve_string_from_code = mod->getFunction("art_resolve_string_from_code"); |
| 543 | if (!func_art_resolve_string_from_code) { |
| 544 | func_art_resolve_string_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 545 | /*Type=*/FuncTy_14, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 546 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 547 | /*Name=*/"art_resolve_string_from_code", mod); // (external, no body) |
| 548 | func_art_resolve_string_from_code->setCallingConv(CallingConv::C); |
| 549 | } |
| 550 | AttrListPtr func_art_resolve_string_from_code_PAL; |
| 551 | func_art_resolve_string_from_code->setAttributes(func_art_resolve_string_from_code_PAL); |
| 552 | |
| 553 | Function* func_art_resolve_method_from_code = mod->getFunction("art_resolve_method_from_code"); |
| 554 | if (!func_art_resolve_method_from_code) { |
| 555 | func_art_resolve_method_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 556 | /*Type=*/FuncTy_15, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 557 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 558 | /*Name=*/"art_resolve_method_from_code", mod); // (external, no body) |
| 559 | func_art_resolve_method_from_code->setCallingConv(CallingConv::C); |
| 560 | } |
| 561 | AttrListPtr func_art_resolve_method_from_code_PAL; |
| 562 | func_art_resolve_method_from_code->setAttributes(func_art_resolve_method_from_code_PAL); |
| 563 | |
| 564 | Function* func_art_set32_static_from_code = mod->getFunction("art_set32_static_from_code"); |
| 565 | if (!func_art_set32_static_from_code) { |
| 566 | func_art_set32_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 567 | /*Type=*/FuncTy_16, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 568 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 569 | /*Name=*/"art_set32_static_from_code", mod); // (external, no body) |
| 570 | func_art_set32_static_from_code->setCallingConv(CallingConv::C); |
| 571 | } |
| 572 | AttrListPtr func_art_set32_static_from_code_PAL; |
| 573 | func_art_set32_static_from_code->setAttributes(func_art_set32_static_from_code_PAL); |
| 574 | |
| 575 | Function* func_art_set64_static_from_code = mod->getFunction("art_set64_static_from_code"); |
| 576 | if (!func_art_set64_static_from_code) { |
| 577 | func_art_set64_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 578 | /*Type=*/FuncTy_17, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 579 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 580 | /*Name=*/"art_set64_static_from_code", mod); // (external, no body) |
| 581 | func_art_set64_static_from_code->setCallingConv(CallingConv::C); |
| 582 | } |
| 583 | AttrListPtr func_art_set64_static_from_code_PAL; |
| 584 | func_art_set64_static_from_code->setAttributes(func_art_set64_static_from_code_PAL); |
| 585 | |
| 586 | Function* func_art_set_obj_static_from_code = mod->getFunction("art_set_obj_static_from_code"); |
| 587 | if (!func_art_set_obj_static_from_code) { |
| 588 | func_art_set_obj_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 589 | /*Type=*/FuncTy_18, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 590 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 591 | /*Name=*/"art_set_obj_static_from_code", mod); // (external, no body) |
| 592 | func_art_set_obj_static_from_code->setCallingConv(CallingConv::C); |
| 593 | } |
| 594 | AttrListPtr func_art_set_obj_static_from_code_PAL; |
| 595 | func_art_set_obj_static_from_code->setAttributes(func_art_set_obj_static_from_code_PAL); |
| 596 | |
| 597 | Function* func_art_get32_static_from_code = mod->getFunction("art_get32_static_from_code"); |
| 598 | if (!func_art_get32_static_from_code) { |
| 599 | func_art_get32_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 600 | /*Type=*/FuncTy_19, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 601 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 602 | /*Name=*/"art_get32_static_from_code", mod); // (external, no body) |
| 603 | func_art_get32_static_from_code->setCallingConv(CallingConv::C); |
| 604 | } |
| 605 | AttrListPtr func_art_get32_static_from_code_PAL; |
| 606 | func_art_get32_static_from_code->setAttributes(func_art_get32_static_from_code_PAL); |
| 607 | |
| 608 | Function* func_art_get64_static_from_code = mod->getFunction("art_get64_static_from_code"); |
| 609 | if (!func_art_get64_static_from_code) { |
| 610 | func_art_get64_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 611 | /*Type=*/FuncTy_20, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 612 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 613 | /*Name=*/"art_get64_static_from_code", mod); // (external, no body) |
| 614 | func_art_get64_static_from_code->setCallingConv(CallingConv::C); |
| 615 | } |
| 616 | AttrListPtr func_art_get64_static_from_code_PAL; |
| 617 | func_art_get64_static_from_code->setAttributes(func_art_get64_static_from_code_PAL); |
| 618 | |
| 619 | Function* func_art_get_obj_static_from_code = mod->getFunction("art_get_obj_static_from_code"); |
| 620 | if (!func_art_get_obj_static_from_code) { |
| 621 | func_art_get_obj_static_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 622 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 623 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 624 | /*Name=*/"art_get_obj_static_from_code", mod); // (external, no body) |
| 625 | func_art_get_obj_static_from_code->setCallingConv(CallingConv::C); |
| 626 | } |
| 627 | AttrListPtr func_art_get_obj_static_from_code_PAL; |
| 628 | func_art_get_obj_static_from_code->setAttributes(func_art_get_obj_static_from_code_PAL); |
| 629 | |
| 630 | Function* func_art_set32_instance_from_code = mod->getFunction("art_set32_instance_from_code"); |
| 631 | if (!func_art_set32_instance_from_code) { |
| 632 | func_art_set32_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 633 | /*Type=*/FuncTy_16, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 634 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 635 | /*Name=*/"art_set32_instance_from_code", mod); // (external, no body) |
| 636 | func_art_set32_instance_from_code->setCallingConv(CallingConv::C); |
| 637 | } |
| 638 | AttrListPtr func_art_set32_instance_from_code_PAL; |
| 639 | func_art_set32_instance_from_code->setAttributes(func_art_set32_instance_from_code_PAL); |
| 640 | |
| 641 | Function* func_art_set64_instance_from_code = mod->getFunction("art_set64_instance_from_code"); |
| 642 | if (!func_art_set64_instance_from_code) { |
| 643 | func_art_set64_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 644 | /*Type=*/FuncTy_17, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 645 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 646 | /*Name=*/"art_set64_instance_from_code", mod); // (external, no body) |
| 647 | func_art_set64_instance_from_code->setCallingConv(CallingConv::C); |
| 648 | } |
| 649 | AttrListPtr func_art_set64_instance_from_code_PAL; |
| 650 | func_art_set64_instance_from_code->setAttributes(func_art_set64_instance_from_code_PAL); |
| 651 | |
| 652 | Function* func_art_set_obj_instance_from_code = mod->getFunction("art_set_obj_instance_from_code"); |
| 653 | if (!func_art_set_obj_instance_from_code) { |
| 654 | func_art_set_obj_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 655 | /*Type=*/FuncTy_18, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 656 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 657 | /*Name=*/"art_set_obj_instance_from_code", mod); // (external, no body) |
| 658 | func_art_set_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 659 | } |
| 660 | AttrListPtr func_art_set_obj_instance_from_code_PAL; |
| 661 | func_art_set_obj_instance_from_code->setAttributes(func_art_set_obj_instance_from_code_PAL); |
| 662 | |
| 663 | Function* func_art_get32_instance_from_code = mod->getFunction("art_get32_instance_from_code"); |
| 664 | if (!func_art_get32_instance_from_code) { |
| 665 | func_art_get32_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 666 | /*Type=*/FuncTy_19, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 667 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 668 | /*Name=*/"art_get32_instance_from_code", mod); // (external, no body) |
| 669 | func_art_get32_instance_from_code->setCallingConv(CallingConv::C); |
| 670 | } |
| 671 | AttrListPtr func_art_get32_instance_from_code_PAL; |
| 672 | func_art_get32_instance_from_code->setAttributes(func_art_get32_instance_from_code_PAL); |
| 673 | |
| 674 | Function* func_art_get64_instance_from_code = mod->getFunction("art_get64_instance_from_code"); |
| 675 | if (!func_art_get64_instance_from_code) { |
| 676 | func_art_get64_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 677 | /*Type=*/FuncTy_20, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 678 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 679 | /*Name=*/"art_get64_instance_from_code", mod); // (external, no body) |
| 680 | func_art_get64_instance_from_code->setCallingConv(CallingConv::C); |
| 681 | } |
| 682 | AttrListPtr func_art_get64_instance_from_code_PAL; |
| 683 | func_art_get64_instance_from_code->setAttributes(func_art_get64_instance_from_code_PAL); |
| 684 | |
| 685 | Function* func_art_get_obj_instance_from_code = mod->getFunction("art_get_obj_instance_from_code"); |
| 686 | if (!func_art_get_obj_instance_from_code) { |
| 687 | func_art_get_obj_instance_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 688 | /*Type=*/FuncTy_11, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 689 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 690 | /*Name=*/"art_get_obj_instance_from_code", mod); // (external, no body) |
| 691 | func_art_get_obj_instance_from_code->setCallingConv(CallingConv::C); |
| 692 | } |
| 693 | AttrListPtr func_art_get_obj_instance_from_code_PAL; |
| 694 | func_art_get_obj_instance_from_code->setAttributes(func_art_get_obj_instance_from_code_PAL); |
| 695 | |
| 696 | Function* func_art_is_assignable_from_code = mod->getFunction("art_is_assignable_from_code"); |
| 697 | if (!func_art_is_assignable_from_code) { |
| 698 | func_art_is_assignable_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 699 | /*Type=*/FuncTy_21, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 700 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 701 | /*Name=*/"art_is_assignable_from_code", mod); // (external, no body) |
| 702 | func_art_is_assignable_from_code->setCallingConv(CallingConv::C); |
| 703 | } |
| 704 | AttrListPtr func_art_is_assignable_from_code_PAL; |
| 705 | func_art_is_assignable_from_code->setAttributes(func_art_is_assignable_from_code_PAL); |
| 706 | |
| 707 | Function* func_art_check_cast_from_code = mod->getFunction("art_check_cast_from_code"); |
| 708 | if (!func_art_check_cast_from_code) { |
| 709 | func_art_check_cast_from_code = Function::Create( |
Logan Chien | 3f71e70 | 2012-02-17 18:45:27 +0800 | [diff] [blame] | 710 | /*Type=*/FuncTy_22, |
Logan Chien | 42e0e15 | 2012-01-13 15:42:36 +0800 | [diff] [blame] | 711 | /*Linkage=*/GlobalValue::ExternalLinkage, |
| 712 | /*Name=*/"art_check_cast_from_code", mod); // (external, no body) |
| 713 | func_art_check_cast_from_code->setCallingConv(CallingConv::C); |
| 714 | } |
| 715 | AttrListPtr func_art_check_cast_from_code_PAL; |
| 716 | func_art_check_cast_from_code->setAttributes(func_art_check_cast_from_code_PAL); |
| 717 | |
| 718 | // Global Variable Declarations |
| 719 | |
| 720 | |
| 721 | // Constant Definitions |
| 722 | |
| 723 | // Global Variable Definitions |
| 724 | |
| 725 | // Function Definitions |
| 726 | |
| 727 | return mod; |
| 728 | |
| 729 | } |
Logan Chien | e75a8cc | 2012-02-24 12:26:43 +0800 | [diff] [blame] | 730 | |
| 731 | } // namespace compiler_llvm |
| 732 | } // namespace art |