/art/compiler/llvm/ |
D | ir_builder.h | 38 namespace llvm { 40 class InserterWithDexOffset : public ::llvm::IRBuilderDefaultInserter<true> { 44 void InsertHelper(::llvm::Instruction *I, const ::llvm::Twine &Name, in InsertHelper() 45 ::llvm::BasicBlock *BB, in InsertHelper() 46 ::llvm::BasicBlock::iterator InsertPt) const { in InsertHelper() 47 ::llvm::IRBuilderDefaultInserter<true>::InsertHelper(I, Name, BB, InsertPt); in InsertHelper() 53 void SetDexOffset(::llvm::MDNode* node) { in SetDexOffset() 57 ::llvm::MDNode* node_; 60 typedef ::llvm::IRBuilder<true, ::llvm::ConstantFolder, InserterWithDexOffset> LLVMIRBuilder; 71 IRBuilder(::llvm::LLVMContext& context, ::llvm::Module& module, [all …]
|
D | gbc_expander.cc | 48 using ::art::llvm::IRBuilder; 49 using ::art::llvm::IntrinsicHelper; 50 using ::art::llvm::JType; 51 using ::art::llvm::RuntimeSupportBuilder; 52 using ::art::llvm::kBoolean; 53 using ::art::llvm::kByte; 54 using ::art::llvm::kChar; 55 using ::art::llvm::kDouble; 56 using ::art::llvm::kFloat; 57 using ::art::llvm::kInt; [all …]
|
D | runtime_support_builder.h | 26 namespace llvm { 35 namespace llvm { 42 RuntimeSupportBuilder(::llvm::LLVMContext& context, ::llvm::Module& module, IRBuilder& irb); 45 virtual ::llvm::Value* EmitGetCurrentThread(); 46 virtual ::llvm::Value* EmitLoadFromThreadOffset(int64_t offset, ::llvm::Type* type, 48 virtual void EmitStoreToThreadOffset(int64_t offset, ::llvm::Value* value, 50 virtual ::llvm::Value* EmitSetCurrentThread(::llvm::Value* thread); 53 virtual ::llvm::Value* EmitPushShadowFrame(::llvm::Value* new_shadow_frame, 54 ::llvm::Value* method, uint32_t num_vregs); 55 virtual ::llvm::Value* EmitPushShadowFrameNoInline(::llvm::Value* new_shadow_frame, [all …]
|
D | llvm_compilation_unit.cc | 89 namespace llvm { namespace 91 ::llvm::FunctionPass* 95 ::llvm::Module* makeLLVMModuleContents(::llvm::Module* module); 134 ::llvm::LLVMContext* llvm_context = context_.release(); // Managed by llvm_info_ in ~LlvmCompilationUnit() 161 ::llvm::raw_string_ostream str_os(str_buffer); in DumpBitcodeToString() 162 ::llvm::WriteBitcodeToFile(module_, str_os); in DumpBitcodeToString() 192 ::llvm::raw_string_ostream str_os(str_buffer); in MaterializeToString() 197 bool LlvmCompilationUnit::MaterializeToRawOStream(::llvm::raw_ostream& out_stream) { in MaterializeToRawOStream() 206 const ::llvm::Target* target = in MaterializeToRawOStream() 207 ::llvm::TargetRegistry::lookupTarget(target_triple, errmsg); in MaterializeToRawOStream() [all …]
|
D | compiler_llvm.cc | 50 namespace llvm { namespace 60 llvm::llvm_start_multithreaded(); in InitializeLLVM() 66 art::llvm::InitialBackendOptions(); in InitializeLLVM() 71 llvm::InitializeNativeTarget(); in InitializeLLVM() 72 llvm::InitializeNativeTargetAsmPrinter(); in InitializeLLVM() 73 llvm::InitializeNativeTargetAsmParser(); in InitializeLLVM() 75 llvm::InitializeAllTargets(); in InitializeLLVM() 76 llvm::InitializeAllTargetMCs(); in InitializeLLVM() 77 llvm::InitializeAllAsmPrinters(); in InitializeLLVM() 78 llvm::InitializeAllAsmParsers(); in InitializeLLVM() [all …]
|
D | runtime_support_builder.cc | 31 using ::llvm::BasicBlock; 32 using ::llvm::CallInst; 33 using ::llvm::Function; 34 using ::llvm::Value; 37 namespace llvm { namespace 39 RuntimeSupportBuilder::RuntimeSupportBuilder(::llvm::LLVMContext& context, in RuntimeSupportBuilder() 40 ::llvm::Module& module, in RuntimeSupportBuilder() 46 ::llvm::Function* fn = module_.getFunction(#NAME); \ in RuntimeSupportBuilder() 57 ::llvm::Value* RuntimeSupportBuilder::EmitGetCurrentThread() { in EmitGetCurrentThread() 65 ::llvm::Value* RuntimeSupportBuilder::EmitLoadFromThreadOffset(int64_t offset, ::llvm::Type* type, in EmitLoadFromThreadOffset() [all …]
|
D | ir_builder.cc | 24 namespace llvm { namespace 31 IRBuilder::IRBuilder(::llvm::LLVMContext& context, ::llvm::Module& module, in IRBuilder() 36 ::llvm::Type* jobject_struct_type = module.getTypeByName("JavaObject"); in IRBuilder() 41 ::llvm::Type* type = module.getTypeByName("Method"); in IRBuilder() 57 ::llvm::Type* jenv_struct_type = ::llvm::StructType::create(context, "JEnv"); in IRBuilder() 72 ::llvm::Type* IRBuilder::getJType(JType jty) { in getJType() 110 ::llvm::StructType* IRBuilder::getShadowFrameTy(uint32_t vreg_size) { in getShadowFrameTy() 114 if (::llvm::Type* type = module_->getTypeByName(name)) { in getShadowFrameTy() 115 CHECK(::llvm::isa< ::llvm::StructType>(type)); in getShadowFrameTy() 116 return static_cast< ::llvm::StructType*>(type); in getShadowFrameTy() [all …]
|
D | intrinsic_helper.cc | 28 namespace llvm { namespace 40 static ::llvm::Type* GetLLVMTypeOfIntrinsicValType(IRBuilder& irb, in GetLLVMTypeOfIntrinsicValType() 93 IntrinsicHelper::IntrinsicHelper(::llvm::LLVMContext& context, in IntrinsicHelper() 94 ::llvm::Module& module) { in IntrinsicHelper() 109 ::llvm::Type* arg_type[kIntrinsicMaxArgc]; in IntrinsicHelper() 127 ::llvm::Type* ret_type = in IntrinsicHelper() 130 ::llvm::FunctionType* type = in IntrinsicHelper() 131 ::llvm::FunctionType::get(ret_type, in IntrinsicHelper() 132 ::llvm::ArrayRef< ::llvm::Type*>(arg_type, num_args), in IntrinsicHelper() 136 ::llvm::Function *fn = ::llvm::Function::Create(type, in IntrinsicHelper() [all …]
|
D | md_builder.h | 26 namespace llvm { 32 namespace llvm { 34 typedef ::llvm::MDBuilder LLVMMDBuilder; 38 explicit MDBuilder(::llvm::LLVMContext& context) in MDBuilder() 49 ::llvm::MDNode* GetTBAASpecialType(TBAASpecialType special_ty); 50 ::llvm::MDNode* GetTBAAMemoryJType(TBAASpecialType special_ty, JType j_ty); 52 ::llvm::MDNode* GetBranchWeights(ExpectCond expect) { in GetBranchWeights() 58 ::llvm::MDNode* const tbaa_root_; 59 ::llvm::MDNode* tbaa_special_type_[MAX_TBAA_SPECIAL_TYPE]; 62 ::llvm::MDNode* tbaa_memory_jtype_[3][MAX_JTYPE]; [all …]
|
D | runtime_support_builder_arm.h | 23 namespace llvm { 27 RuntimeSupportBuilderARM(::llvm::LLVMContext& context, ::llvm::Module& module, IRBuilder& irb) in RuntimeSupportBuilderARM() 31 virtual ::llvm::Value* EmitGetCurrentThread(); 32 virtual ::llvm::Value* EmitLoadFromThreadOffset(int64_t offset, ::llvm::Type* type, 34 virtual void EmitStoreToThreadOffset(int64_t offset, ::llvm::Value* value, 36 virtual ::llvm::Value* EmitSetCurrentThread(::llvm::Value* thread);
|
D | runtime_support_builder_x86.h | 23 namespace llvm { 27 RuntimeSupportBuilderX86(::llvm::LLVMContext& context, ::llvm::Module& module, IRBuilder& irb) in RuntimeSupportBuilderX86() 31 virtual ::llvm::Value* EmitGetCurrentThread(); 32 virtual ::llvm::Value* EmitLoadFromThreadOffset(int64_t offset, ::llvm::Type* type, 34 virtual void EmitStoreToThreadOffset(int64_t offset, ::llvm::Value* value, 36 virtual ::llvm::Value* EmitSetCurrentThread(::llvm::Value* thread);
|
D | intrinsic_helper.h | 24 namespace llvm { 32 namespace llvm { 126 IntrinsicHelper(::llvm::LLVMContext& context, ::llvm::Module& module); 128 ::llvm::Function* GetIntrinsicFunction(IntrinsicId id) { in GetIntrinsicFunction() 134 IntrinsicId GetIntrinsicId(const ::llvm::Function* func) const { in GetIntrinsicId() 135 ::llvm::DenseMap<const ::llvm::Function*, IntrinsicId>::const_iterator in GetIntrinsicId() 148 ::llvm::Function* intrinsic_funcs_[MaxIntrinsicId + 1]; 151 ::llvm::DenseMap<const ::llvm::Function*, IntrinsicId> intrinsic_funcs_map_;
|
D | runtime_support_builder_arm.cc | 31 using ::llvm::CallInst; 32 using ::llvm::Function; 33 using ::llvm::FunctionType; 34 using ::llvm::InlineAsm; 35 using ::llvm::IntegerType; 36 using ::llvm::Type; 37 using ::llvm::Value; 41 char LDRSTRSuffixByType(art::llvm::IRBuilder& irb, Type* type) { in LDRSTRSuffixByType() 44 ::llvm::cast<IntegerType>(type)->getBitWidth(); in LDRSTRSuffixByType() 58 namespace llvm { namespace [all …]
|
D | runtime_support_builder_x86.cc | 32 using ::llvm::CallInst; 33 using ::llvm::Function; 34 using ::llvm::FunctionType; 35 using ::llvm::InlineAsm; 36 using ::llvm::Type; 37 using ::llvm::UndefValue; 38 using ::llvm::Value; 41 namespace llvm { namespace
|
D | llvm_compilation_unit.h | 39 namespace llvm { 47 namespace llvm { 62 ::llvm::LLVMContext* GetLLVMContext() const { in GetLLVMContext() 66 ::llvm::Module* GetModule() const { in GetModule() 109 std::unique_ptr< ::llvm::LLVMContext> context_; 112 ::llvm::Module* module_; // Managed by context_ 122 SafeMap<const ::llvm::Function*, CompiledMethod*> compiled_methods_map_; 130 bool MaterializeToRawOStream(::llvm::raw_ostream& out_stream);
|
D | md_builder.cc | 25 namespace llvm { namespace 28 ::llvm::MDNode* MDBuilder::GetTBAASpecialType(TBAASpecialType sty_id) { in GetTBAASpecialType() 33 ::llvm::MDNode*& spec_ty = tbaa_special_type_[sty_id]; in GetTBAASpecialType() 71 ::llvm::MDNode* MDBuilder::GetTBAAMemoryJType(TBAASpecialType sty_id, JType jty_id) { in GetTBAAMemoryJType() 91 ::llvm::MDNode*& spec_ty = tbaa_memory_jtype_[sty_mapped_index][jty_id]; in GetTBAAMemoryJType()
|
D | backend_options.h | 23 extern llvm::cl::opt<bool> EnableARMLongCalls; \ 24 extern llvm::cl::opt<bool> ReserveR9; 40 namespace llvm {
|
/art/compiler/dex/portable/ |
D | mir_to_gbc.h | 48 llvm::LlvmCompilationUnit* const llvm_compilation_unit); 54 llvm::LlvmCompilationUnit* llvm_compilation_unit) in MirConverter() 86 ::llvm::BasicBlock* GetLLVMBlock(int id); 87 ::llvm::Value* GetLLVMValue(int s_reg); 88 void SetVregOnValue(::llvm::Value* val, int s_reg); 89 void DefineValueOnly(::llvm::Value* val, int s_reg); 90 void DefineValue(::llvm::Value* val, int s_reg); 91 ::llvm::Type* LlvmTypeFromLocRec(RegLocation loc); 93 ::llvm::BasicBlock* FindCaseTarget(uint32_t vaddr); 99 art::llvm::IntrinsicHelper::IntrinsicId id, RegLocation rl_dest); [all …]
|
D | mir_to_gbc.cc | 45 namespace llvm { namespace 46 ::llvm::Module* makeLLVMModuleContents(::llvm::Module* module); 51 llvm_context_.reset(new ::llvm::LLVMContext()); in LLVMInfo() 52 llvm_module_ = new ::llvm::Module("art", *llvm_context_); in LLVMInfo() 53 ::llvm::StructType::create(*llvm_context_, "JavaObject"); in LLVMInfo() 54 art::llvm::makeLLVMModuleContents(llvm_module_); in LLVMInfo() 55 intrinsic_helper_.reset(new art::llvm::IntrinsicHelper(*llvm_context_, *llvm_module_)); in LLVMInfo() 56 ir_builder_.reset(new art::llvm::IRBuilder(*llvm_context_, *llvm_module_, *intrinsic_helper_)); in LLVMInfo() 62 ::llvm::BasicBlock* MirConverter::GetLLVMBlock(int id) { in GetLLVMBlock() 66 ::llvm::Value* MirConverter::GetLLVMValue(int s_reg) { in GetLLVMValue() [all …]
|
/art/compiler/sea_ir/code_gen/ |
D | code_gen_data.cc | 34 ::llvm::raw_string_ostream out_stream(elf); in GetElf() 43 const ::llvm::Target* target = in GetElf() 44 ::llvm::TargetRegistry::lookupTarget(target_triple, errmsg); in GetElf() 49 ::llvm::TargetOptions target_options; in GetElf() 50 target_options.FloatABIType = ::llvm::FloatABI::Soft; in GetElf() 57 ::llvm::OwningPtr< ::llvm::TargetMachine> target_machine( in GetElf() 59 ::llvm::Reloc::Static, ::llvm::CodeModel::Small, in GetElf() 60 ::llvm::CodeGenOpt::Aggressive)); in GetElf() 65 const ::llvm::DataLayout* data_layout = target_machine->getDataLayout(); in GetElf() 68 ::llvm::PassManager pm; in GetElf() [all …]
|
D | code_gen.cc | 34 llvm::PHINode *llvm_phi = llvm_data_->builder_.CreatePHI( in Visit() 35 llvm::Type::getInt32Ty(*llvm_data_->context_), predecessors->size(), phi->StringId()); in Visit() 66 std::vector<llvm::Type*> parameter_types; in Visit() 72 parameter_types.push_back(llvm::Type::getInt32Ty(*llvm_data_->context_)); in Visit() 79 llvm::FunctionType *function_type = llvm::FunctionType::get( in Visit() 80 llvm::Type::getInt32Ty(*llvm_data_->context_), in Visit() 83 llvm_data_->function_ = llvm::Function::Create(function_type, in Visit() 84 llvm::Function::ExternalLinkage, function_name_, &llvm_data_->module_); in Visit() 86 for (llvm::Function::arg_iterator arg_it = llvm_data_->function_->arg_begin(); in Visit() 101 llvm::BasicBlock* new_basic_block = llvm::BasicBlock::Create(*llvm_data_->context_, in Visit() [all …]
|
D | code_gen.h | 32 explicit CodeGenData(): context_(&llvm::getGlobalContext()), module_("sea_ir", *context_), in CodeGenData() 35 llvm::BasicBlock* GetBlock(int region_id) { in GetBlock() 36 std::map<int, llvm::BasicBlock*>::iterator block_it = blocks_.find(region_id); in GetBlock() 41 llvm::BasicBlock* GetBlock(Region* region) { in GetBlock() 45 void AddBlock(int region_id, llvm::BasicBlock* block) { in AddBlock() 46 blocks_.insert(std::pair<int, llvm::BasicBlock*>(region_id, block)); in AddBlock() 49 void AddBlock(Region* region, llvm::BasicBlock* block) { in AddBlock() 53 llvm::Value* GetValue(int instruction_id) { in GetValue() 54 std::map<int, llvm::Value*>::iterator value_it = values_.find(instruction_id); in GetValue() 59 llvm::Value* GetValue(InstructionNode* instruction) { in GetValue() [all …]
|
/art/compiler/jni/portable/ |
D | jni_compiler.cc | 42 namespace llvm { namespace 44 using ::art::llvm::runtime_support::JniMethodEnd; 45 using ::art::llvm::runtime_support::JniMethodEndSynchronized; 46 using ::art::llvm::runtime_support::JniMethodEndWithReference; 47 using ::art::llvm::runtime_support::JniMethodEndWithReferenceSynchronized; 48 using ::art::llvm::runtime_support::JniMethodStart; 49 using ::art::llvm::runtime_support::JniMethodStartSynchronized; 50 using ::art::llvm::runtime_support::RuntimeId; 70 ::llvm::Value* this_object_or_class_object; in Compile() 78 ::llvm::Function::arg_iterator arg_begin(func_->arg_begin()); in Compile() [all …]
|
D | jni_compiler.h | 37 namespace llvm { 49 namespace llvm { 65 ::llvm::FunctionType* GetFunctionType(uint32_t method_idx, 72 ::llvm::Module* module_; 73 ::llvm::LLVMContext* context_; 78 ::llvm::Function* func_;
|
/art/compiler/dex/ |
D | frontend.h | 23 namespace llvm { 29 namespace llvm { 89 ::llvm::LLVMContext* GetLLVMContext() { in GetLLVMContext() 93 ::llvm::Module* GetLLVMModule() { in GetLLVMModule() 97 art::llvm::IntrinsicHelper* GetIntrinsicHelper() { in GetIntrinsicHelper() 101 art::llvm::IRBuilder* GetIRBuilder() { in GetIRBuilder() 106 std::unique_ptr< ::llvm::LLVMContext> llvm_context_; 107 ::llvm::Module* llvm_module_; // Managed by context_. 108 std::unique_ptr<art::llvm::IntrinsicHelper> intrinsic_helper_; 109 std::unique_ptr<art::llvm::IRBuilder> ir_builder_;
|