diff options
Diffstat (limited to 'src/compiler_llvm/ir_builder.cc')
| -rw-r--r-- | src/compiler_llvm/ir_builder.cc | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/src/compiler_llvm/ir_builder.cc b/src/compiler_llvm/ir_builder.cc index d93b5885d0..8ee4f3ede8 100644 --- a/src/compiler_llvm/ir_builder.cc +++ b/src/compiler_llvm/ir_builder.cc @@ -19,8 +19,6 @@ #include <llvm/Module.h> -#include <algorithm> - namespace art { namespace compiler_llvm { @@ -30,7 +28,7 @@ namespace compiler_llvm { //---------------------------------------------------------------------------- IRBuilder::IRBuilder(llvm::LLVMContext& context, llvm::Module& module) -: LLVMIRBuilder(context), module_(&module), tbaa_(context) { +: LLVMIRBuilder(context), module_(&module), mdb_(context) { // Get java object type from module llvm::Type* jobject_struct_type = module.getTypeByName("JavaObject"); @@ -46,22 +44,6 @@ IRBuilder::IRBuilder(llvm::LLVMContext& context, llvm::Module& module) CHECK(art_frame_type_ != NULL); runtime_support_ = NULL; - - - // Pre-generate the MDNode for static branch prediction - llvm::Type* int32ty = llvm::Type::getInt32Ty(context); - llvm::MDString* branch_weights = llvm::MDString::get(context, "branch_weights"); - llvm::Constant* likely = llvm::ConstantInt::get(int32ty, 64); - llvm::Constant* unlikely = llvm::ConstantInt::get(int32ty, 4); - llvm::Value *opts[] = { - branch_weights, - likely, - unlikely - }; - - expect_cond_[kLikely] = llvm::MDNode::get(context, opts); - std::swap(opts[1], opts[2]); - expect_cond_[kUnlikely] = llvm::MDNode::get(context, opts); } |